Retrieve hotel IDs by filter

Retrieve hotel IDs by filter

#content-api

https://api.worldota.net/api/content/v1/hotel_ids_by_filter/

The call gets the identifiers for all required hotels. Use fields to search only for the desired hotels.

ℹ️

Request example

curl --user '<KEY_ID>:<API_KEY>' 'https://api.worldota.net/api/content/v1/hotel_ids_by_filter/' \
--header 'Content-Type: application/json' \
--data '{
    "country": [52]
}'

Request body

Response

Response example

{
  "data": {
    "hids": [
      6325458,
      6445894,
      6493239,
      6526863,
      13350497
    ],
    "ids": [
      "hotel_1",
      "hotel_2",
      "hotel_3",
      "hotel_4",
      "hotel_5"
    ]
  },
  "debug": {
    "request": {
      "serp_filter": [
        "air_conditioning",
        "has_airport_transfer",
        "beach",
        "has_internet",
        "has_kids",
        "kitchen"
      ],
      "kind": [
        "Mini-hotel"
      ],
      "country": [
        153
      ],
      "updated_since": "2006-01-02 15:04:05"
    },
    "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_ids

An internal search error. Has 500 status code.