booking.checkout.create
View connectorPrepare a selected room and guest details for pay-at-property checkout
POST /v1/operations/booking.checkout.createHeaders
Authorization: Bearer YOUR_CONNECTOR_TOKEN
x-booking-token: YOUR_BOOKING_TOKEN
x-idempotency-key: YOUR_UNIQUE_ATTEMPT_KEY
Content-Type: application/jsonx-idempotency-key identifies one intended action. Generate a unique value, such as crypto.randomUUID(), before sending it. Use 1–128 letters, numbers, hyphens, underscores or periods. A duplicate attempt is rejected; it does not return a cached success. If a request times out, check the provider’s state before starting a new attempt with a new key. See the idempotency guide.
Use your connector bearer token and caller-held guest token in x-booking-token.
Inputs
| Parameter | Example type | Example value |
|---|---|---|
| search_ref | string | "fictional-search-ref" |
| property_ref | string | "fictional-property-ref" |
| rate_id | string | "fictional-rate" |
| guest | object | {"first_name":"Alex","last_name":"Example","email":"alex@example.com","phone":"+447700900123","country":"GB"} |
| confirm_prepare | boolean | true |
Example input
{
"search_ref": "fictional-search-ref",
"property_ref": "fictional-property-ref",
"rate_id": "fictional-rate",
"guest": {
"first_name": "Alex",
"last_name": "Example",
"email": "alex@example.com",
"phone": "+447700900123",
"country": "GB"
},
"confirm_prepare": true
}Input schema
{
"$id": "https://useajar.com/schemas/booking/checkout-create.input.schema.json",
"$schema": "https://json-schema.org/draft/2020-12/schema",
"additionalProperties": false,
"properties": {
"confirm_prepare": {
"const": true
},
"guest": {
"additionalProperties": false,
"properties": {
"country": {
"pattern": "^[A-Z]{2}$",
"type": "string"
},
"email": {
"maxLength": 254,
"minLength": 1,
"type": "string"
},
"first_name": {
"maxLength": 120,
"minLength": 1,
"type": "string"
},
"last_name": {
"maxLength": 120,
"minLength": 1,
"type": "string"
},
"phone": {
"maxLength": 40,
"minLength": 1,
"type": "string"
}
},
"required": [
"first_name",
"last_name",
"email",
"phone",
"country"
],
"type": "object"
},
"property_ref": {
"maxLength": 128,
"minLength": 1,
"type": "string"
},
"rate_id": {
"maxLength": 256,
"minLength": 1,
"type": "string"
},
"search_ref": {
"maxLength": 128,
"minLength": 1,
"type": "string"
}
},
"required": [
"search_ref",
"property_ref",
"rate_id",
"guest",
"confirm_prepare"
],
"type": "object"
}