Hotels
Hotels
The Hotels service returns a list of hotel offers for the destination and departure flight date specified.
The latest version number of the Hotels hotels resource is v1.
You can try this live service using I/O docs if you Register or Sign in with your Mashery ID.
Version Information
The most recent version of the Hotels API is version 1. Previous versions are shown below.
Version | Status | End-of-life date |
---|---|---|
v1.0 | Current | N/A |
API Endpoints
Hotels has a REST API endpoint. Click here for more information on using British Airways Rest APIs.
The endpoints available are:
Endpoint | URL |
---|---|
Live | https://api.ba.com/rest-v1/v1/hotels |
Test | N/A |
API Methods
Method | URL Resource | Description |
---|---|---|
GET | hotels;countryCode=US;cityCode=SFO;checkInDate=2014-01-24T12:00:00Z;checkOutDate=2014-01-25T12:00:00Z; | Returns hotel offers for the desired city and check-in/out dates specified |
GET | hotels;countryCode=AU;cityCode=SYD;checkInDate=2014-01-14T12:00:00Z;numberOfNights=1; |
Returns hotel offers for the desired city, check-in date and specified number of nights |
GET | hotels;countryCode=IT;cityCode=FCO;checkInDate=2014-01-13T12:00:00Z;checkOutDate=2014-01-15T12:00:00Z;starRating=5; | Returns hotel offers for the desired city, check-in/out dates and hotel rating specified |
GET | hotels;countryCode=AU;cityCode=SYD;checkInDate=2014-01-14T12:00:00Z;numberOfNights=2;isAirportHotel=Y | Returns hotel offers for the desired city, check-in date, number of Nights and whether airport hotel specified |
GET | hotels;countryCode=IT;cityCode=FCO;checkInDate=2014-01-13T12:00:00Z;checkOutDate=2014-01-15T12:00:00Z;starRating=5;isAirportHotel=Y | Returns hotel offers for the desired city, check-in/out dates, airport hotel and starRating |
HTTP Headers
Header Name | Description | Mandatory? | In/Outbound | Example |
---|---|---|---|---|
client-key | Your unique key used to authorise access to the API. | Yes | Inbound | n/a |
Search Parameters
The various search parameters are described below:
Name | Description | Format | Default | Example | Allowed values |
---|---|---|---|---|---|
countryCode | Country of the City | IATA 2 character country code |
N/A | US | |
cityCode | City where the hotel should be located | IATA 3 character city code | N/A | SFO | Valid British Airways served airports |
checkInDate | Date of Check-in | YYYY-MM-DDTHH:MM:SSZ | N/A | 2014-01-10T12:00:00Z | => today and <= today + 365 |
checkOutDate | Date of Check-out | YYYY-MM-DDTHH:MM:SSZ | N/A | 2014-01-10T12:00:00Z | => today and <= today + 365 |
numberOfNights | How many nights room is required | numeric | N/A | 7 | Any single digit number |
starRating | Star rating of the hotel | numeric | N/A | 5 | Any single digit number |
isAirportHotel | Whether hotel should be at airport or not | single character | N/A | Y | Y or N only |
starRating, boardBasis and isAirportHotel are optional.
Either checkOutDate OR numberOfNights must be specified but if both are specified, only the first one is used.
Search parameters may be submitted in any order and are case insensitive.
Supported Status Codes
You can view the standard status codes returned by our APIs here.
Docs Navigation
- Docs
- Avios Documentation
- Getting started with our API
- Aggregator / Service Providor
- Seller Direct Connect
- Seller using Aggregator / Service Provider
- AirShopping
- FlightPrice/OfferPrice
- BaggageList / ServiceList
- SeatAvailability
- OrderCreate
- AirDocIssue
- OrderRetrieve
- OrderChange
- ItinReshop
- OrderCancel
- OrderList
- OrderView RS
- Countries, Currencies and FOPs Supported
- Passenger Types, Special Service Request and Special Discounts
- API Plans Landing Page