Create Booking
This endpoint allows Mozrest to create a new booking in the partner's system. The request includes necessary details such as venue, party size, date, and contact information to ensure proper reservation creation.
Endpoint
POST https://partner-domain.com/v1/mozrest/booking
Body Parameters
Parameter | Status | Description |
---|---|---|
venueId | Mandatory | The unique Venue ID as defined in the Partner's system. |
bookingChannel.id | Mandatory | Booking channel id where the customer placed the booking |
bookingChannel.name | Mandatory | Booking channel name where the customer placed the booking |
partySize | Mandatory | Number of people for the reservation (e.g., 4). |
date | Mandatory | Date and time of the booking in ISO 8601 format. |
areaId | Optional | The unique Area ID for location within the venue if applicable. |
contact.firstname | Mandatory | First name of the contact person making the booking. |
contact.lastname | Mandatory | Last name of the contact person making the booking. |
contact.email | Mandatory | Email address of the contact person. |
contact.telephone | Mandatory | Phone number of the contact person. |
contact.locale | Optional | Preferred language/locale of the contact person. |
notes | Optional | Special instructions or requests associated with the booking. |
paymentToken | Optional | Payment gateway token if prepayment is required. |
Example Request
curl POST "https://partner-domain.com/v1/mozrest/booking" \
-H "Authorization: Bearer {{api_key}}" \
--data-raw '{
"venueId": "60e890aca5f07b6ee5b950b1",
"bookingChannel": {
"id": "60e890aca5f07b6ee5b950b3",
"name": "Channel Name"
},
"partySize": 4,
"areaId": "60e5a3ed409541da3650b2d3",
"date": 1639578600,
"notes": "I am allergic to peanuts",
"contact": {
"firstname": "John",
"lastname": "Doe",
"email": "john.doe@gmail.com",
"telephone": "44344223322",
"locale": "en",
},
"optInConsent": true
},
"paymentGatewayToken": "pm_1JkkRzAY52ufXkvaHWKbasua",
}'
Example Response
{
"id": "60e890aca5f07b6ee5b950b1",
"status": "pending_confirmation"
}
Response Definitions
- id: Unique identifier for the booking.
- status: Status of the booking (e.g., "confirmed").
Booking statuses allowed
Parameter | Description |
---|---|
confirmed | Booking is confirmed |
pending_confirmation | Booking requires manually approval by de venue |
requires_payment | Booking requires payment |