---
title: "City by ID"
method: GET
path: "/cities/{id}"
tags: ["Geography"]
---

# City by ID

`GET /cities/{id}`

## Request

- Base URL: `https://api-dev.despegar.com/v3`
- URL: `https://api-dev.despegar.com/v3/cities/{id}`
- Auth: API key in header `x-apikey`

Returns the details of a specific city identified by its internal numeric ID.

## Path parameters

- `id` string, required

## Query parameters

- `product` string, required
- `language` string, required
- `ratio` string

## Response `200`

OK

- object
  - `id` string: Internal numeric identifier of the city.
  - `gid` string: Global identifier combining type and id. E.g.: `CIT_982`.
  - `code` string: IATA or internal code of the city. E.g.: `BUE`, `BRC`.
  - `descriptions` object: Localized city names keyed by language code.
  - `aliases` string[]: List of alternative names for the city. Not always present.
  - `timezone` string: IANA timezone identifier for the city. E.g.: `America/Sao_Paulo`.
  - `timezone_offset` number: UTC offset of the city's timezone in hours. E.g.: `-3.0`.
  - `administrative_division_id` string: Internal numeric identifier of the administrative division the city belongs to.
  - `administrative_division_gid` string: Global identifier of the administrative division. E.g.: `ADM_31655`.
  - `country_id` string: Internal numeric identifier of the country.
  - `country_gid` string: Global identifier of the country. E.g.: `COU_20010`.
  - `location` object: Geographic location of the city. Can be a `POINT` (single coordinate) or a `POLYGON` (boundary with coordinate list). `POINT` responses do not include a `coordinates` array.
    - `type` 'POINT' | 'POLYGON': Geometry type. Either `POINT` or `POLYGON`.
    - `latitude` number: Reference latitude of the city.
    - `longitude` number: Reference longitude of the city.
    - `coordinates` object[]: List of points defining the polygon boundary. Only present when `type` is `POLYGON`.
      - `type` 'POINT': Geometry type. Always `POINT`.
      - `latitude` number: Latitude coordinate.
      - `longitude` number: Longitude coordinate.
  - `configurations` string[]: List of product and platform configurations in which this city is available. Values may include product-specific bus configurations such as `any_buses_ar`, `any_buses_br`, or `any_buses_cl`.
  - `pictures` object[]: List of pictures associated with the city. Always empty.
  - `last_update_date` string, date-time: Date and time of the last update to this record.

## Other responses

- `400`: Bad Request. A required parameter is missing or invalid.
- `401`: Unauthorized. The request is missing a valid API key.
- `404`: Not Found. No city found for the given ID.
- `500`: Internal Server Error.

---

[API](https://skmtc.dev/despegar/apis/geography-api.md) - [All operations](https://skmtc.dev/despegar/apis/geography-api/llms.txt) - [OpenAPI document](https://skmtc.dev/despegar/apis/geography-api/revisions/68ba7194d527?raw)
