Skip to content
Ads API •References / targets / Get Geo Targets

Get Geo Targets

Returns geo information filterable by query parameters. At least one query parameter must be provided.

Request

  • country_code
    string

    The country or region of a geo in ISO alpha-2 country code format.

    Default: country_code=Example: country_code=US
  • ids
    array of strings

    A list of unique identifiers for geos.

    Example: ids=5259444&ids=US%3A11214
  • types
    array of strings

    A list of geo types.

    Example: types=CITY&types=COUNTRY&types=DMA_REGION&types=POSTAL_CODE&types=REGION
  • q
    string

    Query to search by keyword via case-insensitive wildcard matching.

    Example: q=query
  • limit
    integer

    Limit or page size for a given response. The maximum limit is 50, except for when bulk uploading zip codes, where the maximum limit is 1000.

    Default: limit=50Range: 1 - 1000Example: limit=50
  • offset
    integer

    Starting position of the next record to assist in data pagination.

    Default: offset=0Example: offset=0
  • language
    string

    A two-letter ISO 639-1 language code for querying geo targets. Defaults to "en" if missing.

    Pattern: ^[a-z]{2}$Example: language=en

Response

A list of geos.

  • offset
    integer
  • page_size
    integer
  • An object that represents the geo target entity.

    • country_code
      string

      The country or region of the geo in ISO alpha-2 country code format.

      Example: "US"
    • id
      string

      A unique identifier for a geo.

      Example: "94110"
    • type
      string

      The geo type.

      Example: "DMA_REGION"
    • name
      string

      Name of the geo.

      Example: "San Francisco"
    • parent_geo_name
      string

      The parent location to this geo if it exists (e.g. city, state, or country).

      Example: "California"

Response sample

{  "offset": 0,  "page_size": 0,  "geos": [    {      "country_code": "US",      "id": "94110",      "type": "DMA_REGION",      "name": "San Francisco",      "parent_geo_name": "California"    }  ]}