1. Buying on TravelgateX
  2. Getting started with Hotel-X

Best Practices

Read on for tips and best practices that will help you make the most of your connection

Content calls

Sellers' static information as Hotel List, Room List, Board List... are returned through our content calls.
We strongly recommend to implement them as sometimes, Seller codes might be different from the ones returned through our API. 

Gzip Compression

In order to increase performance and save bandwidth, all LIVE traffic must (it is mandatory) enable GZIP compression in the HTTP header.

TravelgateX FTP

One of the biggest features of Hotel-X is the possibility of customize your requests by adding Apps.
Each App require a different set of files to be uploaded on our FTP in order to configure it.
In case you want to configure any of our App, raise a ticket on our Help Center requesting your FTP credentials.

TravelgateX Status

Offering an event tracker and consistent metrics, our Status page allows you to stay informed of our services performance in real time.

Keep Alive Header

In order to increase performance and improve response times (in Search), you can add the Connection: keep-alive header to all our transactions.

GraphQL To Rest

In case you expect to have +5k options returned per search response, we suggest using our GraphQL to Rest feature to keep performance at the highest level.
To implement this feature, please follow below steps:
  1. Check that your JSON parser is updated to the last schema as the Array. Fields previously defined as single Scalars can produce unexpected JSON marshalling.
  2. Add the HTTP header to your request(s): TGX-Content-Type:graphqlx/json
  3. Test a sample call for every request using the header
  4. Enjoy the performance

Criteria Search

When performing a Search query, we recommend adding the following fields in the criteria section:
  • Check-in
  • Check-out
  • Hotels
  • Occupancies
  • Language
  • Currency
  • Nationality
  • Market
Bear in mind that:
If currency is not introduced the default one will be applied. Note that even if introducing a specific currency, Sellers might return a different one.
Sellers might return different rates depending on the market. 

Reservation Status

When making a reservation, there will be a field named “status” in the response indicating the status of the reservation. It can have four values:

  • OK: The reservation was completed with no problems.
  • RQ: The reservation was completed but the product is still not available, so the reservation goes into a waiting list (Request). It is the Buyer’s responsibility to check the final status of the booking.
  • CN: The reservation was completed but due to a Seller error or a timeout the system will immediately cancel the reservation to prevent further possible errors.
  • UN: The reservation was completed but due to a Seller error or a timeout, the reservation status is unknown. It is the Buyer’s responsibility to check if the booking is OK.

If the Buyer experience any of the common errors (or any status different to OK), mentioned in the previous point, during the Book process. It is the Buyer's responsibility to check the final Status of the Booking.

Improve GraphQL Performance

Visit our blog for some tips to improve GraphQL performance when responses contain more than 10.000 nodes and/or weight more than 1Mb.

Cancellation Status

When making a reservation, there will be a field named “status” in the response indicating the status of the reservation. It can have four values:
  • RQ: The cancellation was completed but the cancel is still not available, so the reservation goes into a waiting list (Request). It is the Buyer’s responsibility to check the final status of the cancellation.
  • CN: The cancellation was completed.
  • UN: The cancellation was completed but due to a Seller error or a timeout, the cancellation status is unknown. It is the Buyer’s responsibility to check if the cancellation is CN.

If the Buyer experience any of the common errors (or any status different to CN), mentioned in  the previous point, during the Cancellation process. It is the Buyer's responsibility to check the final Status of the Cancellation.