Retrieve hotels review by IDs
https://api.worldota.net/api/content/v1/hotel_reviews_by_ids/
In this call can get reviews on the requested hotel IDs.
ℹ️
- Use this call instead of call Retrieve hotel reviews’ dump.
- Use this call after Retrieve hotels content by IDs.
Request example
ℹ️
Only one of HIDs or IDs can be specified in the request.
curl --user '<KEY_ID>:<API_KEY>' 'https://api.worldota.net/api/content/v1/hotel_reviews_by_ids/' \
--header 'Content-Type: application/json' \
--data '{
"hids": [6291688,
6296387,
6296716,
6303545,
6303742,
6304320,
6304603,
6304886,
6304887,
6314064,
6314532,
6315546,
6317902,
6333750,
6334068,
6344525,
6352359,
6353673,
6374316],
"language": "en"
}'
curl --user '<KEY_ID>:<API_KEY>' 'https://api.worldota.net/api/content/v1/hotel_content_by_ids/' \
--header 'Content-Type: application/json' \
--data '{
"ids": [
"hotel_1",
"hotel_2",
"hotel_3",
"hotel_4",
"hotel_5"
]
"language": "en"
}'
Request body
A list of hotel IDs filtered by the criteria specified in the request.
ℹ️
- Use the
hids
field from the call Retrieve hotel IDs by filter.
The language.
ℹ️
- Use the
value
field from the call Retrieve filter values.
Response
The most preferred hotel ID.
ℹ️
- Either this field or the
id
field is required. - The maximum length is
10
characters.
A list of user reviews about the hotel.
The list of the URLs for the hotel images.
Each URL has the {size}
placeholder. Meaning, the size of the image you can get.
ℹ️
- The possible size meanings:
crop
— the image is fit by the width and is cut equally from the bottom and top till the middle part of the height.fit-h
— the image is fit into the rectangle by the height.fit
— the image is fit into the rectangle by the size in question.
- The possible values:
100x100
— crop.1024x768
— fit.120x120
— crop.240x240
— crop.x220
— fit-h.x500
— fit-h.
Detailed ratings for different aspects of the stay (see subfields below).
Type of traveller (e.g.,
solo
, couple
, family
, or unspecified
if not provided).
Response example
{
"data": [
{
"id": "hotel_1",
"hid": 6302348,
"reviews": [
{
"id": 280527,
"review_plus": "Plenty of space . good room size .",
"review_minus": "Parking is hard .",
"created": "2019-03-06 00:17:57.609789+00",
"author": "Gary",
"adults": 2,
"children": 0,
"room_name": "Double Apartment (Double bed) (2 bedrooms)",
"nights": 1,
"images": null,
"detailed_review": {
"cleanness": 10,
"location": 6,
"price": 8,
"services": 10,
"room": 0,
"meal": 0,
"wifi": "unspecified",
"hygiene": "unspecified"
},
"traveller_type": "unspecified",
"trip_type": "leisure",
"rating": 8.5
}
]
},
{
"id": "hotel_2",
"hid": 6304782,
"reviews": [
{
"id": 356735,
"review_plus": "Um... It had a pub attached.",
"review_minus": "The smell was rank. Absolutely horrendous stink! I wasted my money as I left at 2am because the smell was so disgusting I couldn’t sleep.",
"created": "2020-07-06 07:49:30.029243+00",
"author": "Kieran",
"adults": 1,
"children": 0,
"room_name": "Standard Double Suite (double bed) (queen size double bed)",
"nights": 1,
"images": null,
"detailed_review": {
"cleanness": 2,
"location": 8,
"price": 4,
"services": 6,
"room": 0,
"meal": 0,
"wifi": "unspecified",
"hygiene": "unspecified"
},
"traveller_type": "unspecified",
"trip_type": "leisure",
"rating": 5
}
]
}
}
"debug": {
"request": {
"id": [
"hotel_1",
"hotel_2"
],
"hids": [
6302348,
6304782
],
"language": "en"
},
"key_id": 1234,
"validation_error": null
},
"status": "ok",
"error": null
}
Errors
The error
field has the value specified in the headers below.
invalid_params
One or more input parameters are incorrect. For more details, see the response field debug validation_error.
no_hotel_reviews
An internal search error. Has 500
status code.