CRADالمطوّرون
العربية

Preview a schedule change

Preview schedule impact

قبل الاستخدام الفعلي — افحص القدرات المنشورة والصلاحيات وجاهزية ربطك.

تحقّق من القدرات المنشورة وصلاحيات المفتاح وجاهزية النشاط في بيئتك. أمثلة HTTP مسجّلة من اختبارات معزولة؛ وصفها local-unreleased لا يعني أن API غير عامل ولا يُثبت جاهزية ربطك. في مسار العميل يُتحقق من الهاتف بقالب واتساب أعدّه النشاط؛ SMS غير مدعوم. التسجيل بواسطة مسؤول مخوّل عملية منفصلة دون رمز.

POST/v1/management/schedules/{resource}/change-previews

Behavior

Use mode: override with a complete WeeklyHours value, or mode: inherit only for a provider and omit hours entirely. The business schedule cannot inherit. The preview identifies affected appointment times and versions; it preserves appointments and does not grant access to their customer details or authorize moving them.

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

hours:write

The credential must also explicitly grant the requested business or provider resource.

Request

  • resourcepath · stringRequired

    business or allowed provider UUID

    Format and constraints
    resource schema
    {
      "type": "string"
    }
  • If-Matchheader · stringRequired

    Exact strong quoted version returned by the relevant resource; never weak or *. Customer: "1". Schedule: "b1"/"b1:p2". Block: "v1".

    Format and constraints
    If-Match schema
    {
      "type": "string",
      "pattern": "^\"b[1-9][0-9]*(?::p[1-9][0-9]*)?\"$"
    }

Request body · required

application/json · ScheduleProposal

A complete weekly-hours proposal. Override requires hours with all seven days. Inherit is valid only for a provider resource and must omit hours; the business resource cannot inherit. Times are local to the business timezone; overnight intervals are unsupported.

All of these schema rules apply together.

  • modestringRequired

    override replaces the complete weekly schedule. inherit removes a provider override so business hours apply; it is not valid for resource=business.

    Allowed values: ["inherit","override"]

  • hoursallOf (object & unspecified)Optional

    All of these schema rules apply together.

    View nested fields
    • allOf 1objectSchema branch
      View branch fields and rules
      • sundayobject; allOf (unspecified)Required

        All of these schema rules apply together.

        View nested fields
        • enabledbooleanRequired
        • openstringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • closestringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • breaksarrayOptional

          maxItems: 10

          View nested fields
          • []objectArray item
            View nested fields
            • startstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • endstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • additionalPropertiesno value allowedSchema rule
        • allOf 1unspecifiedSchema branch
          View branch fields and rules
          • ifobjectSchema rule
            View branch fields and rules
            • enabledbooleanCondition predicate

              Value: true

          • thenunspecifiedSchema rule
            View branch fields and rules
            • openunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

            • closeunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

        • additionalPropertiesno value allowedSchema rule
      • mondayobject; allOf (unspecified)Required

        All of these schema rules apply together.

        View nested fields
        • enabledbooleanRequired
        • openstringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • closestringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • breaksarrayOptional

          maxItems: 10

          View nested fields
          • []objectArray item
            View nested fields
            • startstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • endstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • additionalPropertiesno value allowedSchema rule
        • allOf 1unspecifiedSchema branch
          View branch fields and rules
          • ifobjectSchema rule
            View branch fields and rules
            • enabledbooleanCondition predicate

              Value: true

          • thenunspecifiedSchema rule
            View branch fields and rules
            • openunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

            • closeunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

        • additionalPropertiesno value allowedSchema rule
      • tuesdayobject; allOf (unspecified)Required

        All of these schema rules apply together.

        View nested fields
        • enabledbooleanRequired
        • openstringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • closestringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • breaksarrayOptional

          maxItems: 10

          View nested fields
          • []objectArray item
            View nested fields
            • startstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • endstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • additionalPropertiesno value allowedSchema rule
        • allOf 1unspecifiedSchema branch
          View branch fields and rules
          • ifobjectSchema rule
            View branch fields and rules
            • enabledbooleanCondition predicate

              Value: true

          • thenunspecifiedSchema rule
            View branch fields and rules
            • openunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

            • closeunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

        • additionalPropertiesno value allowedSchema rule
      • wednesdayobject; allOf (unspecified)Required

        All of these schema rules apply together.

        View nested fields
        • enabledbooleanRequired
        • openstringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • closestringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • breaksarrayOptional

          maxItems: 10

          View nested fields
          • []objectArray item
            View nested fields
            • startstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • endstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • additionalPropertiesno value allowedSchema rule
        • allOf 1unspecifiedSchema branch
          View branch fields and rules
          • ifobjectSchema rule
            View branch fields and rules
            • enabledbooleanCondition predicate

              Value: true

          • thenunspecifiedSchema rule
            View branch fields and rules
            • openunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

            • closeunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

        • additionalPropertiesno value allowedSchema rule
      • thursdayobject; allOf (unspecified)Required

        All of these schema rules apply together.

        View nested fields
        • enabledbooleanRequired
        • openstringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • closestringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • breaksarrayOptional

          maxItems: 10

          View nested fields
          • []objectArray item
            View nested fields
            • startstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • endstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • additionalPropertiesno value allowedSchema rule
        • allOf 1unspecifiedSchema branch
          View branch fields and rules
          • ifobjectSchema rule
            View branch fields and rules
            • enabledbooleanCondition predicate

              Value: true

          • thenunspecifiedSchema rule
            View branch fields and rules
            • openunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

            • closeunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

        • additionalPropertiesno value allowedSchema rule
      • fridayobject; allOf (unspecified)Required

        All of these schema rules apply together.

        View nested fields
        • enabledbooleanRequired
        • openstringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • closestringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • breaksarrayOptional

          maxItems: 10

          View nested fields
          • []objectArray item
            View nested fields
            • startstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • endstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • additionalPropertiesno value allowedSchema rule
        • allOf 1unspecifiedSchema branch
          View branch fields and rules
          • ifobjectSchema rule
            View branch fields and rules
            • enabledbooleanCondition predicate

              Value: true

          • thenunspecifiedSchema rule
            View branch fields and rules
            • openunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

            • closeunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

        • additionalPropertiesno value allowedSchema rule
      • saturdayobject; allOf (unspecified)Required

        All of these schema rules apply together.

        View nested fields
        • enabledbooleanRequired
        • openstringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • closestringOptional

          pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

        • breaksarrayOptional

          maxItems: 10

          View nested fields
          • []objectArray item
            View nested fields
            • startstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • endstringRequired

              pattern: "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"

            • additionalPropertiesno value allowedSchema rule
        • allOf 1unspecifiedSchema branch
          View branch fields and rules
          • ifobjectSchema rule
            View branch fields and rules
            • enabledbooleanCondition predicate

              Value: true

          • thenunspecifiedSchema rule
            View branch fields and rules
            • openunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

            • closeunspecifiedRequired in this branch

              Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

        • additionalPropertiesno value allowedSchema rule
      • additionalPropertiesno value allowedSchema rule
    • allOf 2unspecifiedSchema branch

      Required for override, forbidden for inherit. Supply the complete seven-day week, not a partial patch.

  • allOf 1unspecifiedSchema branch
    View branch fields and rules
    • ifobjectSchema rule
      View branch fields and rules
      • modestringCondition predicate

        Value: "override"

    • thenunspecifiedSchema rule
      View branch fields and rules
      • hoursunspecifiedRequired in this branch

        Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

    • elseunspecifiedSchema rule
      View branch fields and rules
      • notunspecifiedSchema rule

        This rule must not match.

        View branch fields and rules
        • hoursunspecifiedPart of a negated rule

          Presence constraint in this rule; evaluate its enclosing condition or negation. The field’s type may be defined elsewhere.

  • additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
JSON Schema
{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "mode": {
      "enum": [
        "inherit",
        "override"
      ],
      "description": "override replaces the complete weekly schedule. inherit removes a provider override so business hours apply; it is not valid for resource=business."
    },
    "hours": {
      "allOf": [
        {
          "type": "object",
          "properties": {
            "sunday": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "enabled": {
                  "type": "boolean"
                },
                "open": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "close": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "breaks": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "additionalProperties": false,
                    "properties": {
                      "start": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      },
                      "end": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      }
                    },
                    "required": [
                      "start",
                      "end"
                    ]
                  },
                  "maxItems": 10
                }
              },
              "required": [
                "enabled"
              ],
              "allOf": [
                {
                  "if": {
                    "properties": {
                      "enabled": {
                        "const": true
                      }
                    }
                  },
                  "then": {
                    "required": [
                      "open",
                      "close"
                    ]
                  }
                }
              ]
            },
            "monday": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "enabled": {
                  "type": "boolean"
                },
                "open": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "close": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "breaks": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "additionalProperties": false,
                    "properties": {
                      "start": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      },
                      "end": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      }
                    },
                    "required": [
                      "start",
                      "end"
                    ]
                  },
                  "maxItems": 10
                }
              },
              "required": [
                "enabled"
              ],
              "allOf": [
                {
                  "if": {
                    "properties": {
                      "enabled": {
                        "const": true
                      }
                    }
                  },
                  "then": {
                    "required": [
                      "open",
                      "close"
                    ]
                  }
                }
              ]
            },
            "tuesday": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "enabled": {
                  "type": "boolean"
                },
                "open": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "close": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "breaks": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "additionalProperties": false,
                    "properties": {
                      "start": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      },
                      "end": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      }
                    },
                    "required": [
                      "start",
                      "end"
                    ]
                  },
                  "maxItems": 10
                }
              },
              "required": [
                "enabled"
              ],
              "allOf": [
                {
                  "if": {
                    "properties": {
                      "enabled": {
                        "const": true
                      }
                    }
                  },
                  "then": {
                    "required": [
                      "open",
                      "close"
                    ]
                  }
                }
              ]
            },
            "wednesday": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "enabled": {
                  "type": "boolean"
                },
                "open": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "close": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "breaks": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "additionalProperties": false,
                    "properties": {
                      "start": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      },
                      "end": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      }
                    },
                    "required": [
                      "start",
                      "end"
                    ]
                  },
                  "maxItems": 10
                }
              },
              "required": [
                "enabled"
              ],
              "allOf": [
                {
                  "if": {
                    "properties": {
                      "enabled": {
                        "const": true
                      }
                    }
                  },
                  "then": {
                    "required": [
                      "open",
                      "close"
                    ]
                  }
                }
              ]
            },
            "thursday": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "enabled": {
                  "type": "boolean"
                },
                "open": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "close": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "breaks": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "additionalProperties": false,
                    "properties": {
                      "start": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      },
                      "end": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      }
                    },
                    "required": [
                      "start",
                      "end"
                    ]
                  },
                  "maxItems": 10
                }
              },
              "required": [
                "enabled"
              ],
              "allOf": [
                {
                  "if": {
                    "properties": {
                      "enabled": {
                        "const": true
                      }
                    }
                  },
                  "then": {
                    "required": [
                      "open",
                      "close"
                    ]
                  }
                }
              ]
            },
            "friday": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "enabled": {
                  "type": "boolean"
                },
                "open": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "close": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "breaks": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "additionalProperties": false,
                    "properties": {
                      "start": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      },
                      "end": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      }
                    },
                    "required": [
                      "start",
                      "end"
                    ]
                  },
                  "maxItems": 10
                }
              },
              "required": [
                "enabled"
              ],
              "allOf": [
                {
                  "if": {
                    "properties": {
                      "enabled": {
                        "const": true
                      }
                    }
                  },
                  "then": {
                    "required": [
                      "open",
                      "close"
                    ]
                  }
                }
              ]
            },
            "saturday": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "enabled": {
                  "type": "boolean"
                },
                "open": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "close": {
                  "type": "string",
                  "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                },
                "breaks": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "additionalProperties": false,
                    "properties": {
                      "start": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      },
                      "end": {
                        "type": "string",
                        "pattern": "^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"
                      }
                    },
                    "required": [
                      "start",
                      "end"
                    ]
                  },
                  "maxItems": 10
                }
              },
              "required": [
                "enabled"
              ],
              "allOf": [
                {
                  "if": {
                    "properties": {
                      "enabled": {
                        "const": true
                      }
                    }
                  },
                  "then": {
                    "required": [
                      "open",
                      "close"
                    ]
                  }
                }
              ]
            }
          },
          "additionalProperties": false,
          "required": [
            "sunday",
            "monday",
            "tuesday",
            "wednesday",
            "thursday",
            "friday",
            "saturday"
          ]
        },
        {
          "description": "Required for override, forbidden for inherit. Supply the complete seven-day week, not a partial patch."
        }
      ]
    }
  },
  "required": [
    "mode"
  ],
  "description": "A complete weekly-hours proposal. Override requires hours with all seven days. Inherit is valid only for a provider resource and must omit hours; the business resource cannot inherit. Times are local to the business timezone; overnight intervals are unsupported.",
  "allOf": [
    {
      "if": {
        "properties": {
          "mode": {
            "const": "override"
          }
        },
        "required": [
          "mode"
        ]
      },
      "then": {
        "required": [
          "hours"
        ]
      },
      "else": {
        "not": {
          "required": [
            "hours"
          ]
        }
      }
    }
  ]
}

Successful responses

200 · SchedulePreview

application/json · SchedulePreview

  • previewIdstring · uuidRequired
  • expectedVersionstringRequired
  • affectedAppointmentsarrayRequired
    View nested fields
    • []objectArray item
      View nested fields
      • appointmentIdstring · uuidRequired
      • versionstring · date-timeRequired
      • startTimestring · date-timeRequired
      • endTimestring · date-timeRequired
      • additionalPropertiesno value allowedSchema rule
  • affectedCountintegerRequired

    minimum: 0

  • expiresAtstring · date-timeRequired
  • existingAppointmentsPreservedbooleanRequired

    Value: true

  • additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
JSON Schema
{
  "type": "object",
  "properties": {
    "previewId": {
      "type": "string",
      "format": "uuid"
    },
    "expectedVersion": {
      "type": "string"
    },
    "affectedAppointments": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "appointmentId": {
            "type": "string",
            "format": "uuid"
          },
          "version": {
            "type": "string",
            "format": "date-time"
          },
          "startTime": {
            "type": "string",
            "format": "date-time"
          },
          "endTime": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "appointmentId",
          "version",
          "startTime",
          "endTime"
        ],
        "additionalProperties": false
      }
    },
    "affectedCount": {
      "type": "integer",
      "minimum": 0
    },
    "expiresAt": {
      "type": "string",
      "format": "date-time"
    },
    "existingAppointmentsPreserved": {
      "const": true
    }
  },
  "required": [
    "previewId",
    "expectedVersion",
    "affectedAppointments",
    "affectedCount",
    "expiresAt",
    "existingAppointmentsPreserved"
  ],
  "additionalProperties": false
}

Errors and recovery

Input validation

  • 413REQUEST_TOO_LARGE

    The JSON request body exceeds 8,192 bytes.

  • 415JSON_REQUIRED

    Send Content-Type: application/json.

Error responses declared in the contract (10)

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

401 · Structured error.

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 · Structured error.

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"
  ]
}
404 · Structured error.

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 · Structured error.

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 · Structured error.

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"
  ]
}
412 · Structured error.

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 · Structured error.

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"
  ]
}
428 · Structured error.

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 · Rate limit; honor Retry-After.

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 · Outcome may be unknown. Keep operation key and reconcile.

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"
  ]
}