Last updated

Overview


Enable travellers to book and pay for the products they have chosen. Manage bookings from your application.

The /orders API

The /orders API is a subset of Demand API endpoints that provides the following functionality:

  • Booking: Enable travellers to book the products they have chosen directly in your application, instead of having to redirect them to Booking.com.
  • Post-booking: Get information about bookings, cancel bookings, and perform other post-booking tasks.

Note: The /orders API is vertical-agnostic.

You will need to use /orders endpoints if your application implements either or both of the following application flows.

drawing

Endpoints

The following sections briefly describe the available endpoints and their purpose.

Create orders

Create an order for the products a traveller has chosen to book (as part of a search, look and book application flow):

  • /orders/preview - Get final price and payment information, so that you can check that all details are correct before creating the order.
  • /orders/create - Using the information from /orders/preview, book the requested products and process payment (as per the chosen method) for the order.

For more information about how to use these endpoints, see /orders/preview and /orders/create.

Manage orders

Get the information required about orders to perform various post-booking tasks, such as reporting commission or managing a loyalty program:

  • /orders/details - Get basic information about an order. For some tasks this endpoint provides all the information you need. For example, managing loyalty rewards.
  • /orders/details/accommodations - Get information about the accommodation-specific part of an order. You may want this, for example, to assist a customer with an enquiry

For more information about how to use these endpoints, see /orders/details/*.

Cancel orders

Features

Order preview

Previewing the order before creating it provides a streamlined, transparent and efficient booking process. The /orders/preview endpoint provides:

  • The accurate final price and available payment options for the order, based on the included products.
  • A unique order token, which contains encapsulated information needed to create the order. You pass this token to the /orders/create request instead of having to rebuild the order information again, reducing the risk of data errors.

Extensive payment options

The Demand API supports a range of payments features designed to optimise the booking experience for both partners and travellers.

Support for these features is built into the /orders endpoints, so that you can provide travellers with the necessary information on when and how they can pay, and process their chosen payment option.

For more information, see Payments.