/hotel - V3 migration guide
In V2, the hotels endpoint returns hotel and room data.
- By default, the endpoint returns only the
hotel_ids
of the hotels that match the supplied search criteria. - You can use the
extras
parameter to tailor the information returned to your requirements.
In V3, the equivalent endpoint is accommodations/details. This endpoint:
- By default returns more information about each accommodation than
hotels
. - Returns purely static content. It does not return any information about room availability or prices. Use the following tables to identify how to migrate request query parameters and response fields from a V2 call to the appropriate V3 equivalent.
Attention
Do not assume that mapped parameters or fields work in exactly the same way in V3 as they did in V2.
V3 is a significant redesign of the Demand API and some things work very differently. Use this documentation, the API Reference, and your own experimentation and testing to make sure that you migrate each V2 call correctly.
Request parameter mappings
Location
V2 query parameter | Equivalent V3 field |
---|---|
- | airport (new in V3) |
city_ids countries region_ids | city country region |
district_ids landmark_ids | Not available |
hotel_ids | accommodations |
Filter criteria
V2 query parameter | Equivalent V3 field |
---|---|
- | beta_features (new in V3) |
chain_ids | brands |
hotel_facility_type_ids | accommodation_facilities |
hotel_type_ids | accommodation_types |
Extra information
V2 query parameter | Equivalent V3 field |
---|---|
extras | extras |
=credit_card_exceptions =payment_details | =payment |
=hotel_description =hotel_description_formatted | =description |
=hotel_facilities | =facilities |
=hotel_info =key_collection_info | Not available The information returned by these V2 parameter values is returned in the default V3 response. |
=hotel_photos =room_photos | =photos |
=hotel_policies | =policies |
=room_facilities =room_info =room_description | =rooms |
=sustainability | Not available |
General
V2 query parameter | Equivalent V3 field |
---|---|
language | languages You can now return multiple translations in a single call to this endpoint. See Multiple language support. |
Pagination
V2 query parameter | Equivalent V3 field |
---|---|
offset | page |
rows | rows |
Response schema mappings
Result
V2 field | Equivalent V3 field |
---|---|
hotel_data | data |
hotel_id | id |
room_data | rooms |
hotel_data
V2 field | Equivalent V3 field |
---|---|
hotel_data: | data: |
additional_policies.child_min_age, additional_policies.children_allowed | policies.minimum_guest_age |
cots_and_extra_beds | policies.cots_and_beds |
address city_id, country, district_id, location.latitude, location.longitude, region_ids, zip | location |
adult_age_restrictions.max_age adult_age_restrictions.min_age | policies.maximum_checkin_age policies.minimum_checkin_age |
min_age | policies.minimum_guest_age |
book_domestic_without_cc_details | Not available V3 handles payments differently to V2. See TBSL. |
chain_id | brands |
checkin_checkout_times.checkin_from checkin_checkout_times.checkin_to checkin_checkout_times.checkout_from checkin_checkout_times.checkout_to | checkin_checkout_times |
city | Not available To obtain the city name, call /common/locations/cities using the location.city value from this response. |
class class_is_estimated exact_class number_of_reviews preferred review_score | rating |
credit_card_exceptions creditcard_required | payment.credit_card_required |
currency | currency |
deep_link_url | deep_link_url |
default_language | Not available |
email | contacts |
hotel_description hotel_important_information license_number | description |
hotel_facilities.attrs hotel_facilities.hotel_facility_type_id, | facilities |
name | Not available Use /accommodations/constants to obtain this information. |
hotel_photos.main_photo hotel_photos.tags hotel_photos.url_max300 hotel_photos.url_original hotel_photos.url_square60 | photos |
auto_tags is_logo_photo | Not available |
hotel_policies.content hotel_policies.name hotel_policies.type | Not available |
hotel_type_id | accommodation_type |
hotelier_welcome_message | Not available |
is_closed | Not available |
is_work_friendly | is_work_friendly |
key_collection_info.alternative_key_location key_collection_info.how_to_collect key_collection_info.key_location | key_collection_information |
other_text | Not available |
max_persons_in_reservation max_rooms_in_reservation | Not available |
name | name |
number_of_rooms | number_of_rooms |
payment_details | Not available |
payment_options.pay_at_the_property payment_options.pay_online | payment.timings |
ranking | Not available |
spoken_languages | spoken_languages |
sustainability | Not available |
theme_ids | themes |
url | url |
room_data
V2 field | Equivalent V3 field |
---|---|
room_data | rooms |
room_description | description |
room_facilities.room_facility_type_id | facilities |
name | Not available Use /accommodations/constants to obtain this information. |
room_id | id |
room_info | |
bathroom_count bedroom_count | number_of_rooms |
bedrooms.bed_configurations.bed_types .configuration_id .count | bed_options.bed_configuration.configuration |
bedrooms.bed_configurations.bed_types .description .description_imperial .name | Not available Use /accommodations/constants to obtain this information. |
bedrooms .description .name | Not available |
bookable | Not available |
is_work_friendly | attributes |
max_price min_price ranking | Not available |
occupancy .allow_cribs_and_extra_beds .max_cribs .max_extra_beds | cribs_and_extra_beds |
occupancy .max_adults .max_children .max_occupancy | maximum_occupancy |
room_size | size |
room_type | Not available |
room_type_id | room_type |
roomtype | Not available. Use /accommodations/constants to obtain this information. |
room_name | name |
room_photos .main_photo .tags .url_max300 .url_original .url_square60 | photos |