Book an appointment
/api/book/{slug}/appointmentsPublic guest checkout. The requested slot is checked again server-side (not in the past, inside the staff member's working hours, not inside a blocked period), because nothing stops a direct POST inventing a slot the booking page never offered. Overlap is enforced by the database.
The client record is matched on email, so a returning customer builds up history on one record. notes goes on this booking, never on the client record.
This route checks only that the business is active; it is the hospitality endpoints that refuse a business running the other engine.
Path Parameters
The organization's public booking slug, i.e. the {slug} in /{slug}. Only orgs with status active resolve; anything else is a 404.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/book/string/appointments" \ -H "Content-Type: application/json" \ -d '{ "providerId": "4834bcdc-4a64-444d-966b-1a6fe381da24", "startsAt": "2019-08-24T14:15:22Z", "customer": { "name": "string", "email": "user@example.com" } }'{ "appointment": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "starts_at": "2019-08-24T14:15:22Z", "ends_at": "2019-08-24T14:15:22Z" }, "calendar": { "googleCalendarUrl": "http://example.com", "icsUrl": "http://example.com" }, "promotion": { "kind": "sale", "discountCents": 0 }, "lines": [ { "serviceId": "8f8bb40f-b96b-40fe-9064-5031fbe483f9", "providerName": "string" } ]}Join the waitlist for a full day (public, appointments)POST
One service, one day, any team member or one named, an optional time window. Only a day availability answers `full` for can be joined. Nothing is held. When a time this guest could really book opens up, they are emailed a link to it, and the first one back gets it. Joining again with the same email, service, day and team member returns the existing entry.
Preview a promo codePOST
A preview, so a booking page can confirm a code and show its discount before the guest fills in their details. Never creates or charges anything: `POST /api/book/{slug}/appointments` checks the same code again under the same rules, and only that answer is ever charged. A "valid" preview can still be refused at checkout, for example a once-per-customer code the guest has already used, since this route has no customer to check yet. Rate limited on the tighter guest write budget, 30 requests a minute: a code is a short, guessable string, and this is the one endpoint that tests a guess without booking anything.