Book
Perform a booking by providing the product, interval, occupancy and form values. If the booking is successful, a reference and booking ID will be returned. If a payment URL is included in the response, the user should be redirected to that URL to complete the booking.
Body
coupon_codesrequiredArray<string>The coupon codes entered for the booking.
currencyrequiredCurrency | nullThe currency to use for the booking. Defaults to the product's currency. See the widget docs for the allowed values.
failure_urlrequiredstringThe URL to redirect the user to when a booking payment fails. Defaults to the booking page.
form_valuesrequiredRecord<string, string | number | boolean | null | Record<string, string | null>>Values for each of the form fields. The keys refer to services.id, the values should be valid values for each of these services.
intervalrequired{ start: string, end: string }The interval to book.
languageLanguageThe user's preferred language.
occupancyrequiredRecord<uuid, integer>The occupancy for each capacity group. The keys refer to capacity_groups.id, the values are the number of guests for that group.
product_idrequireduuidThe identifier of the product to book.
redirect_urlrequiredstring | nullThe URL to redirect the user to after the booking is completed.
show_pending_asrequired"CONFIRMED" | "TENTATIVE" | "CANCELLED"How to interpret pending events when checking if the booking is possible. Defaults to TENTATIVE
Responses
201Information identifying the booking. If a payment URL is set, the user should be redirected to that URL to complete the booking.
{
booking_id: uuid;
payment_expiry_timestamp: number | null;
payment_url: string | null;
reference: string;
secret: string;
}POST /bookcurl -X POST "https://api.bookingmood.com/v1/book" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"form_values": {
"00000000-0000-0000-0000-000000000000": {
"first_name": "John",
"last_name": "Doe"
},
"00000000-0000-0000-0000-000000000001": {
"city": "Anytown",
"country": "US",
"street": "123 Main St",
"zip": "12345"
},
"00000000-0000-0000-0000-000000000002": "+31612345678"
},
"interval": {
"start": "2026-10-30",
"end": "2026-11-03"
},
"occupancy": {
"00000000-0000-0000-0000-000000000000": 1
},
"product_id": "00000000-0000-0000-0000-000000000000"
}'{
"booking_id": "00000000-0000-0000-0000-000000000000",
"payment_url": null,
"reference": "ABC123",
"secret": "SECRET"
}