Skip Navigation

Get Booking – GraphQL (Beta)

Why GraphQL?

Many APIs are just a façade for backend databases, so that as APIs are driving more web and mobile applications, it is natural for front-end developers to demand more access and control over backend resources.

GraphQL was developed by Facebook and is now used by GitHub and others, giving developers more control over what data they access, allowing them to design the exact API responses they need for any application at runtime – offloading API design to front-end developers, and sharing the load with back-end developers.

In short, GraphQL is a Query Language for APIs, which is a good fit for APIs designed to query (“read”) data.

As mentioned previously, the Get Booking API is designed to provide a normalized view of the Sabre reservation. In order to achieve this, we queried data from different sources within Sabre and decided that exposing Get Booking via GraphQL as an alternate option to RPC/JSON is worth exploring.

Note: Interested in knowing more about Sabre's view on API protocols/standards & GraphQL? Feel free to access the following Blog Post.

Why beta?

From an API consumer perspective Get Booking in both its RPC/JSON and GraphQL formats offers fundamentally the same capability; to view a Sabre booking in JSON format.

This means you are free to choose the solution that best meets your needs.

Sabre will continue refining the optimization techniques required for an optimal GraphQL implementation during the upcoming releases; that is why we have labeled this as a "beta" release for users who are willing to test/validate and provide feedback.

Accessing the Get Booking GraphQL endpoint

In order to use the GraphQL version of Get Booking we expose an additional schema file: booking-management-v1.graphql (users may need to remove the .txt at the end of the file).

Get Booking endpoint for accessing the GraphQL version is the following:

POST /v1/trip/orders/getBooking/graphql HTTP/1.1

Retirement plan

Due to low interest in the GraphQL format, it is set for retirement in the upcoming BM API release.