- HTTP request
- Request body
- Response body
- Authorization scopes
- LocationNames
- GeoTargets
- GeoTargetConstantSuggestion
- Try it!
Returns GeoTargetConstant suggestions by location name or by resource name.
List of thrown errors: AuthenticationError AuthorizationError GeoTargetConstantSuggestionError HeaderError InternalError QuotaError RequestError
HTTP request
POST https://googleads.googleapis.com/v18/geoTargetConstants:suggest
The URL uses gRPC Transcoding syntax.
Request body
The request body contains data with the following structure:
JSON representation |
---|
{ "locale": string, "countryCode": string, // Union field |
Fields | |
---|---|
locale |
If possible, returned geo targets are translated using this locale. If not, en is used by default. This is also used as a hint for returned geo targets. |
countryCode |
Returned geo targets are restricted to this country code. |
Union field query . Required. A selector of geo target constants. query can be only one of the following: |
|
locationNames |
The location names to search by. At most 25 names can be set. |
geoTargets |
The geo target constant resource names to filter by. |
Response body
Response message for GeoTargetConstantService.SuggestGeoTargetConstants
.
If successful, the response body contains data with the following structure:
JSON representation |
---|
{
"geoTargetConstantSuggestions": [
{
object ( |
Fields | |
---|---|
geoTargetConstantSuggestions[] |
Geo target constant suggestions. |
Authorization scopes
Requires the following OAuth scope:
https://www.googleapis.com/auth/adwords
For more information, see the OAuth 2.0 Overview.
LocationNames
A list of location names.
JSON representation |
---|
{ "names": [ string ] } |
Fields | |
---|---|
names[] |
A list of location names. |
GeoTargets
A list of geo target constant resource names.
JSON representation |
---|
{ "geoTargetConstants": [ string ] } |
Fields | |
---|---|
geoTargetConstants[] |
A list of geo target constant resource names. |
GeoTargetConstantSuggestion
A geo target constant suggestion.
JSON representation |
---|
{ "geoTargetConstant": { object ( |
Fields | |
---|---|
geoTargetConstant |
The GeoTargetConstant result. |
geoTargetConstantParents[] |
The list of parents of the geo target constant. |
locale |
The language this GeoTargetConstantSuggestion is currently translated to. It affects the name of geo target fields. For example, if locale=en, then name=Spain. If locale=es, then name=España. The default locale will be returned if no translation exists for the locale in the request. |
reach |
Approximate user population that will be targeted, rounded to the nearest 100. |
searchTerm |
If the request searched by location name, this is the location name that matched the geo target. |