Places

Airports and cities near a point

Changed on

The airports (and optionally cities) closest to a place or a coordinate pair, nearest first – for finding an alternative departure airport serving the same trip. Pass either place (a code, resolved to coordinates here) or latitude+longitude, never neither.

get/v1/places/nearby

Request

  • Base URL
    https://api.wego.com
  • Auth
    • OAuth 2
      Authorization codehttps://auth.wego.com/user-auth/v2/users/oauth/authorize
      Token URLhttps://auth.wego.com/user-auth/v2/users/oauth/token
    • or HTTP bearer
  • TypeScript
    A function with typed inputs. Its response is checked against the schema.

Query parameters

placestring

Place code to search around (e.g. LON, LHR). Resolved to coordinates before the upstream call.

latitudenumber

Latitude of the point to search around, decimal degrees (-90 to 90). Give latitude and longitude together; use either this pair or place, never both.

longitudenumber

Longitude of the point to search around, decimal degrees (-180 to 180). Give latitude and longitude together; use either this pair or place, never both.

typesstring[]

Place types to resolve; repeat or comma-separate to mix.

localestring

Language tag for localized place names (e.g. en, ar). Defaults to en.

pageSizeinteger

Max results (1-50). Defaults to 50, the maximum, because this read wants the complete set of nearby places, not a page of it. The upstream returns roughly ten rows and ignores paging, so pageSize can only narrow that set, never reach further.

Response

Nearby places, nearest first, plus the origin they were measured from.

Changes

    • warning

      added the new rates_require_hotel_search enum value to the response property for the response status

    • warning

      added the new rates_require_hotel_search enum value to the response property for the response status

    • warning

      added the new rates_require_hotel_search enum value to the response property for the response status

    • warning

      added the new rates_require_hotel_search enum value to the response property for the response status

    • warning

      added the new rates_require_hotel_search enum value to the response property for the response status