CRADמפתחים
עברית

Read appointment membership or changes

לפני שימוש חי — בדקו יכולות פרוסות, הרשאות ומוכנות של החיבור שלכם.

בדקו את היכולות הפרוסות, הרשאות המפתח ומוכנות העסק בסביבה שלכם. דוגמאות HTTP נלכדו בבדיקות מבודדות; הסימון local-unreleased שלהן אינו אומר שה־API אינו פועל, ואינו מאשר את החיבור שלכם. במסלול הלקוח מאמתים טלפון בתבנית WhatsApp שהעסק הגדיר; SMS אינו נתמך. רישום בידי אדמין מורשה הוא פעולה נפרדת ללא קוד.

GET/v1/management/appointment-changes

Behavior

Server only. Your backend authenticates its administrator and sends an owner-issued wbm_ key without an Origin header. Every call requires appointments:read plus the stated action scope and a CURRENT per-credential owner calendar grant. Scope issuance alone grants no appointment access. Provider grants never imply manager authority, unassigned access, customer data or notes. Public booking intake, customer OTP, bot/WhatsApp readiness and customer messaging consent are separate. Use only an issued cursor with the same credential and authority epoch. limit 1–100/default 50. Snapshot pages contain current physical rows or minimal removals. Delta events contain metadata signals plus current authorized state, never historical notes or private data. signalVersion describes the signal; current may be newer and wins over an older removal signal. current:null means remove that scoped local row, not proof of a global deletion. Provider/range departures disclose no new unauthorized state. Apply pages in order, deduplicate eventId and appointment/version, and advance even empty filtered pages. A grant change, cursor expiry or30-day retention floor requires a fresh snapshot. No joined customer/catalogue labels are replicated.

Authentication

ManagementCredential

Credential rules

One server-only owner-issued wbm_ API key can carry both management and integration permissions. Additional permissions require an explicit owner-issued grant. GET /v1/management returns the management discovery view, which may be empty for a booking-only key. For credentials with appointments:read, this discovery view omits whatsapp-templates:read, whatsapp-templates:write, whatsapp-profile:read and whatsapp-profile:write to preserve calendar-client compatibility. Discover these grants through GET /v1/management/messaging-capabilities. Template/profile command authorization still uses the stored grants. Server-only owner-issued Management authority with explicit application permissions. Calling this API does not expand a credential's grants. contacts:read/write/block/sync/fields:read/fields:write are separate approvals for canonical business contacts; fields also require current typed owner grants. contacts:record remains contact recording/recovery only. These grants create no customer phone proof, booking authority, messaging consent or automatic synchronization. Hours/blocks retain their independent resource grants. booking-policy:read/write separately delegate whole-business booking settings, without schedule/provider grants; write requires read. They preserve existing appointments and create no duration-rewrite authority. Provider duration policy additionally requires explicit provider-booking-policy:read/write and exact current providerIds; booking-duration:rewrite is separately approved and does not itself grant policy read/write. Service catalogue requires explicit services:read/write, independent of provider/calendar/schedule resources; write requires read. These operations do not expand an existing credential's grants. Public presentation and reviewed service selection require explicit website-content:read/write; write requires read, independently from services:* and provider resources. Existing provider metadata/activity/assignment additionally requires providers:read/write and a nonempty explicit current providerIds grant; write requires read. This grants no provider creation, deletion, login, invitation or schedule authority. WhatsApp template/profile management requires separate whatsapp-templates:read, whatsapp-templates:write, whatsapp-profile:read and whatsapp-profile:write application scopes. Write requires its matching read scope. These grants require explicit owner approval; Meta OAuth permissions remain separate.

Required application permissions

appointments:readappointments:sync

Request

  • cursorquery · stringRequired
    Format and constraints
    cursor schema
    {
      "type": "string",
      "format": "uuid"
    }
  • limitquery · integerOptional
    Format and constraints
    limit schema
    {
      "type": "integer",
      "minimum": 1,
      "maximum": 100,
      "default": 50
    }

Successful responses

200 · BusinessAppointmentSyncPage

Success.

Cache-Control · Contains no-store. Do not cache appointments, grants or receipts.
Cache-Control schema
{
  "type": "string",
  "const": "no-store"
}

application/json · BusinessAppointmentSyncPage

Exactly one of these variants must match.

  • oneOf 1 · kind = "snapshot"objectSchema branch
    View branch fields and rules
    • kindstringRequired in this branch

      Value: "snapshot"

    • appointmentsarrayRequired in this branch

      maxItems: 100

      View nested fields
      • []oneOf (object; allOf (unspecified) | object)Array item

        Exactly one of these variants must match.

        View nested fields
        • oneOf 1 · removed = falseobject; allOf (unspecified)Schema branch

          All of these schema rules apply together.

          View branch fields and rules
          • appointmentIdstring · uuidRequired in this branch
          • versionstringRequired in this branch

            Opaque physical appointment revision, a0 through a9223372036854775807. Preserve exactly; this is distinct from website lineage versions.

            pattern: "^a(?:0|[1-9][0-9]{0,18})$"

          • businessCustomerIdstring · uuidRequired in this branch
          • startAtstring · date-timeRequired in this branch
          • endAtstring · date-timeRequired in this branch
          • statusstringRequired in this branch

            Allowed values: ["PENDING","CONFIRMED","NOW","COMPLETED","CANCELLED","MISSED"]

          • providerIdanyOf (string | null)Required in this branch

            At least one of these variants must match.

            View nested fields
            • anyOf 1string · uuidSchema branch
            • anyOf 2nullSchema branch
          • serviceIdanyOf (string | null)Required in this branch

            At least one of these variants must match.

            View nested fields
            • anyOf 1string · uuidSchema branch
            • anyOf 2nullSchema branch
          • priceMajoranyOf (number | null)Required in this branch

            At least one of these variants must match.

            View nested fields
            • anyOf 1numberSchema branch

              Stored major currency units; 120 means 120 units, not 1.20. Do not combine with customer booking minor-unit money fields.

              minimum: 0maximum: 9007199254740991

            • anyOf 2nullSchema branch
          • currencyanyOf (string | null)Required in this branch

            Frozen accepted currency, or null when an ordinary legacy appointment did not save a currency. CRAD does not infer a current catalogue currency.

            At least one of these variants must match.

            View nested fields
            • anyOf 1stringSchema branch

              maxLength: 100minLength: 1

            • anyOf 2nullSchema branch
          • termsanyOf (object; allOf (unspecified & unspecified) | null)Required in this branch

            At least one of these variants must match.

            View nested fields
            • anyOf 1 · version = 1object; allOf (unspecified & unspecified)Schema branch

              All of these schema rules apply together.

              View branch fields and rules
              • versionnumberRequired in this branch

                Value: 1

              • policystringRequired in this branch

                Allowed values: ["service_duration_v1","legacy_fixed_slot_v1"]

              • policyVersionintegerRequired in this branch

                minimum: 1maximum: 9007199254740991

              • serviceIdstring · uuidRequired in this branch
              • providerIdanyOf (string | null)Required in this branch

                At least one of these variants must match.

                View nested fields
                • anyOf 1string · uuidSchema branch
                • anyOf 2nullSchema branch
              • serviceNameobjectRequired in this branch
                View nested fields
                • hestringOptional in this branch

                  maxLength: 4096

                • arstringOptional in this branch

                  maxLength: 4096

                • enstringOptional in this branch

                  maxLength: 4096

                • additionalPropertiesno value allowedSchema rule
              • baseDurationMinutesintegerRequired in this branch

                minimum: 1maximum: 1440

              • removalDurationMinutesintegerRequired in this branch

                minimum: 0maximum: 240

              • durationMinutesintegerRequired in this branch

                minimum: 1maximum: 1440

              • slotIntervalMinutesintegerRequired in this branch

                minimum: 1maximum: 1440

              • withRemovalbooleanRequired in this branch
              • basePriceMajoranyOf (number | null)Required in this branch

                Unknown accepted price remains null, distinct from an explicit zero. Base and total must both be null or both priced.

                At least one of these variants must match.

                View nested fields
                • anyOf 1numberSchema branch

                  minimum: 0

                • anyOf 2nullSchema branch
              • removalPriceMajornumberRequired in this branch

                Stored major currency units; 120 means 120 units, not 1.20. Do not combine with customer booking minor-unit money fields.

                minimum: 0maximum: 9007199254740991

              • totalPriceMajoranyOf (number | null)Required in this branch

                Unknown accepted price remains null, distinct from an explicit zero. Base and total must both be null or both priced.

                At least one of these variants must match.

                View nested fields
                • anyOf 1numberSchema branch

                  minimum: 0

                • anyOf 2nullSchema branch
              • currencystringRequired in this branch

                maxLength: 100minLength: 1

              • websiteBookingIdstring · uuidOptional in this branch
              • originstringOptional in this branch

                Value: "website"

              • serviceUpdatedAtstring · date-timeOptional in this branch
              • slotGridAnchorstringOptional in this branch

                Present only for accepted treatment-duration grids that restart at each scheduled work segment after a break. Absence preserves the existing day-opening anchor, including historical appointments. Use server-returned availability slots; do not infer the rule from duration, interval, or current business settings.

                Allowed values: ["segment_start"]

              • basePriceRangeMajoranyOf (object | null)Optional in this branch

                Non-final inclusive price bounds in major currency units. Both finite bounds are required; min must be strictly below max and amounts have at most two decimal places. The companion exact amount is null. Omitted or null means no range, not a zero price. Accepted bounds are frozen and must not be recomputed from the current catalogue.

                At least one of these variants must match.

                View nested fields
                • anyOf 1objectSchema branch
                  View branch fields and rules
                  • minnumberRequired in this branch

                    minimum: 0maximum: 90071992547409.9

                  • maxnumberRequired in this branch

                    minimum: 0maximum: 90071992547409.9

                  • additionalPropertiesno value allowedSchema rule
                • anyOf 2nullSchema branch
              • totalPriceRangeMajoranyOf (object | null)Optional in this branch

                Non-final inclusive price bounds in major currency units. Both finite bounds are required; min must be strictly below max and amounts have at most two decimal places. The companion exact amount is null. Omitted or null means no range, not a zero price. Accepted bounds are frozen and must not be recomputed from the current catalogue.

                At least one of these variants must match.

                View nested fields
                • anyOf 1objectSchema branch
                  View branch fields and rules
                  • minnumberRequired in this branch

                    minimum: 0maximum: 90071992547409.9

                  • maxnumberRequired in this branch

                    minimum: 0maximum: 90071992547409.9

                  • additionalPropertiesno value allowedSchema rule
                • anyOf 2nullSchema branch
              • allOf 1unspecifiedSchema branch
                View branch fields and rules
                • ifobjectSchema rule
                  View branch fields and rules
                  • basePriceRangeMajorobjectCondition predicate
                • thenobjectSchema rule
                  View branch fields and rules
                  • basePriceMajornullOptional in this branch
              • allOf 2unspecifiedSchema branch
                View branch fields and rules
                • ifobjectSchema rule
                  View branch fields and rules
                  • totalPriceRangeMajorobjectCondition predicate
                • thenobjectSchema rule
                  View branch fields and rules
                  • totalPriceMajornullOptional in this branch
              • additionalPropertiesno value allowedSchema rule
            • anyOf 2nullSchema branch
          • websiteBookingIdanyOf (string | null)Required in this branch

            At least one of these variants must match.

            View nested fields
            • anyOf 1string · uuidSchema branch
            • anyOf 2nullSchema branch
          • notesanyOf (string | null)Required in this branch

            At least one of these variants must match.

            View nested fields
            • anyOf 1stringSchema branch

              maxLength: 4000

            • anyOf 2nullSchema branch
          • fieldUnavailableReasonsobjectRequired in this branch
            View nested fields
            • priceMajorstringOptional in this branch

              Allowed values: ["too_large","invalid_stored_value"]

            • termsstringOptional in this branch

              Allowed values: ["too_large","invalid_stored_value"]

            • notesstringOptional in this branch

              Allowed values: ["too_large","invalid_stored_value"]

            • additionalPropertiesno value allowedSchema rule
          • removedbooleanRequired in this branch

            Value: false

          • approvalRequiredbooleanOptional in this branch

            Customer request requiring a clinic decision. Existing appointments and manually entered appointments are preserved.

          • timeProposalanyOf (object | null)Optional in this branch

            At least one of these variants must match.

            View nested fields
            • anyOf 1objectSchema branch

              Version-bound alternative for a pending request. The original keeps its slot; the alternative is not held. Acceptance rechecks capacity and creates one confirmed successor preserving accepted terms. Expired or replaced offers cannot be accepted.

              View branch fields and rules
              • proposalIdstring · uuidRequired in this branch
              • appointmentVersionstringRequired in this branch

                Opaque physical appointment revision, a0 through a9223372036854775807. Preserve exactly; this is distinct from website lineage versions.

                pattern: "^a(?:0|[1-9][0-9]{0,18})$"

              • startAtstring · date-timeRequired in this branch
              • endAtstring · date-timeRequired in this branch
              • expiresAtstring · date-timeRequired in this branch
              • statestringRequired in this branch

                Allowed values: ["offered","accepted","declined"]

              • additionalPropertiesno value allowedSchema rule
            • anyOf 2nullSchema branch
          • priceRangeMajoranyOf (object | null)Optional in this branch

            Non-final inclusive price bounds in major currency units. Both finite bounds are required; min must be strictly below max and amounts have at most two decimal places. The companion exact amount is null. Omitted or null means no range, not a zero price. Accepted bounds are frozen and must not be recomputed from the current catalogue.

            At least one of these variants must match.

            View nested fields
            • anyOf 1objectSchema branch
              View branch fields and rules
              • minnumberRequired in this branch

                minimum: 0maximum: 90071992547409.9

              • maxnumberRequired in this branch

                minimum: 0maximum: 90071992547409.9

              • additionalPropertiesno value allowedSchema rule
            • anyOf 2nullSchema branch
          • allOf 1unspecifiedSchema branch
            View branch fields and rules
            • ifobjectSchema rule
              View branch fields and rules
              • priceRangeMajorobjectCondition predicate
            • thenobjectSchema rule
              View branch fields and rules
              • priceMajornullOptional in this branch
          • additionalPropertiesno value allowedSchema rule
        • oneOf 2 · removed = trueobjectSchema branch
          View branch fields and rules
          • appointmentIdstring · uuidRequired in this branch
          • versionstringRequired in this branch

            Opaque physical appointment revision, a0 through a9223372036854775807. Preserve exactly; this is distinct from website lineage versions.

            pattern: "^a(?:0|[1-9][0-9]{0,18})$"

          • removedbooleanRequired in this branch

            Value: true

          • additionalPropertiesno value allowedSchema rule
    • nextCursorstring · uuidRequired in this branch
    • hasMorebooleanRequired in this branch
    • watermarkintegerRequired in this branch

      minimum: 0maximum: 9007199254740991

    • projectionEpochstringRequired in this branch

      Opaque scope/authority identity. Do not parse it as a version or infer a hash algorithm.

      pattern: "^(?:[a-f0-9]{32}|[a-f0-9]{64})$"

    • scopeIdstringRequired in this branch

      Opaque scope/authority identity. Do not parse it as a version or infer a hash algorithm.

      pattern: "^(?:[a-f0-9]{32}|[a-f0-9]{64})$"

    • additionalPropertiesno value allowedSchema rule
  • oneOf 2 · kind = "changes"objectSchema branch
    View branch fields and rules
    • kindstringRequired in this branch

      Value: "changes"

    • eventsarrayRequired in this branch

      maxItems: 100

      View nested fields
      • []objectArray item
        View nested fields
        • eventIdstring · uuidRequired in this branch
        • appointmentIdstring · uuidRequired in this branch
        • sequenceintegerRequired in this branch

          minimum: 1maximum: 9007199254740991

        • signalVersionstringRequired in this branch

          Opaque physical appointment revision, a0 through a9223372036854775807. Preserve exactly; this is distinct from website lineage versions.

          pattern: "^a(?:0|[1-9][0-9]{0,18})$"

        • typestringRequired in this branch

          Allowed values: ["upsert","removed"]

        • changedFieldsarrayRequired in this branch

          minItems: 1maxItems: 20

          View nested fields
          • []stringArray item

            Allowed values: ["*","version","businessCustomerId","providerId","serviceId","priceMajor","startAt","endAt","status","terms","websiteBookingId","notes"]

        • sourcestringRequired in this branch

          Only this integration can be named management:<its ID>; other integrations and native user IDs are masked.

          pattern: "^(?:crad_appointment|other_integration|management:[a-f0-9-]{36})$"

        • currentanyOf (object; allOf (unspecified) | null)Required in this branch

          At least one of these variants must match.

          View nested fields
          • anyOf 1 · removed = falseobject; allOf (unspecified)Schema branch

            All of these schema rules apply together.

            View branch fields and rules
            • appointmentIdstring · uuidRequired in this branch
            • versionstringRequired in this branch

              Opaque physical appointment revision, a0 through a9223372036854775807. Preserve exactly; this is distinct from website lineage versions.

              pattern: "^a(?:0|[1-9][0-9]{0,18})$"

            • businessCustomerIdstring · uuidRequired in this branch
            • startAtstring · date-timeRequired in this branch
            • endAtstring · date-timeRequired in this branch
            • statusstringRequired in this branch

              Allowed values: ["PENDING","CONFIRMED","NOW","COMPLETED","CANCELLED","MISSED"]

            • providerIdanyOf (string | null)Required in this branch

              At least one of these variants must match.

              View nested fields
              • anyOf 1string · uuidSchema branch
              • anyOf 2nullSchema branch
            • serviceIdanyOf (string | null)Required in this branch

              At least one of these variants must match.

              View nested fields
              • anyOf 1string · uuidSchema branch
              • anyOf 2nullSchema branch
            • priceMajoranyOf (number | null)Required in this branch

              At least one of these variants must match.

              View nested fields
              • anyOf 1numberSchema branch

                Stored major currency units; 120 means 120 units, not 1.20. Do not combine with customer booking minor-unit money fields.

                minimum: 0maximum: 9007199254740991

              • anyOf 2nullSchema branch
            • currencyanyOf (string | null)Required in this branch

              Frozen accepted currency, or null when an ordinary legacy appointment did not save a currency. CRAD does not infer a current catalogue currency.

              At least one of these variants must match.

              View nested fields
              • anyOf 1stringSchema branch

                maxLength: 100minLength: 1

              • anyOf 2nullSchema branch
            • termsanyOf (object; allOf (unspecified & unspecified) | null)Required in this branch

              At least one of these variants must match.

              View nested fields
              • anyOf 1 · version = 1object; allOf (unspecified & unspecified)Schema branch

                All of these schema rules apply together.

                View branch fields and rules
                • versionnumberRequired in this branch

                  Value: 1

                • policystringRequired in this branch

                  Allowed values: ["service_duration_v1","legacy_fixed_slot_v1"]

                • policyVersionintegerRequired in this branch

                  minimum: 1maximum: 9007199254740991

                • serviceIdstring · uuidRequired in this branch
                • providerIdanyOf (string | null)Required in this branch

                  At least one of these variants must match.

                  View nested fields
                  • anyOf 1string · uuidSchema branch
                  • anyOf 2nullSchema branch
                • serviceNameobjectRequired in this branch
                  View nested fields
                  • hestringOptional in this branch

                    maxLength: 4096

                  • arstringOptional in this branch

                    maxLength: 4096

                  • enstringOptional in this branch

                    maxLength: 4096

                  • additionalPropertiesno value allowedSchema rule
                • baseDurationMinutesintegerRequired in this branch

                  minimum: 1maximum: 1440

                • removalDurationMinutesintegerRequired in this branch

                  minimum: 0maximum: 240

                • durationMinutesintegerRequired in this branch

                  minimum: 1maximum: 1440

                • slotIntervalMinutesintegerRequired in this branch

                  minimum: 1maximum: 1440

                • withRemovalbooleanRequired in this branch
                • basePriceMajoranyOf (number | null)Required in this branch

                  Unknown accepted price remains null, distinct from an explicit zero. Base and total must both be null or both priced.

                  At least one of these variants must match.

                  View nested fields
                  • anyOf 1numberSchema branch

                    minimum: 0

                  • anyOf 2nullSchema branch
                • removalPriceMajornumberRequired in this branch

                  Stored major currency units; 120 means 120 units, not 1.20. Do not combine with customer booking minor-unit money fields.

                  minimum: 0maximum: 9007199254740991

                • totalPriceMajoranyOf (number | null)Required in this branch

                  Unknown accepted price remains null, distinct from an explicit zero. Base and total must both be null or both priced.

                  At least one of these variants must match.

                  View nested fields
                  • anyOf 1numberSchema branch

                    minimum: 0

                  • anyOf 2nullSchema branch
                • currencystringRequired in this branch

                  maxLength: 100minLength: 1

                • websiteBookingIdstring · uuidOptional in this branch
                • originstringOptional in this branch

                  Value: "website"

                • serviceUpdatedAtstring · date-timeOptional in this branch
                • slotGridAnchorstringOptional in this branch

                  Present only for accepted treatment-duration grids that restart at each scheduled work segment after a break. Absence preserves the existing day-opening anchor, including historical appointments. Use server-returned availability slots; do not infer the rule from duration, interval, or current business settings.

                  Allowed values: ["segment_start"]

                • basePriceRangeMajoranyOf (object | null)Optional in this branch

                  Non-final inclusive price bounds in major currency units. Both finite bounds are required; min must be strictly below max and amounts have at most two decimal places. The companion exact amount is null. Omitted or null means no range, not a zero price. Accepted bounds are frozen and must not be recomputed from the current catalogue.

                  At least one of these variants must match.

                  View nested fields
                  • anyOf 1objectSchema branch
                    View branch fields and rules
                    • minnumberRequired in this branch

                      minimum: 0maximum: 90071992547409.9

                    • maxnumberRequired in this branch

                      minimum: 0maximum: 90071992547409.9

                    • additionalPropertiesno value allowedSchema rule
                  • anyOf 2nullSchema branch
                • totalPriceRangeMajoranyOf (object | null)Optional in this branch

                  Non-final inclusive price bounds in major currency units. Both finite bounds are required; min must be strictly below max and amounts have at most two decimal places. The companion exact amount is null. Omitted or null means no range, not a zero price. Accepted bounds are frozen and must not be recomputed from the current catalogue.

                  At least one of these variants must match.

                  View nested fields
                  • anyOf 1objectSchema branch
                    View branch fields and rules
                    • minnumberRequired in this branch

                      minimum: 0maximum: 90071992547409.9

                    • maxnumberRequired in this branch

                      minimum: 0maximum: 90071992547409.9

                    • additionalPropertiesno value allowedSchema rule
                  • anyOf 2nullSchema branch
                • allOf 1unspecifiedSchema branch
                  View branch fields and rules
                  • ifobjectSchema rule
                    View branch fields and rules
                    • basePriceRangeMajorobjectCondition predicate
                  • thenobjectSchema rule
                    View branch fields and rules
                    • basePriceMajornullOptional in this branch
                • allOf 2unspecifiedSchema branch
                  View branch fields and rules
                  • ifobjectSchema rule
                    View branch fields and rules
                    • totalPriceRangeMajorobjectCondition predicate
                  • thenobjectSchema rule
                    View branch fields and rules
                    • totalPriceMajornullOptional in this branch
                • additionalPropertiesno value allowedSchema rule
              • anyOf 2nullSchema branch
            • websiteBookingIdanyOf (string | null)Required in this branch

              At least one of these variants must match.

              View nested fields
              • anyOf 1string · uuidSchema branch
              • anyOf 2nullSchema branch
            • notesanyOf (string | null)Required in this branch

              At least one of these variants must match.

              View nested fields
              • anyOf 1stringSchema branch

                maxLength: 4000

              • anyOf 2nullSchema branch
            • fieldUnavailableReasonsobjectRequired in this branch
              View nested fields
              • priceMajorstringOptional in this branch

                Allowed values: ["too_large","invalid_stored_value"]

              • termsstringOptional in this branch

                Allowed values: ["too_large","invalid_stored_value"]

              • notesstringOptional in this branch

                Allowed values: ["too_large","invalid_stored_value"]

              • additionalPropertiesno value allowedSchema rule
            • removedbooleanRequired in this branch

              Value: false

            • approvalRequiredbooleanOptional in this branch

              Customer request requiring a clinic decision. Existing appointments and manually entered appointments are preserved.

            • timeProposalanyOf (object | null)Optional in this branch

              At least one of these variants must match.

              View nested fields
              • anyOf 1objectSchema branch

                Version-bound alternative for a pending request. The original keeps its slot; the alternative is not held. Acceptance rechecks capacity and creates one confirmed successor preserving accepted terms. Expired or replaced offers cannot be accepted.

                View branch fields and rules
                • proposalIdstring · uuidRequired in this branch
                • appointmentVersionstringRequired in this branch

                  Opaque physical appointment revision, a0 through a9223372036854775807. Preserve exactly; this is distinct from website lineage versions.

                  pattern: "^a(?:0|[1-9][0-9]{0,18})$"

                • startAtstring · date-timeRequired in this branch
                • endAtstring · date-timeRequired in this branch
                • expiresAtstring · date-timeRequired in this branch
                • statestringRequired in this branch

                  Allowed values: ["offered","accepted","declined"]

                • additionalPropertiesno value allowedSchema rule
              • anyOf 2nullSchema branch
            • priceRangeMajoranyOf (object | null)Optional in this branch

              Non-final inclusive price bounds in major currency units. Both finite bounds are required; min must be strictly below max and amounts have at most two decimal places. The companion exact amount is null. Omitted or null means no range, not a zero price. Accepted bounds are frozen and must not be recomputed from the current catalogue.

              At least one of these variants must match.

              View nested fields
              • anyOf 1objectSchema branch
                View branch fields and rules
                • minnumberRequired in this branch

                  minimum: 0maximum: 90071992547409.9

                • maxnumberRequired in this branch

                  minimum: 0maximum: 90071992547409.9

                • additionalPropertiesno value allowedSchema rule
              • anyOf 2nullSchema branch
            • allOf 1unspecifiedSchema branch
              View branch fields and rules
              • ifobjectSchema rule
                View branch fields and rules
                • priceRangeMajorobjectCondition predicate
              • thenobjectSchema rule
                View branch fields and rules
                • priceMajornullOptional in this branch
            • additionalPropertiesno value allowedSchema rule
          • anyOf 2nullSchema branch
        • additionalPropertiesno value allowedSchema rule
    • nextCursorstring · uuidRequired in this branch
    • hasMorebooleanRequired in this branch
    • watermarkintegerRequired in this branch

      minimum: 0maximum: 9007199254740991

    • projectionEpochstringRequired in this branch

      Opaque scope/authority identity. Do not parse it as a version or infer a hash algorithm.

      pattern: "^(?:[a-f0-9]{32}|[a-f0-9]{64})$"

    • scopeIdstringRequired in this branch

      Opaque scope/authority identity. Do not parse it as a version or infer a hash algorithm.

      pattern: "^(?:[a-f0-9]{32}|[a-f0-9]{64})$"

    • additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
JSON Schema
{
  "oneOf": [
    {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "kind": {
          "const": "snapshot"
        },
        "appointments": {
          "type": "array",
          "items": {
            "oneOf": [
              {
                "type": "object",
                "additionalProperties": false,
                "properties": {
                  "appointmentId": {
                    "type": "string",
                    "format": "uuid"
                  },
                  "version": {
                    "type": "string",
                    "pattern": "^a(?:0|[1-9][0-9]{0,18})$",
                    "description": "Opaque physical appointment revision, a0 through a9223372036854775807. Preserve exactly; this is distinct from website lineage versions."
                  },
                  "businessCustomerId": {
                    "type": "string",
                    "format": "uuid"
                  },
                  "startAt": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "endAt": {
                    "type": "string",
                    "format": "date-time"
                  },
                  "status": {
                    "enum": [
                      "PENDING",
                      "CONFIRMED",
                      "NOW",
                      "COMPLETED",
                      "CANCELLED",
                      "MISSED"
                    ]
                  },
                  "providerId": {
                    "anyOf": [
                      {
                        "type": "string",
                        "format": "uuid"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "serviceId": {
                    "anyOf": [
                      {
                        "type": "string",
                        "format": "uuid"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "priceMajor": {
                    "anyOf": [
                      {
                        "type": "number",
                        "minimum": 0,
                        "maximum": 9007199254740991,
                        "description": "Stored major currency units; 120 means 120 units, not 1.20. Do not combine with customer booking minor-unit money fields."
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "currency": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 100,
                        "minLength": 1
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "Frozen accepted currency, or null when an ordinary legacy appointment did not save a currency. CRAD does not infer a current catalogue currency."
                  },
                  "terms": {
                    "anyOf": [
                      {
                        "type": "object",
                        "additionalProperties": false,
                        "properties": {
                          "version": {
                            "const": 1
                          },
                          "policy": {
                            "enum": [
                              "service_duration_v1",
                              "legacy_fixed_slot_v1"
                            ]
                          },
                          "policyVersion": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 9007199254740991
                          },
                          "serviceId": {
                            "type": "string",
                            "format": "uuid"
                          },
                          "providerId": {
                            "anyOf": [
                              {
                                "type": "string",
                                "format": "uuid"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "serviceName": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                              "he": {
                                "type": "string",
                                "maxLength": 4096
                              },
                              "ar": {
                                "type": "string",
                                "maxLength": 4096
                              },
                              "en": {
                                "type": "string",
                                "maxLength": 4096
                              }
                            },
                            "required": []
                          },
                          "baseDurationMinutes": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 1440
                          },
                          "removalDurationMinutes": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 240
                          },
                          "durationMinutes": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 1440
                          },
                          "slotIntervalMinutes": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 1440
                          },
                          "withRemoval": {
                            "type": "boolean"
                          },
                          "basePriceMajor": {
                            "anyOf": [
                              {
                                "type": "number",
                                "minimum": 0
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Unknown accepted price remains null, distinct from an explicit zero. Base and total must both be null or both priced."
                          },
                          "removalPriceMajor": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 9007199254740991,
                            "description": "Stored major currency units; 120 means 120 units, not 1.20. Do not combine with customer booking minor-unit money fields."
                          },
                          "totalPriceMajor": {
                            "anyOf": [
                              {
                                "type": "number",
                                "minimum": 0
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Unknown accepted price remains null, distinct from an explicit zero. Base and total must both be null or both priced."
                          },
                          "currency": {
                            "type": "string",
                            "maxLength": 100,
                            "minLength": 1
                          },
                          "websiteBookingId": {
                            "type": "string",
                            "format": "uuid"
                          },
                          "origin": {
                            "const": "website"
                          },
                          "serviceUpdatedAt": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "slotGridAnchor": {
                            "enum": [
                              "segment_start"
                            ],
                            "description": "Present only for accepted treatment-duration grids that restart at each scheduled work segment after a break. Absence preserves the existing day-opening anchor, including historical appointments. Use server-returned availability slots; do not infer the rule from duration, interval, or current business settings."
                          },
                          "basePriceRangeMajor": {
                            "anyOf": [
                              {
                                "type": "object",
                                "additionalProperties": false,
                                "required": [
                                  "min",
                                  "max"
                                ],
                                "properties": {
                                  "min": {
                                    "type": "number",
                                    "minimum": 0,
                                    "maximum": 90071992547409.9
                                  },
                                  "max": {
                                    "type": "number",
                                    "minimum": 0,
                                    "maximum": 90071992547409.9
                                  }
                                }
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Non-final inclusive price bounds in major currency units. Both finite bounds are required; min must be strictly below max and amounts have at most two decimal places. The companion exact amount is null. Omitted or null means no range, not a zero price. Accepted bounds are frozen and must not be recomputed from the current catalogue."
                          },
                          "totalPriceRangeMajor": {
                            "anyOf": [
                              {
                                "type": "object",
                                "additionalProperties": false,
                                "required": [
                                  "min",
                                  "max"
                                ],
                                "properties": {
                                  "min": {
                                    "type": "number",
                                    "minimum": 0,
                                    "maximum": 90071992547409.9
                                  },
                                  "max": {
                                    "type": "number",
                                    "minimum": 0,
                                    "maximum": 90071992547409.9
                                  }
                                }
                              },
                              {
                                "type": "null"
                              }
                            ],
                            "description": "Non-final inclusive price bounds in major currency units. Both finite bounds are required; min must be strictly below max and amounts have at most two decimal places. The companion exact amount is null. Omitted or null means no range, not a zero price. Accepted bounds are frozen and must not be recomputed from the current catalogue."
                          }
                        },
                        "required": [
                          "version",
                          "policy",
                          "policyVersion",
                          "serviceId",
                          "providerId",
                          "serviceName",
                          "baseDurationMinutes",
                          "removalDurationMinutes",
                          "durationMinutes",
                          "slotIntervalMinutes",
                          "withRemoval",
                          "basePriceMajor",
                          "removalPriceMajor",
                          "totalPriceMajor",
                          "currency"
                        ],
                        "allOf": [
                          {
                            "if": {
                              "required": [
                                "basePriceRangeMajor"
                              ],
                              "properties": {
                                "basePriceRangeMajor": {
                                  "type": "object"
                                }
                              }
                            },
                            "then": {
                              "properties": {
                                "basePriceMajor": {
                                  "type": "null"
                                }
                              }
                            }
                          },
                          {
                            "if": {
                              "required": [
                                "totalPriceRangeMajor"
                              ],
                              "properties": {
                                "totalPriceRangeMajor": {
                                  "type": "object"
                                }
                              }
                            },
                            "then": {
                              "properties": {
                                "totalPriceMajor": {
                                  "type": "null"
                                }
                              }
                            }
                          }
                        ]
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "websiteBookingId": {
                    "anyOf": [
                      {
                        "type": "string",
                        "format": "uuid"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "notes": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 4000
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "fieldUnavailableReasons": {
                    "type": "object",
                    "additionalProperties": false,
                    "properties": {
                      "priceMajor": {
                        "enum": [
                          "too_large",
                          "invalid_stored_value"
                        ]
                      },
                      "terms": {
                        "enum": [
                          "too_large",
                          "invalid_stored_value"
                        ]
                      },
                      "notes": {
                        "enum": [
                          "too_large",
                          "invalid_stored_value"
                        ]
                      }
                    },
                    "required": []
                  },
                  "removed": {
                    "const": false
                  },
                  "approvalRequired": {
                    "type": "boolean",
                    "description": "Customer request requiring a clinic decision. Existing appointments and manually entered appointments are preserved."
                  },
                  "timeProposal": {
                    "anyOf": [
                      {
                        "type": "object",
                        "additionalProperties": false,
                        "properties": {
                          "proposalId": {
                            "type": "string",
                            "format": "uuid"
                          },
                          "appointmentVersion": {
                            "type": "string",
                            "pattern": "^a(?:0|[1-9][0-9]{0,18})$",
                            "description": "Opaque physical appointment revision, a0 through a9223372036854775807. Preserve exactly; this is distinct from website lineage versions."
                          },
                          "startAt": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "endAt": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "expiresAt": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "state": {
                            "enum": [
                              "offered",
                              "accepted",
                              "declined"
                            ]
                          }
                        },
                        "required": [
                          "proposalId",
                          "appointmentVersion",
                          "startAt",
                          "endAt",
                          "expiresAt",
                          "state"
                        ],
                        "description": "Version-bound alternative for a pending request. The original keeps its slot; the alternative is not held. Acceptance rechecks capacity and creates one confirmed successor preserving accepted terms. Expired or replaced offers cannot be accepted."
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "priceRangeMajor": {
                    "anyOf": [
                      {
                        "type": "object",
                        "additionalProperties": false,
                        "required": [
                          "min",
                          "max"
                        ],
                        "properties": {
                          "min": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 90071992547409.9
                          },
                          "max": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 90071992547409.9
                          }
                        }
                      },
                      {
                        "type": "null"
                      }
                    ],
                    "description": "Non-final inclusive price bounds in major currency units. Both finite bounds are required; min must be strictly below max and amounts have at most two decimal places. The companion exact amount is null. Omitted or null means no range, not a zero price. Accepted bounds are frozen and must not be recomputed from the current catalogue."
                  }
                },
                "required": [
                  "appointmentId",
                  "version",
                  "businessCustomerId",
                  "startAt",
                  "endAt",
                  "status",
                  "providerId",
                  "serviceId",
                  "priceMajor",
                  "currency",
                  "terms",
                  "websiteBookingId",
                  "notes",
                  "fieldUnavailableReasons",
                  "removed"
                ],
                "allOf": [
                  {
                    "if": {
                      "required": [
                        "priceRangeMajor"
                      ],
                      "properties": {
                        "priceRangeMajor": {
                          "type": "object"
                        }
                      }
                    },
                    "then": {
                      "properties": {
                        "priceMajor": {
                          "type": "null"
                        }
                      }
                    }
                  }
                ]
              },
              {
                "type": "object",
                "additionalProperties": false,
                "properties": {
                  "appointmentId": {
                    "type": "string",
                    "format": "uuid"
                  },
                  "version": {
                    "type": "string",
                    "pattern": "^a(?:0|[1-9][0-9]{0,18})$",
                    "description": "Opaque physical appointment revision, a0 through a9223372036854775807. Preserve exactly; this is distinct from website lineage versions."
                  },
                  "removed": {
                    "const": true
                  }
                },
                "required": [
                  "appointmentId",
                  "version",
                  "removed"
                ]
              }
            ]
          },
          "maxItems": 100
        },
        "nextCursor": {
          "type": "string",
          "format": "uuid"
        },
        "hasMore": {
          "type": "boolean"
        },
        "watermark": {
          "type": "integer",
          "minimum": 0,
          "maximum": 9007199254740991
        },
        "projectionEpoch": {
          "type": "string",
          "pattern": "^(?:[a-f0-9]{32}|[a-f0-9]{64})$",
          "description": "Opaque scope/authority identity. Do not parse it as a version or infer a hash algorithm."
        },
        "scopeId": {
          "type": "string",
          "pattern": "^(?:[a-f0-9]{32}|[a-f0-9]{64})$",
          "description": "Opaque scope/authority identity. Do not parse it as a version or infer a hash algorithm."
        }
      },
      "required": [
        "kind",
        "appointments",
        "nextCursor",
        "hasMore",
        "watermark",
        "projectionEpoch",
        "scopeId"
      ]
    },
    {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "kind": {
          "const": "changes"
        },
        "events": {
          "type": "array",
          "items": {
            "type": "object",
            "additionalProperties": false,
            "properties": {
              "eventId": {
                "type": "string",
                "format": "uuid"
              },
              "appointmentId": {
                "type": "string",
                "format": "uuid"
              },
              "sequence": {
                "type": "integer",
                "minimum": 1,
                "maximum": 9007199254740991
              },
              "signalVersion": {
                "type": "string",
                "pattern": "^a(?:0|[1-9][0-9]{0,18})$",
                "description": "Opaque physical appointment revision, a0 through a9223372036854775807. Preserve exactly; this is distinct from website lineage versions."
              },
              "type": {
                "enum": [
                  "upsert",
                  "removed"
                ]
              },
              "changedFields": {
                "type": "array",
                "minItems": 1,
                "maxItems": 20,
                "items": {
                  "enum": [
                    "*",
                    "version",
                    "businessCustomerId",
                    "providerId",
                    "serviceId",
                    "priceMajor",
                    "startAt",
                    "endAt",
                    "status",
                    "terms",
                    "websiteBookingId",
                    "notes"
                  ]
                }
              },
              "source": {
                "type": "string",
                "pattern": "^(?:crad_appointment|other_integration|management:[a-f0-9-]{36})$",
                "description": "Only this integration can be named management:<its ID>; other integrations and native user IDs are masked."
              },
              "current": {
                "anyOf": [
                  {
                    "type": "object",
                    "additionalProperties": false,
                    "properties": {
                      "appointmentId": {
                        "type": "string",
                        "format": "uuid"
                      },
                      "version": {
                        "type": "string",
                        "pattern": "^a(?:0|[1-9][0-9]{0,18})$",
                        "description": "Opaque physical appointment revision, a0 through a9223372036854775807. Preserve exactly; this is distinct from website lineage versions."
                      },
                      "businessCustomerId": {
                        "type": "string",
                        "format": "uuid"
                      },
                      "startAt": {
                        "type": "string",
                        "format": "date-time"
                      },
                      "endAt": {
                        "type": "string",
                        "format": "date-time"
                      },
                      "status": {
                        "enum": [
                          "PENDING",
                          "CONFIRMED",
                          "NOW",
                          "COMPLETED",
                          "CANCELLED",
                          "MISSED"
                        ]
                      },
                      "providerId": {
                        "anyOf": [
                          {
                            "type": "string",
                            "format": "uuid"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "serviceId": {
                        "anyOf": [
                          {
                            "type": "string",
                            "format": "uuid"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "priceMajor": {
                        "anyOf": [
                          {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 9007199254740991,
                            "description": "Stored major currency units; 120 means 120 units, not 1.20. Do not combine with customer booking minor-unit money fields."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "currency": {
                        "anyOf": [
                          {
                            "type": "string",
                            "maxLength": 100,
                            "minLength": 1
                          },
                          {
                            "type": "null"
                          }
                        ],
                        "description": "Frozen accepted currency, or null when an ordinary legacy appointment did not save a currency. CRAD does not infer a current catalogue currency."
                      },
                      "terms": {
                        "anyOf": [
                          {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                              "version": {
                                "const": 1
                              },
                              "policy": {
                                "enum": [
                                  "service_duration_v1",
                                  "legacy_fixed_slot_v1"
                                ]
                              },
                              "policyVersion": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 9007199254740991
                              },
                              "serviceId": {
                                "type": "string",
                                "format": "uuid"
                              },
                              "providerId": {
                                "anyOf": [
                                  {
                                    "type": "string",
                                    "format": "uuid"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "serviceName": {
                                "type": "object",
                                "additionalProperties": false,
                                "properties": {
                                  "he": {
                                    "type": "string",
                                    "maxLength": 4096
                                  },
                                  "ar": {
                                    "type": "string",
                                    "maxLength": 4096
                                  },
                                  "en": {
                                    "type": "string",
                                    "maxLength": 4096
                                  }
                                },
                                "required": []
                              },
                              "baseDurationMinutes": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 1440
                              },
                              "removalDurationMinutes": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 240
                              },
                              "durationMinutes": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 1440
                              },
                              "slotIntervalMinutes": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 1440
                              },
                              "withRemoval": {
                                "type": "boolean"
                              },
                              "basePriceMajor": {
                                "anyOf": [
                                  {
                                    "type": "number",
                                    "minimum": 0
                                  },
                                  {
                                    "type": "null"
                                  }
                                ],
                                "description": "Unknown accepted price remains null, distinct from an explicit zero. Base and total must both be null or both priced."
                              },
                              "removalPriceMajor": {
                                "type": "number",
                                "minimum": 0,
                                "maximum": 9007199254740991,
                                "description": "Stored major currency units; 120 means 120 units, not 1.20. Do not combine with customer booking minor-unit money fields."
                              },
                              "totalPriceMajor": {
                                "anyOf": [
                                  {
                                    "type": "number",
                                    "minimum": 0
                                  },
                                  {
                                    "type": "null"
                                  }
                                ],
                                "description": "Unknown accepted price remains null, distinct from an explicit zero. Base and total must both be null or both priced."
                              },
                              "currency": {
                                "type": "string",
                                "maxLength": 100,
                                "minLength": 1
                              },
                              "websiteBookingId": {
                                "type": "string",
                                "format": "uuid"
                              },
                              "origin": {
                                "const": "website"
                              },
                              "serviceUpdatedAt": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "slotGridAnchor": {
                                "enum": [
                                  "segment_start"
                                ],
                                "description": "Present only for accepted treatment-duration grids that restart at each scheduled work segment after a break. Absence preserves the existing day-opening anchor, including historical appointments. Use server-returned availability slots; do not infer the rule from duration, interval, or current business settings."
                              },
                              "basePriceRangeMajor": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "additionalProperties": false,
                                    "required": [
                                      "min",
                                      "max"
                                    ],
                                    "properties": {
                                      "min": {
                                        "type": "number",
                                        "minimum": 0,
                                        "maximum": 90071992547409.9
                                      },
                                      "max": {
                                        "type": "number",
                                        "minimum": 0,
                                        "maximum": 90071992547409.9
                                      }
                                    }
                                  },
                                  {
                                    "type": "null"
                                  }
                                ],
                                "description": "Non-final inclusive price bounds in major currency units. Both finite bounds are required; min must be strictly below max and amounts have at most two decimal places. The companion exact amount is null. Omitted or null means no range, not a zero price. Accepted bounds are frozen and must not be recomputed from the current catalogue."
                              },
                              "totalPriceRangeMajor": {
                                "anyOf": [
                                  {
                                    "type": "object",
                                    "additionalProperties": false,
                                    "required": [
                                      "min",
                                      "max"
                                    ],
                                    "properties": {
                                      "min": {
                                        "type": "number",
                                        "minimum": 0,
                                        "maximum": 90071992547409.9
                                      },
                                      "max": {
                                        "type": "number",
                                        "minimum": 0,
                                        "maximum": 90071992547409.9
                                      }
                                    }
                                  },
                                  {
                                    "type": "null"
                                  }
                                ],
                                "description": "Non-final inclusive price bounds in major currency units. Both finite bounds are required; min must be strictly below max and amounts have at most two decimal places. The companion exact amount is null. Omitted or null means no range, not a zero price. Accepted bounds are frozen and must not be recomputed from the current catalogue."
                              }
                            },
                            "required": [
                              "version",
                              "policy",
                              "policyVersion",
                              "serviceId",
                              "providerId",
                              "serviceName",
                              "baseDurationMinutes",
                              "removalDurationMinutes",
                              "durationMinutes",
                              "slotIntervalMinutes",
                              "withRemoval",
                              "basePriceMajor",
                              "removalPriceMajor",
                              "totalPriceMajor",
                              "currency"
                            ],
                            "allOf": [
                              {
                                "if": {
                                  "required": [
                                    "basePriceRangeMajor"
                                  ],
                                  "properties": {
                                    "basePriceRangeMajor": {
                                      "type": "object"
                                    }
                                  }
                                },
                                "then": {
                                  "properties": {
                                    "basePriceMajor": {
                                      "type": "null"
                                    }
                                  }
                                }
                              },
                              {
                                "if": {
                                  "required": [
                                    "totalPriceRangeMajor"
                                  ],
                                  "properties": {
                                    "totalPriceRangeMajor": {
                                      "type": "object"
                                    }
                                  }
                                },
                                "then": {
                                  "properties": {
                                    "totalPriceMajor": {
                                      "type": "null"
                                    }
                                  }
                                }
                              }
                            ]
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "websiteBookingId": {
                        "anyOf": [
                          {
                            "type": "string",
                            "format": "uuid"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "notes": {
                        "anyOf": [
                          {
                            "type": "string",
                            "maxLength": 4000
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "fieldUnavailableReasons": {
                        "type": "object",
                        "additionalProperties": false,
                        "properties": {
                          "priceMajor": {
                            "enum": [
                              "too_large",
                              "invalid_stored_value"
                            ]
                          },
                          "terms": {
                            "enum": [
                              "too_large",
                              "invalid_stored_value"
                            ]
                          },
                          "notes": {
                            "enum": [
                              "too_large",
                              "invalid_stored_value"
                            ]
                          }
                        },
                        "required": []
                      },
                      "removed": {
                        "const": false
                      },
                      "approvalRequired": {
                        "type": "boolean",
                        "description": "Customer request requiring a clinic decision. Existing appointments and manually entered appointments are preserved."
                      },
                      "timeProposal": {
                        "anyOf": [
                          {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                              "proposalId": {
                                "type": "string",
                                "format": "uuid"
                              },
                              "appointmentVersion": {
                                "type": "string",
                                "pattern": "^a(?:0|[1-9][0-9]{0,18})$",
                                "description": "Opaque physical appointment revision, a0 through a9223372036854775807. Preserve exactly; this is distinct from website lineage versions."
                              },
                              "startAt": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "endAt": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "expiresAt": {
                                "type": "string",
                                "format": "date-time"
                              },
                              "state": {
                                "enum": [
                                  "offered",
                                  "accepted",
                                  "declined"
                                ]
                              }
                            },
                            "required": [
                              "proposalId",
                              "appointmentVersion",
                              "startAt",
                              "endAt",
                              "expiresAt",
                              "state"
                            ],
                            "description": "Version-bound alternative for a pending request. The original keeps its slot; the alternative is not held. Acceptance rechecks capacity and creates one confirmed successor preserving accepted terms. Expired or replaced offers cannot be accepted."
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "priceRangeMajor": {
                        "anyOf": [
                          {
                            "type": "object",
                            "additionalProperties": false,
                            "required": [
                              "min",
                              "max"
                            ],
                            "properties": {
                              "min": {
                                "type": "number",
                                "minimum": 0,
                                "maximum": 90071992547409.9
                              },
                              "max": {
                                "type": "number",
                                "minimum": 0,
                                "maximum": 90071992547409.9
                              }
                            }
                          },
                          {
                            "type": "null"
                          }
                        ],
                        "description": "Non-final inclusive price bounds in major currency units. Both finite bounds are required; min must be strictly below max and amounts have at most two decimal places. The companion exact amount is null. Omitted or null means no range, not a zero price. Accepted bounds are frozen and must not be recomputed from the current catalogue."
                      }
                    },
                    "required": [
                      "appointmentId",
                      "version",
                      "businessCustomerId",
                      "startAt",
                      "endAt",
                      "status",
                      "providerId",
                      "serviceId",
                      "priceMajor",
                      "currency",
                      "terms",
                      "websiteBookingId",
                      "notes",
                      "fieldUnavailableReasons",
                      "removed"
                    ],
                    "allOf": [
                      {
                        "if": {
                          "required": [
                            "priceRangeMajor"
                          ],
                          "properties": {
                            "priceRangeMajor": {
                              "type": "object"
                            }
                          }
                        },
                        "then": {
                          "properties": {
                            "priceMajor": {
                              "type": "null"
                            }
                          }
                        }
                      }
                    ]
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "required": [
              "eventId",
              "appointmentId",
              "sequence",
              "signalVersion",
              "type",
              "changedFields",
              "source",
              "current"
            ]
          },
          "maxItems": 100
        },
        "nextCursor": {
          "type": "string",
          "format": "uuid"
        },
        "hasMore": {
          "type": "boolean"
        },
        "watermark": {
          "type": "integer",
          "minimum": 0,
          "maximum": 9007199254740991
        },
        "projectionEpoch": {
          "type": "string",
          "pattern": "^(?:[a-f0-9]{32}|[a-f0-9]{64})$",
          "description": "Opaque scope/authority identity. Do not parse it as a version or infer a hash algorithm."
        },
        "scopeId": {
          "type": "string",
          "pattern": "^(?:[a-f0-9]{32}|[a-f0-9]{64})$",
          "description": "Opaque scope/authority identity. Do not parse it as a version or infer a hash algorithm."
        }
      },
      "required": [
        "kind",
        "events",
        "nextCursor",
        "hasMore",
        "watermark",
        "projectionEpoch",
        "scopeId"
      ]
    }
  ]
}

Errors and recovery

Error responses declared in the contract (8)

The preview contract shares generic error definitions across operations. This list is not an exhaustive list of runtime errors.

401 · Missing/invalid Management bearer.

application/json · Error

  • errorobjectRequired
    View nested fields
    • codestringRequired
    • requestIdstring · uuidRequired
    • retryAfterintegerOptional

      minimum: 1

    • additionalPropertiesno value allowedSchema rule
  • additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
JSON Schema
{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "error": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "code": {
          "type": "string"
        },
        "requestId": {
          "type": "string",
          "format": "uuid"
        },
        "retryAfter": {
          "type": "integer",
          "minimum": 1
        }
      },
      "required": [
        "code",
        "requestId"
      ]
    }
  },
  "required": [
    "error"
  ]
}
403 · Current scope, calendar grant or authority denied; a browser Origin is refused.

application/json · Error

  • errorobjectRequired
    View nested fields
    • codestringRequired
    • requestIdstring · uuidRequired
    • retryAfterintegerOptional

      minimum: 1

    • additionalPropertiesno value allowedSchema rule
  • additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
JSON Schema
{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "error": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "code": {
          "type": "string"
        },
        "requestId": {
          "type": "string",
          "format": "uuid"
        },
        "retryAfter": {
          "type": "integer",
          "minimum": 1
        }
      },
      "required": [
        "code",
        "requestId"
      ]
    }
  },
  "required": [
    "error"
  ]
}
405 · Method not allowed.

application/json · Error

  • errorobjectRequired
    View nested fields
    • codestringRequired
    • requestIdstring · uuidRequired
    • retryAfterintegerOptional

      minimum: 1

    • additionalPropertiesno value allowedSchema rule
  • additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
JSON Schema
{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "error": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "code": {
          "type": "string"
        },
        "requestId": {
          "type": "string",
          "format": "uuid"
        },
        "retryAfter": {
          "type": "integer",
          "minimum": 1
        }
      },
      "required": [
        "code",
        "requestId"
      ]
    }
  },
  "required": [
    "error"
  ]
}
409 · Action, quote, slot, operation, projection or checkpoint conflict. No partial command.

application/json · Error

  • errorobjectRequired
    View nested fields
    • codestringRequired
    • requestIdstring · uuidRequired
    • retryAfterintegerOptional

      minimum: 1

    • additionalPropertiesno value allowedSchema rule
  • additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
JSON Schema
{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "error": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "code": {
          "type": "string"
        },
        "requestId": {
          "type": "string",
          "format": "uuid"
        },
        "retryAfter": {
          "type": "integer",
          "minimum": 1
        }
      },
      "required": [
        "code",
        "requestId"
      ]
    }
  },
  "required": [
    "error"
  ]
}
410 · Issued cursor expired, was cleaned up, predates retention, or belongs to a previous grant epoch. Start a new snapshot.

application/json · Error

  • errorobjectRequired
    View nested fields
    • codestringRequired
    • requestIdstring · uuidRequired
    • retryAfterintegerOptional

      minimum: 1

    • additionalPropertiesno value allowedSchema rule
  • additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
JSON Schema
{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "error": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "code": {
          "type": "string"
        },
        "requestId": {
          "type": "string",
          "format": "uuid"
        },
        "retryAfter": {
          "type": "integer",
          "minimum": 1
        }
      },
      "required": [
        "code",
        "requestId"
      ]
    }
  },
  "required": [
    "error"
  ]
}
422 · Malformed or unsupported request, including caller-supplied authority or price.

application/json · Error

  • errorobjectRequired
    View nested fields
    • codestringRequired
    • requestIdstring · uuidRequired
    • retryAfterintegerOptional

      minimum: 1

    • additionalPropertiesno value allowedSchema rule
  • additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
JSON Schema
{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "error": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "code": {
          "type": "string"
        },
        "requestId": {
          "type": "string",
          "format": "uuid"
        },
        "retryAfter": {
          "type": "integer",
          "minimum": 1
        }
      },
      "required": [
        "code",
        "requestId"
      ]
    }
  },
  "required": [
    "error"
  ]
}
429 · Machine request, directory cursor or snapshot limit exceeded.

application/json · Error

  • errorobjectRequired
    View nested fields
    • codestringRequired
    • requestIdstring · uuidRequired
    • retryAfterintegerOptional

      minimum: 1

    • additionalPropertiesno value allowedSchema rule
  • additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
JSON Schema
{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "error": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "code": {
          "type": "string"
        },
        "requestId": {
          "type": "string",
          "format": "uuid"
        },
        "retryAfter": {
          "type": "integer",
          "minimum": 1
        }
      },
      "required": [
        "code",
        "requestId"
      ]
    }
  },
  "required": [
    "error"
  ]
}
503 · Persistence unavailable or outcome uncertain. Retain the original UUID/body and recover it before any new operation.

application/json · Error

  • errorobjectRequired
    View nested fields
    • codestringRequired
    • requestIdstring · uuidRequired
    • retryAfterintegerOptional

      minimum: 1

    • additionalPropertiesno value allowedSchema rule
  • additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
JSON Schema
{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "error": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "code": {
          "type": "string"
        },
        "requestId": {
          "type": "string",
          "format": "uuid"
        },
        "retryAfter": {
          "type": "integer",
          "minimum": 1
        }
      },
      "required": [
        "code",
        "requestId"
      ]
    }
  },
  "required": [
    "error"
  ]
}