Booking.com Demand API (3.1)

Our Demand API offers a wide range of functionalities for Affiliate Partners to be able to retrieve accommodation, car rental and flights information from Booking.com inventory.

- Based on basic REST principles, our endpoints return JSON data directly from our system.
- You can consume them directly through HTTPS calls, using the POST method.

Download OpenAPI description
Languages
Servers
Production environment
https://demandapi.booking.com/3.1/
Sandbox environment
https://demandapi-sandbox.booking.com/3.1/

Accommodation

This API collection is specific for the stay part of the connected trip.

Use these endpoints to look for accommodation such as hotels, apartments, etc, check their availability, reviews, accommodation details, etc.

Operations

Car rentals

This API collection is specific to the car rentals part of the connected trip, and form part of an early access pilot programme restricted to selected partners.

Pilot phase:
- All the functionalities are currently under active development and are subject to change.
- Initial search, look, and post-book functionalities (Type 2 and Type 4 partners) are available exclusively for testing purposes.
- General availability is targeted for Q2 2025.

Limited access:
- This API collection is currently accessible only to a select group of Type 2 and Type 4 pilot partners.
- If you are not part of the pilot, you will not have access to these endpoints.
- For inquiries regarding participation, please contact our Partnerships team.

Frequent updates:
These endpoints and documentation will be updated regularly throughout the pilot.

Operations

Locations

These are the endpoints you can use to retrieve the identifiers of a wide range of geographical locations: airports, countries, cities, regions, etc.

Use these identifiers to construct your requests.

Note: These identifiers are available across all travel services and you can use them for both accommodotation and car rentals requests.

Operations

Payments

Generic endpoints related to payments and finance: currencies, payment types, etc.

Operations

Languages

Use this endpoint to retrieve the list of available language codes.

Operations

Orders

These endpoints enable you to manage and process booking orders within the Demand API. These operations include previewing and creating new orders, checking order details, cancelling existing orders, and modifying orders if needed.

This API collection is essential for integrating the order management functionality, such as handling bookings, cancellations, and updates to reservation details, etc.

Operations

Messages

This API collection is specific to Messaging integrations, and form part of an early access pilot programme restricted to selected partners.

Pilot phase:
- All the functionalities are currently under active development and are subject to change.
- Initial post-booking functionalities are available exclusively for testing purposes.
- General availability is targeted for Q3 2025.

Limited access:
- This API collection is currently accessible only to a select group of pilot partners.
- If you are not part of the pilot, you will not have access to these endpoints.
- For inquiries regarding participation, please contact our Partnerships team.

Frequent updates:
These endpoints and documentation will be updated regularly throughout the pilot.

Operations

Conversations

Endpoints to retrieve and manage messaging conversations.

Operations

Attachments

Endpoints for uploading and retrieving message attachments.

Operations

Download a message attachment

Request

Retrieves a file that was attached to a message. The response includes the file's content as a base64-encoded string.

Headers
X-Affiliate-Idintegerrequired

Include here your Affiliate identifier number

Bodyapplication/json
conversationstringrequired

The unique identifier of the conversation that contains the attachment.

accommodationstringrequired

The unique identifier of the property where the conversation occurred.

attachmentstringrequired

The unique identifier of the attachment to download.

curl -i -X POST \
  https://demandapi.booking.com/3.1/messages/attachments/download \
  -H 'Authorization: Bearer <YOUR_string_HERE>' \
  -H 'Content-Type: application/json' \
  -H 'X-Affiliate-Id: 0' \
  -d '{
    "conversation": "8586a789-44f4-5521-9f27-f5efd097cba6",
    "accommodation": "6819547",
    "attachment": "9635be40-1dc6-11f0-8893-0130f0cdef6d"
  }'

Responses

Attachment successfully retrieved.

Bodyapplication/json
request_idstring

A unique ID for this request. Please include this when contacting support.

dataobject
Response
application/json
{ "request_id": "773e2c0d-1ab3-449b-b88a-3d6b5ce09ae7", "data": { "conversation": "8586a789-44f4-5521-9f27-f5efd097cba6", "file_content": "/9j/4AAQSkZJRgABAQACWAJYAAD/2wCEAAgGBgc..." } }

Retrieve attachment metadata

Request

Returns metadata for a file uploaded in a message, including its name, type, and size.

Headers
X-Affiliate-Idintegerrequired

Include here your Affiliate identifier number

Bodyapplication/json
conversationstringrequired

The unique identifier of the conversation that includes the attachment.

accommodationstringrequired

The unique identifier of the property associated with the conversation.

attachmentstringrequired

The unique identifier of the attachment whose metadata is being requested.

curl -i -X POST \
  https://demandapi.booking.com/3.1/messages/attachments/metadata \
  -H 'Authorization: Bearer <YOUR_string_HERE>' \
  -H 'Content-Type: application/json' \
  -H 'X-Affiliate-Id: 0' \
  -d '{
    "conversation": "8586a789-44f4-5521-9f27-f5efd097cba6",
    "accommodation": "6819547",
    "attachment": "9635be40-1dc6-11f0-8893-0130f0cdef6d"
  }'

Responses

Successful response.

Bodyapplication/json
request_idstring

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

dataobject
Response
application/json
{ "request_id": "fec1a9bb-9c85-42fc-a109-3707e1ed4de7", "data": { "metadata": {} } }