TripAdvisor API endpoint
Returns the values TripAdvisor place and listing filters accept: `locales`, `currencies`, `languages`, `listing_types`, `sorts`, `pricing_modes`, `hotel_classes`, `hotel_amenities`, `restaurant_types`, `restaurant_options`, attraction categories with their ids, and `filter_ids`. It also lists `unsupported_entity_types`. Takes no parameters.
/tripadvisor/enumsReturns supported TripAdvisor enum values for place and listing filters.
Query parameters: none.
Notable response behavior: this metadata endpoint has a billing credit cost of 0.
| Field | In the sample | Value in the sample |
|---|---|---|
| locales | Has a value | 17 entries |
| currencies | Has a value | 23 entries |
| sorts | Has a value | 2 entries |
| languages | Has a value | 15 entries |
| listing_types | Has a value | 22 entries |
| attraction_categories | Has a value | 11 entries |
| attraction_category_ids.attraction | Has a value | |
| attraction_category_ids.class_workshop | Has a value | |
| attraction_category_ids.concert_show | Has a value | |
| attraction_category_ids.day_trip | Has a value | |
| attraction_category_ids.event | Has a value | |
| attraction_category_ids.food_drink | Has a value | |
| attraction_category_ids.outdoor_activity | Has a value | |
| attraction_category_ids.shopping | Has a value | |
| attraction_category_ids.tour | Has a value | |
| attraction_category_ids.transportation | Has a value | |
| attraction_category_ids.traveler_resource | Has a value | |
| unsupported_entity_types | Has a value | 11 entries |
| hotel_classes | Has a value | 5 entries |
| hotel_amenities | Has a value | 2 entries |
| pricing_modes | Has a value | 1 entry |
| restaurant_options | Has a value | 2 entries |
| restaurant_types | Has a value | 1 entry |
| filter_ids | Has a value |
| Parameter | Type | Required | Default | Description | Example |
|---|---|---|---|---|---|
| x-api-key (header) | string | Yes | API key required |
curl -X GET "https://api.crawlora.net/api/v1/tripadvisor/enums" \ -H "x-api-key: $CRAWLORA_API_KEY"
{
"code": 200,
"msg": "OK",
"data": {
"locales": [
"en-HK",
"en-US",
"en-GB"
],
"currencies": [
"HKD",
"USD",
"EUR"
],
"languages": [
"en",
"fr",
"zh-CN"
],
"listing_types": [
"hotel",
"restaurant",
"attraction"
],
"attraction_categories": [
"attraction",
"tour",
"day_trip"
],
"hotel_classes": [
1,
2,
3,
4,
5
],
"filter_ids": [
"class",
"ufe"
]
}
}Request schema
No body schema
Response schema
#/definitions/tripadvisor.tripadvisorEnumsResponseDoc
| Field | Type | Required | Enum | Bounds | Example | Description |
|---|---|---|---|---|---|---|
| code | integer | No | 200 | |||
| data | tripadvisor.EnumsResponse | No | ||||
| data.attraction_categories | array | No | attraction,tour,day_trip | Attraction category types accepted by the `type` parameter of the search endpoint. | ||
| data.attraction_category_ids | object | No | [object Object] | Map from each attraction category type to its TripAdvisor category id, for example `tour` to `c42`. | ||
| data.currencies | array | No | HKD,USD,EUR | Currency codes accepted by the `currency` parameter, for example `HKD`. | ||
| data.filter_ids | array | No | class,ufe | Filter ids accepted by the `filter_id` parameter. | ||
| data.hotel_amenities | array | No | 9176,9179 | Hotel amenity ids accepted by the `amenities` parameter. | ||
| data.hotel_classes | array | No | 1,2,3,4,5 | Hotel star classes accepted by the `class` parameter. | ||
| data.languages | array | No | en,fr,zh-CN | Review language codes accepted by the reviews endpoint, for example `en`. | ||
| data.listing_types | array | No | hotel,restaurant,attraction | Listing types accepted by the `type` parameter of the search endpoint, for example `hotel`. | ||
| data.locales | array | No | en-HK,en-US,en-GB | Locale codes accepted by the `locale` parameter, for example `en-HK`. | ||
| data.pricing_modes | array | No | ALL_IN_RATE | Pricing modes accepted by the `pricing_mode` parameter. | ||
| data.restaurant_options | array | No | 20693 | Restaurant online-option ids accepted by the `online_options` parameter. | ||
| data.restaurant_types | array | No | 10591 | Restaurant establishment-type ids accepted by the `establishment_types` parameter. | ||
| data.sorts | array | No | BEST_VALUE,POPULARITY | Sort orders accepted by the `sort` parameter, for example `BEST_VALUE`. | ||
| data.unsupported_entity_types | array | No | airline,airport | Entity types that cannot be searched, for example `airline`. Omitted when none. | ||
| msg | string | No | OK |
| Status | Description | Schema |
|---|---|---|
| 429 | Rate limit exceeded | #/definitions/app.Response |
| 500 | Internal server error | #/definitions/app.Response |
Use environment variables for secrets and keep Crawlora API keys server-side.
curl -X GET "https://api.crawlora.net/api/v1/tripadvisor/enums" \
-H "x-api-key: $CRAWLORA_API_KEY"