{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/agentbookable-com/json-schema/agentbookable-com-business-schema.json",
  "title": "Business",
  "x-generated": "2026-11-01",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/agentbookable-com-openapi.json#/components/schemas/Business",
  "type": "object",
  "properties": {
    "id": {
      "type": "string"
    },
    "name": {
      "type": "string"
    },
    "slug": {
      "type": [
        "string",
        "null"
      ]
    },
    "category": {
      "type": [
        "string",
        "null"
      ]
    },
    "description": {
      "type": [
        "string",
        "null"
      ]
    },
    "location": {
      "type": "object",
      "properties": {
        "city": {
          "type": "string"
        },
        "postcode": {
          "type": "string"
        },
        "country": {
          "type": "string"
        }
      }
    },
    "timezone": {
      "type": "string"
    },
    "provider": {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "description": "Internal provider family. Providers are never exposed by name to agents.",
          "enum": [
            "registry",
            "calcom",
            "zoho",
            "simplybook"
          ]
        }
      }
    },
    "capabilities": {
      "$ref": "#/$defs/Capabilities"
    }
  },
  "$defs": {
    "Capabilities": {
      "type": "object",
      "description": "What is possible for this business. Agents MUST respect these: do not promise actions whose flag is false.",
      "properties": {
        "services": {
          "type": "boolean",
          "description": "Service listing supported."
        },
        "availability": {
          "type": "boolean",
          "description": "Live availability lookup supported. When true you may call POST /businesses/{id}/availability."
        },
        "booking": {
          "type": "boolean",
          "description": "Booking creation supported. When true you may call POST /bookings (with a mandate)."
        },
        "reschedule": {
          "type": "boolean",
          "description": "Rescheduling supported. When false, never offer to move an appointment."
        },
        "cancellation": {
          "type": "boolean",
          "description": "Cancellation supported. When false, never offer to cancel."
        },
        "payment": {
          "type": "boolean",
          "description": "Payment through AgentBookable. When false, payment (if any) is handled at the venue."
        },
        "instantConfirmation": {
          "type": "boolean",
          "description": "True when bookings are confirmed immediately; false means the provider may hold requests for manual confirmation."
        }
      }
    }
  }
}