# Search attractions

Use this endpoint to search for attractions based on a single search criterion, such as attraction IDs, cities, countries, or geographic coordinates.

Endpoint: POST /attractions/search
Version: 3.2-Beta
Security: BearerAuth

## Header parameters:

  - `X-Affiliate-Id` (integer, required)
    Include here your Affiliate identifier number

## Request fields (application/json):

  - `attractions` (array, required)
    List of attraction IDs to search for. When provided, results are limited to these specific attractions.

  - `currency` (string, required)
    ISO 4217 currency code. The list of supported currencies can be retrieved from [/common/payments/currencies](#/common/payments/currencies).

  - `dates` (object, required)
    Date range used to search for attraction availability.

  - `dates.start_date` (string, required)
    Start date of the availability period, in ISO 8601 date format (YYYY-MM-DD).

  - `dates.end_date` (string, required)
    End date of the availability period, in ISO 8601 date format (YYYY-MM-DD). Can be the same as start_date for single-day attractions.

  - `filters` (object)
    Optional filters to narrow down attraction search results.

  - `filters.rating` (object)
    Filters based on guest review ratings.

  - `filters.rating.minimum_review_score` (number)
    Minimum average guest review score, on a scale from 0 to 5.

  - `filters.rating.minimum_review_count` (integer)
    Minimum number of guest reviews required for an attraction to be included.

  - `filters.supported_languages` (array)
    Filter results by supported languages. Uses [IETF language tag codes](https://en.wikipedia.org/wiki/IETF_language_tag) in lowercase, for example "nl" for Dutch/Nederlands or "en-us" for English (US). To retrieve the full list of supported languages, call the `/common/languages` endpoint in the same Demand API version you are using.

  - `filters.categories` (array)
    Filter results by one or more attraction category IDs. Only attractions that match at least one of the specified categories are returned. If an invalid or unsupported category ID is provided, the search response will contain no results.

  - `page` (string)
    Pagination token used to retrieve the next page of results. Omit this parameter on the first request and use the value returned in `metadata.next_page` for subsequent pages.

  - `rows` (integer)
    The maximum number of results to return.

  - `sort` (object)
    Sorting options that control the order of the search results.

  - `sort.by` (string)
    Defines how the search results are sorted.
    Enum: "highest_review_score", "highest_weighted_review_score", "lowest_price_first", "most_popular", "nearest_location", "trending"

## Response 200 fields (application/json):

  - `data` (array)

  - `data.id` (string)
    Uniquely identifies an attraction.

  - `data.free_cancellation` (boolean)
    Indicates whether the attraction offers free cancellation.

  - `data.price` (object)
    Pricing information for the cheapest available adult offer for the attraction.

  - `data.price.currency` (string)
    ISO 4217 currency code. The list of supported currencies can be retrieved from [/common/payments/currencies](#/common/payments/currencies).

  - `data.price.total` (number)

  - `data.urls` (object)
    Platform-specific URLs for viewing this item.
    Example: {"app":{"detail":"booking://attractions/product?slug=prvlvlwpbs1m-moco-museum-amsterdam-official-tickets&aid=956509","search_results":"booking://attractions/searchresults?ufi=-2140479&pinned_product_i…

  - `data.urls.app` (object)

  - `data.urls.app.detail` (string)
    URL to view the attraction detail page in the app.

  - `data.urls.app.search_results` (string)
    URL to view the attraction within search results in the app.

  - `data.urls.web` (object)

  - `data.urls.web.detail` (string)
    URL to view the attraction detail page on the website.

  - `data.urls.web.search_results` (string)
    URL to view the attraction within the website search results page.

  - `metadata` (object)
    Metadata about the request.

  - `metadata.next_page` (string)
    Indicates that more results are available. Use this pagination token to retrieve the next page of results (via parameter `page`).

  - `metadata.total_results` (integer)
    The total number of results available.

  - `request_id` (string)
    Uniquely identifies the request. Please provide this identifier when contacting support.

