Requires appointments:write, an Idempotency-Key and a key with the booking API switched on. Books the slot through the same booking code the web app uses, so the practice sees it in the diary at once; the end is the start plus the type's duration, and the slot must be one GET /appointments/availability offers (else 409 booking_conflict). Any meeting type but a class can be booked, including video, types that need a room or other resource, and types synced to external calendars; class types are refused with 422. A type with a deposit set is booked like any other: no deposit is taken or requested. The client is told by the practice's usual confirmation unless hold is sent. A priced type (price above zero) also needs payments:write, and priced bookings enabled for the environment (else 422); the booking's invoice is then issued for the full price, open, with no online pay link, and its id is answered as invoiceId. Nothing is charged: record the payment you take with POST /invoices/payment-records. Repeating a request with the same Idempotency-Key and body answers 200 with replayed true and books nothing again; the same key with a different body (a different note included) is 409 idempotency_conflict. A request that failed part-way is finished by repeating it with the same key.
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
400A field not listed, a non-string reference field, missing client or type, a startDate that is not an RFC 3339 real calendar date, a malformed hold or note, or a missing Idempotency-Key.
403Missing scope (payments:write for a priced type), or a practitioner whose diary you may not book.
404Client, type, case, location or practitioner not found, not in your practice, or not assigned to the practitioner.
409The slot is not offered or was taken (booking_conflict), or the Idempotency-Key was used with another body or its first request is still running (idempotency_conflict).
422A class type, a type with no usable duration, or a priced type that cannot be booked here (priced bookings disabled, a taxed or non two-decimal price).
503The booking API is not enabled for this key, or is temporarily unavailable.
