Skip to main content
POST
Book a customer into a class

Authorizations

Authorization
string
header
required

Organization-scoped bearer credential: a customer API key (1club_sk_live_...) or an MCP OAuth access token.

Headers

Idempotency-Key
string

Retry-safe key; a repeat of the same request replays the first response

Maximum string length: 255

Path Parameters

id
integer
required

Class occurrence id (from GET /v1/platform/classes)

Body

application/json
payment
object
required
contactId
integer

Existing contact to book for (from GET /v1/platform/contacts). Mutually exclusive with customer.

customer
object

Inline find-or-create by email. Mutually exclusive with contactId.

notes
string
Maximum string length: 2000
notifyCustomer
boolean

Tell the customer they are booked - email plus the in-app, WhatsApp and SMS notification. Off by default for an API key, on by default over an OAuth connection, as on POST /v1/platform/bookings.

Response

Booking created

A booking created through the platform API. Recorded with a booking transaction so it counts for revenue, marked paid (settled against a payment method named after the caller's API key, so the club can reconcile what each partner collected) or unpaid (outstanding) per the caller. Collection stays with the caller; what it collected and what it gave back on cancellation are reported in payment.

bookingId
integer

1club booking id

bookingUuid
string<uuid>

Stable unguessable identifier. Prefer this over bookingId when storing a reference.

status
string

Booking status (e.g. confirmed, cancelled)

areaId
integer | null

Area id

classId
integer | null

The class occurrence this booking attends, when it is a class booking. Every attendee holds their own booking row against the same classId, and classes rows are per-occurrence - so this is what tells two classes running in the same hour apart. Join it against GET /v1/platform/classes, or read the roster with GET /v1/platform/classes/{id}/bookings.

eventId
integer | null

The event this booking attends, when it is an event booking

maxPlayers
integer | null

How many players the booking takes, the organizer included, when it differs from the area type's defaultMaxPlayers: 2 on a court booked for singles (area types with allowsSingles). null means the area type's own limit. Adding a player past it is refused.

instructorId
integer | null

Instructor leading the session, when one is attached

contactId
integer | null

Contact the booking is for

startTime
string<date-time>
endTime
string<date-time>
customer
object | null

The booking's customer, identical to what GET /v1/platform/contacts/{id} returns. Present only when the request passes include=customer, which additionally requires the contacts:read scope; null when the booking has no contact. Use it to import a window of bookings without a contact lookup per row.

money
object

What the booking costs and how it was paid. Present only with include=money, which additionally requires the transactions:read scope. billed is always paid + outstanding, on the same basis as the admin's Booking audit: tax-inclusive, net of refunds, so a cancelled booking bills only the Cancellation Charge it kept.

cancellation
object

The cancellation terms stamped on the booking and how it was cancelled. Present only with include=cancellation.

payment
object