> ## Documentation Index
> Fetch the complete documentation index at: https://docs.anysite.io/llms.txt
> Use this file to discover all available pages before exploring further.

# /despegar/places/search

> Resolve a city, airport, hotel or point of interest name into Despegar geo identifiers. Returns ranked matches with the geo id (e.g. CIT_982 for a city, AIR_192636 for an airport, HOT_335526 for a hotel, POI_531400 for a point of interest), the plain numeric id, place type, city code, airport IATA code, display name, parent country, city and administrative-division ids and coordinates. Use the returned ids as the destination for hotel and activity search. Pick the product the place is resolved for (hotels or activities) to bias which matches surface; the returned geo ids are usable across products.

**Price:** 1 credit

**⚠️ Common errors:** 412: No places matched the given keyword



## OpenAPI

````yaml /openapi/travel-hospitality.json post /api/despegar/places/search
openapi: 3.1.0
info:
  title: Any Site API
  description: >+
    Any Site API provides programmatic access to data from LinkedIn, Instagram,
    Twitter, and other platforms.


    ## Authentication


    All API endpoints require an `access-token` header with a valid API token.
    Tokens can be created in the [dashboard](https://app.anysite.io/).


    ## Pricing


    Each endpoint has a credit cost listed in its description. Credits are
    deducted from your token balance per request.

  version: 0.0.1
servers: []
security:
  - AccessToken: []
paths:
  /api/despegar/places/search:
    post:
      tags:
        - /despegar
      summary: /despegar/places/search
      description: >-
        Resolve a city, airport, hotel or point of interest name into Despegar
        geo identifiers. Returns ranked matches with the geo id (e.g. CIT_982
        for a city, AIR_192636 for an airport, HOT_335526 for a hotel,
        POI_531400 for a point of interest), the plain numeric id, place type,
        city code, airport IATA code, display name, parent country, city and
        administrative-division ids and coordinates. Use the returned ids as the
        destination for hotel and activity search. Pick the product the place is
        resolved for (hotels or activities) to bias which matches surface; the
        returned geo ids are usable across products.


        **Price:** 1 credit


        **⚠️ Common errors:** 412: No places matched the given keyword
      operationId: __api_despegar_places_search_post
      parameters:
        - name: access-token
          in: header
          required: true
          schema:
            anyOf:
              - type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DespegarPlacesSearchPayload'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/DespegarPlace'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    DespegarPlacesSearchPayload:
      properties:
        timeout:
          type: integer
          maximum: 1500
          minimum: 20
          default: 300
        region:
          $ref: '#/components/schemas/DespegarRegion'
          default: AR
        keyword:
          type: string
          minLength: 1
        product:
          $ref: '#/components/schemas/DespegarPlaceProduct'
          default: hotels
        count:
          type: integer
          minimum: 1
      type: object
      required:
        - keyword
        - count
    DespegarPlace:
      properties:
        '@type':
          type: string
          default: DespegarPlace
        id:
          type: string
        geo_id:
          anyOf:
            - type: string
            - type: 'null'
        place_type:
          anyOf:
            - type: string
            - type: 'null'
        code:
          anyOf:
            - type: string
            - type: 'null'
        iata:
          anyOf:
            - type: string
            - type: 'null'
        name:
          anyOf:
            - type: string
            - type: 'null'
        country_id:
          anyOf:
            - type: string
            - type: 'null'
        city_id:
          anyOf:
            - type: string
            - type: 'null'
        administrative_division_id:
          anyOf:
            - type: string
            - type: 'null'
        latitude:
          anyOf:
            - type: number
            - type: 'null'
        longitude:
          anyOf:
            - type: number
            - type: 'null'
      type: object
      required:
        - id
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
      type: object
    DespegarRegion:
      type: string
      enum:
        - AR
        - BO
        - CL
        - CO
        - CR
        - EC
        - SV
        - GT
        - MX
        - NI
        - PA
        - PY
        - PE
        - PR
        - US
        - UY
    DespegarPlaceProduct:
      type: string
      enum:
        - hotels
        - activities
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
        msg:
          type: string
        type:
          type: string
        input: {}
        ctx:
          type: object
      type: object
      required:
        - loc
        - msg
        - type
  securitySchemes:
    AccessToken:
      type: apiKey
      in: header
      name: access-token
      description: API token from the dashboard

````