Skip to content

Create an order

Request

Use this endpoint to confirm the booking and proceed the payment.

Security
BearerAuth
Headers
X-Affiliate-Idintegerrequired

Include here your Affiliate identifier number

Bodyapplication/json
accommodationobject(OrderCreateAccommodationInput)

Additional information related to the accommodation order.

bookerobject(OrderCreateBookerInput)required

The booker's information.

order_tokenstringrequired

A token containing the necessary data to be used for creating this order.

paymentobject(OrderCreatePaymentInput)required

Payment related information for the order.

curl -i -X POST \
  https://demandapi.booking.com/3.1/orders/create \
  -H 'Authorization: Bearer <YOUR_string_HERE>' \
  -H 'Content-Type: application/json' \
  -H 'X-Affiliate-Id: 0' \
  -d '{
    "accommodation": {
      "label": "Sample label",
      "products": [
        {
          "id": "333",
          "bed_configuration": "123456",
          "guests": [
            {
              "email": "test.name@booking.com",
              "name": "Test Name"
            }
          ]
        }
      ],
      "remarks": {
        "estimated_arrival_time": {
          "hour": 12
        },
        "special_requests": "We will need an extra cot."
      }
    },
    "booker": {
      "address": {
        "address_line": "Road-1, house-2",
        "city": "Amsterdam",
        "country": "nl",
        "post_code": "11111"
      },
      "company": "Booking B.V",
      "email": "test.name@booking.com",
      "language": "en-gb",
      "name": {
        "first_name": "Test",
        "last_name": "Name"
      },
      "telephone": "12345678"
    },
    "order_token": "sample-token",
    "payment": {
      "card": {
        "cardholder": "Test Name",
        "cvc": "111",
        "expiry_date": "2030-10",
        "number": "23333333333333"
      },
      "include_receipt": true,
      "method": "card",
      "timing": "pay_at_the_property"
    }
  }'

Responses

Successful response.

Bodyapplication/json
request_idstring

Uniquely identifies the request. Please provide this identifier when contacting support.

dataobject(OrderCreateDataOutput)
Response
{ "request_id": "01fr9ez700exycb98w90w5r9sh", "data": { "accommodation": { … }, "payment": { … } } }