Search Geo Locations
Search for geographic locations for use in ad group geo targeting.
URL
GET https://api.ads.apple.com/v1/search/geoQuery Parameters
| Name | Type | Description |
|---|---|---|
supplySource Required | SearchSupplySourceType | Supply source context for eligibility evaluation. Case-insensitive. Values: |
query Optional | string | Search string. Minimum 2 characters. The API rejects shorter values with error code |
entity Optional | GeoEntityType | Geo entity type to filter results. Values: |
countrycode Optional | string | ISO 3166-1 alpha-2 country code to scope results. When |
eligible Optional | boolean | Controls soft-block filtering. When |
offset Optional | int32 | Zero-based index of the first result to return. Defaults to |
pageSize Optional | int32 | Maximum number of results per page. Defaults to |
Header Parameters
| Name | Type | Description |
|---|---|---|
X-Ap-Context Required | string |
Response Codes
| Status | Reason | Type | Description |
|---|---|---|---|
| 200 | OK Content-Type: application/json | GeoSearchResponse | |
| 400 | Bad Request Content-Type: application/json | Error | |
| 401 | Unauthorized Content-Type: application/json | Error | |
| 403 | Forbidden Content-Type: application/json | Error | |
| 404 | Not Found Content-Type: application/json | Error | |
| 429 | Too Many Requests Content-Type: application/json | Error | |
| 500 | Internal Server Error Content-Type: application/json | Error |
Discussion
This endpoint returns a list of geographic locations matching the search criteria. To discover valid geo location identifiers by name before assigning targets to an ad group, use this endpoint. For ID-based lookup of known locations, use the POST endpoint POST /v1/search/geo (Query Geo Locations) instead.
The API sorts results alphabetically by displayName and paginates them. Each result includes a legacyId, which is a pipe-delimited string encoding the full geographic hierarchy (such as US|CA|San Francisco), and an eligibility object scoped to the requested supplySource.
Every request requires supplySource, which determines which entity types are available. See the supplySource parameter below for details.