Index
AttributesService
(interface)CategoriesService
(interface)Chains
(interface)GoogleLocations
(interface)Locations
(interface)AdWordsLocationExtensions
(message)AssociateLocationRequest
(message)Attribute
(message)AttributeMetadata
(message)AttributeMetadata.AttributeValueMetadata
(message)AttributeValueType
(enum)Attributes
(message)BatchGetCategoriesRequest
(message)BatchGetCategoriesResponse
(message)BusinessHours
(message)Categories
(message)Category
(message)CategoryView
(enum)Chain
(message)Chain.ChainName
(message)Chain.ChainUri
(message)ClearLocationAssociationRequest
(message)CreateLocationRequest
(message)DeleteLocationRequest
(message)ErrorCode
(enum)GetAttributesRequest
(message)GetChainRequest
(message)GetGoogleUpdatedAttributesRequest
(message)GetGoogleUpdatedLocationRequest
(message)GetLocationRequest
(message)GoogleLocation
(message)GoogleUpdatedLocation
(message)Label
(message)ListAttributeMetadataRequest
(message)ListAttributeMetadataResponse
(message)ListCategoriesRequest
(message)ListCategoriesResponse
(message)ListLocationsRequest
(message)ListLocationsResponse
(message)Location
(message)Metadata
(message)MoreHours
(message)MoreHoursType
(message)OpenInfo
(message)OpenInfo.OpenForBusiness
(enum)PhoneNumbers
(message)PlaceInfo
(message)Places
(message)Profile
(message)RelationshipData
(message)RelevantLocation
(message)RelevantLocation.RelationType
(enum)RepeatedEnumAttributeValue
(message)SearchChainsRequest
(message)SearchChainsResponse
(message)SearchGoogleLocationsRequest
(message)SearchGoogleLocationsResponse
(message)ServiceAreaBusiness
(message)ServiceAreaBusiness.BusinessType
(enum)ServiceItem
(message)ServiceItem.FreeFormServiceItem
(message)ServiceItem.StructuredServiceItem
(message)ServiceType
(message)SpecialHourPeriod
(message)SpecialHours
(message)TimePeriod
(message)UpdateAttributesRequest
(message)UpdateLocationRequest
(message)UriAttributeValue
(message)
AttributesService
Allows clients to lookup and update attributes for a given location.
GetAttributes |
---|
Looks up all the attributes set for a given location.
|
GetGoogleUpdatedAttributes |
---|
Gets the Google-updated version of the specified location.
|
ListAttributeMetadata |
---|
Returns the list of attributes that would be available for a location with the given primary category and country.
|
UpdateAttributes |
---|
Update attributes for a given location.
|
CategoriesService
This API provides information about supported categories for business locations on Google. For reference, see the categories section of this article: https://support.google.com/business/answer/3038177
BatchGetCategories |
---|
Returns a list of business categories for the provided language and GConcept ids.
|
ListCategories |
---|
Returns a list of business categories. Search will match the category name but not the category ID. Search only matches the front of a category name (that is, 'food' may return 'Food Court' but not 'Fast Food Restaurant').
|
Chains
A service for looking up information about a Chain business.
GetChain |
---|
Gets the specified chain. Returns
|
SearchChains |
---|
Searches the chain based on chain name.
|
GoogleLocations
This API allows access and search GoogleLocation.
SearchGoogleLocations |
---|
Search all of the possible locations that are a match to the specified request.
|
Locations
This API allows management of business locations on Google.
AssociateLocation |
---|
Associates a location to a place ID. Any previous association is overwritten. This operation is only valid if the location is unverified. The association must be valid, that is, it appears in the list of
|
ClearLocationAssociation |
---|
Clears an association between a location and its place ID. This operation is only valid if the location is unverified.
|
CreateLocation |
---|
Creates a new Location that will be owned by the logged in user.
|
DeleteLocation |
---|
Deletes a location. If this location cannot be deleted using the API and it is marked so in the
|
GetGoogleUpdatedLocation |
---|
Gets the Google-updated version of the specified location.
|
GetLocation |
---|
Returns the specified location.
|
ListLocations |
---|
Lists the locations for the specified account.
|
UpdateLocation |
---|
Updates the specified location.
|
AdWordsLocationExtensions
Additional information that is surfaced in AdWords.
Fields | |
---|---|
ad_phone |
Required. An alternate phone number to display on AdWords location extensions instead of the location's primary phone number. |
AssociateLocationRequest
Request message for Locations.AssociateLocationRequest.
Fields | |
---|---|
name |
Required. The resource name of the location to associate. |
place_id |
The association to establish. If not set, it indicates no match. |
Attribute
A location attribute. Attributes provide additional information about a location. The attributes that can be set on a location may vary based on the properties of that location (for example, category). Available attributes are determined by Google and may be added and removed without API changes.
Fields | |
---|---|
name |
Required. The resource name for this attribute. |
value_type |
Output only. The type of value that this attribute contains. This should be used to determine how to interpret the value. |
values[] |
The values for this attribute. The type of the values supplied must match that expected for that attribute. This is a repeated field where multiple attribute values may be provided. Attribute types only support one value. |
repeated_enum_value |
When the attribute value type is REPEATED_ENUM, this contains the attribute value, and the other values fields must be empty. |
uri_values[] |
When the attribute value type is URL, this field contains the value(s) for this attribute, and the other values fields must be empty. |
AttributeMetadata
Metadata for an attribute. Contains display information for the attribute, including a localized name and a heading for grouping related attributes together.
Fields | |
---|---|
parent |
The unique identifier for the attribute. |
value_type |
The value type for the attribute. Values set and retrieved should be expected to be of this type. |
display_name |
The localized display name for the attribute, if available; otherwise, the English display name. |
group_display_name |
The localized display name of the group that contains this attribute, if available; otherwise, the English group name. Related attributes are collected into a group and should be displayed together under the heading given here. |
repeatable |
If true, the attribute supports multiple values. If false, only a single value should be provided. |
value_metadata[] |
For some types of attributes (for example, enums), a list of supported values and corresponding display names for those values is provided. |
deprecated |
If true, the attribute is deprecated and should no longer be used. If deprecated, updating this attribute will not result in an error, but updates will not be saved. At some point after being deprecated, the attribute will be removed entirely and it will become an error. |
AttributeValueMetadata
Metadata for supported attribute values.
Fields | |
---|---|
value |
The attribute value. |
display_name |
The display name for this value, localized where available; otherwise, in English. The value display name is intended to be used in context with the attribute display name. For example, for a "WiFi" enum attribute, this could contain "Paid" to represent paid Wi-Fi. |
AttributeValueType
The value type of the attribute.
Enums | |
---|---|
ATTRIBUTE_VALUE_TYPE_UNSPECIFIED |
Not specified. |
BOOL |
The values for this attribute are boolean values. |
ENUM |
The attribute has a predetermined list of available values that can be used. Metadata for this attribute will list these values. |
URL |
The values for this attribute are URLs. |
REPEATED_ENUM |
The attribute value is an enum with multiple possible values that can be explicitly set or unset. |
Attributes
A container for all the attributes for a given location.
Fields | |
---|---|
name |
Required. Google identifier for this location in the form of |
attributes[] |
A collection of attributes that need to be updated. |
BatchGetCategoriesRequest
Request message for BusinessCategories.BatchGetBusinessCategories.
Fields | |
---|---|
names[] |
Required. At least one name must be set. The GConcept ids the localized category names should be returned for. To return details for more than one category, repeat this parameter in the request. |
language_code |
Required. The BCP 47 code of language that the category names should be returned in. |
region_code |
Optional. The ISO 3166-1 alpha-2 country code used to infer non-standard language. |
view |
Required. Specifies which parts to the Category resource should be returned in the response. |
BatchGetCategoriesResponse
Response message for BusinessCategories.BatchGetBusinessCategories.
Fields | |
---|---|
categories[] |
Categories that match the GConcept ids provided in the request. They will not come in the same order as category ids in the request. |
BusinessHours
Represents the time periods that this location is open for business. Holds a collection of [TimePeriod][google.mybusiness.mybusinessinformation.v1.TimePeriod] instances.
Fields | |
---|---|
periods[] |
Required. A collection of times that this location is open for business. Each period represents a range of hours when the location is open during the week. |
Categories
A collection of categories that describes the business. During updates, both fields must be set. Clients are prohibited from individually updating the primary or additional categories using the update mask.
Fields | |
---|---|
primary_category |
Required. Category that best describes the core business this location engages in. |
additional_categories[] |
Optional. Additional categories to describe your business. Categories help your customers find accurate, specific results for services they're interested in. To keep your business information accurate and live, make sure that you use as few categories as possible to describe your overall core business. Choose categories that are as specific as possible, but representative of your main business. |
Category
A category describing what this business is (not what it does). For a list of valid category IDs, and the mappings to their human-readable names, see categories.list
.
Fields | |
---|---|
name |
Required. A stable ID (provided by Google) for this category. The value must be specified when modifying the category (when creating or updating a location). |
display_name |
Output only. The human-readable name of the category. This is set when reading the location. When modifying the location, |
service_types[] |
Output only. A list of all the service types that are available for this business category. |
more_hours_types[] |
Output only. More hours types that are available for this business category. |
CategoryView
An enum to help limit the amount of data returned by the server.
Enums | |
---|---|
CATEGORY_VIEW_UNSPECIFIED |
Not specified, equivalent to CATEGORY_METADATA_ONLY. |
BASIC |
The server response will only include Category fields display_name, category_id and language_code. It omits any service type metadata related fields. |
FULL |
Returns all the fields in the response. |
Chain
A chain is a brand that your business's locations can be affiliated with.
Fields | |
---|---|
name |
Required. The chain's resource name, in the format |
chain_names[] |
Names of the chain. |
websites[] |
Websites of the chain. |
location_count |
Number of locations that are part of this chain. |
ChainName
Name to be used when displaying the chain.
Fields | |
---|---|
display_name |
The display name for this chain. |
language_code |
The BCP 47 code of language of the name. |
ChainUri
Url to be used when displaying the chain.
Fields | |
---|---|
uri |
The uri for this chain. |
ClearLocationAssociationRequest
Request message for Locations.ClearLocationAssociationRequest.
Fields | |
---|---|
name |
Required. The resource name of the location to disassociate. |
CreateLocationRequest
Request message for Locations.CreateLocation.
Fields | |
---|---|
parent |
Required. The name of the account in which to create this location. |
location |
Required. The new location metadata. |
validate_only |
Optional. If true, the request is validated without actually creating the location. |
request_id |
Optional. A unique request ID for the server to detect duplicated requests. We recommend using UUIDs. Max length is 50 characters. |
DeleteLocationRequest
Request message for Locations.DeleteLocation.
Fields | |
---|---|
name |
Required. The name of the location to delete. |
ErrorCode
All errors codes returned by the API.
Enums | |
---|---|
ERROR_CODE_UNSPECIFIED |
Missing error code. |
INVALID_ATTRIBUTE_NAME |
One of the attributes provided cannot be applied to this location. Only attributes returned in the ListAttributeMetadata response maybe be applied to this location. All problematic attribute names will be returned in the attribute_names key under metadata. |
ASSOCIATE_OPERATION_ON_VERIFIED_LOCATION |
This error is returned when a client tries to associate a location or clear a location association on a location that is in verified state. |
ASSOCIATE_LOCATION_INVALID_PLACE_ID |
The place_id provided in the associateLocation request is not a match for the location or is invalid. Ensure that the place_id being set matches one of the IDs being returned in the SearchGoogleLocations response. |
LAT_LNG_UPDATES_NOT_PERMITTED |
This project is not allowed to update the lat/lng field on the Location. You may either update the lat/lng using the pin drop functionality in the UI or provide us with an address. |
PO_BOX_IN_ADDRESS_NOT_ALLOWED |
PO box cannot be used in address. Metadata keys include "field_mask". |
BLOCKED_REGION |
Due to international sanctions that we are obliged to comply with, we are unable to accept businesses from this region. Metadata keys include "field_maks". |
MISSING_BOTH_PHONE_AND_WEBSITE |
Either a phone or a website is required for CUSTOMER_LOCATION_ONLY businesses. Metadata keys include "field_mask". |
MISSING_STOREFRONT_ADDRESS_OR_SAB |
All Locations must have at least a storefront address or a service area. Metadata keys include "field_mask". |
LAT_LNG_TOO_FAR_FROM_ADDRESS |
The latitude/longitude and address pair are too far apart. Metadata keys include "field_mask". |
LAT_LNG_REQUIRED |
DEPRECATED. Replaced by PIN_DROP_REQUIRED. The specified address cannot be located. Please provide a latitude/longitude. Metadata keys include "field_mask". |
INVALID_CHARACTERS |
Invalid characters are found. Metadata keys include "field_mask" and "invalid_characters". |
FORBIDDEN_WORDS |
Forbidden words are found. Metadata keys include "field_mask" and "forbidden_words". |
INVALID_INTERCHANGE_CHARACTERS |
Invalid characters are found. Metadata keys include "field_mask". |
FIELDS_REQUIRED_FOR_CATEGORY |
Additional fields are required for this category of location. Metadata keys include "field_mask", "value", and "fields_required". |
STOREFRONT_REQUIRED_FOR_CATEGORY |
Your business category requires a storefront location customers can visit. Metadata keys include "field_mask". |
ADDRESS_MISSING_REGION_CODE |
Address is missing required region_code. Metadata keys include "field_mask". |
ADDRESS_EDIT_CHANGES_COUNTRY |
The address cannot be moved to different country. Metadata keys include "field_mask". |
SPECIAL_HOURS_SET_WITHOUT_REGULAR_HOURS |
Special hours can only be specified if the location has regular business hours. Metadata empty. |
INVALID_TIME_SCHEDULE |
Invalid time schedule, overlapped or end time is earlier than start time. Metadata keys include "field_mask". |
INVALID_HOURS_VALUE |
Invalid hours format or value. Metadata keys include "field_mask". |
OVERLAPPED_SPECIAL_HOURS |
Special_hours cannot overlap. Metadata keys include "field_mask". |
INCOMPATIBLE_MORE_HOURS_TYPE_FOR_CATEGORY |
Your business primary category doesn't support this hours type. Metadata keys include "field_mask" and "incompatible_hours_type". |
DUPLICATE_CHILDREN_LOCATIONS |
Duplicate children_locations in relationship_data. Metadata keys include "field_mask". |
INCOMPATIBLE_SERVICE_AREA_AND_CATEGORY |
A service area business cannot have the selected primary category. Metadata keys include "field_mask". |
INVALID_SERVICE_AREA_PLACE_ID |
Invalid place_id in service_area. Metadata keys include "field_mask" and "place_id". |
INVALID_AREA_TYPE_FOR_SERVICE_AREA |
Invalid area type for service_area. Metadata keys include "field_mask" and "place_id". |
OPENING_DATE_TOO_FAR_IN_THE_FUTURE |
Enter an opening date that's within a year. Metadata keys include "field_mask". |
OPENING_DATE_MISSING_YEAR_OR_MONTH |
Opening date must have a year or a month specified. Metadata keys include "field_mask". |
OPENING_DATE_BEFORE_1AD |
Opening date cannot be before 1 AD. Metadata keys include "field_mask". |
TOO_MANY_ENTRIES |
Too many entries for the field. Metadata keys include "field_mask" and "max_count". |
INVALID_PHONE_NUMBER |
Phone number input is not recognized. Metadata keys include "field_mask" and "value". |
INVALID_PHONE_NUMBER_FOR_REGION |
Invalid phone number for region. Metadata keys include "field_mask" and "value". |
MISSING_PRIMARY_PHONE_NUMBER |
Missing primary phone number. Metadata keys include "field_mask". |
THROTTLED |
The field cannot be updated at this time. Metadata keys include "field_mask" and "value". |
UNSUPPORTED_POINT_RADIUS_SERVICE_AREA |
Point radius service areas are no longer supported. Metadata keys include "field_mask". |
INVALID_CATEGORY |
Invalid category id. Metadata keys include "field_mask" and "value". |
CANNOT_REOPEN |
The business cannot reopen. Metadata keys include "field_mask". |
INVALID_BUSINESS_OPENING_DATE |
Invalid business opening date. Metadata keys include "field_mask". |
INVALID_LATLNG |
Invalid latlng. Metadata keys include "field_mask". |
PROFILE_DESCRIPTION_CONTAINS_URL |
Business description should not contain URL. Metadata keys include "field_mask". |
LODGING_CANNOT_EDIT_PROFILE_DESCRIPTION |
Lodging location's profile description can't be edited. Metadata keys include "field_mask". |
INVALID_URL |
Invalid link. Metadata keys include "field_mask". |
INVALID_ADDRESS |
Invalid address. Metadata keys include "field_mask". |
PARENT_CHAIN_CANNOT_BE_THE_LOCATION_ITSELF |
ParentChain cannot be the location itself. Metadata keys include "field_mask" and "value". |
RELATION_CANNOT_BE_THE_LOCATION_ITSELF |
Relation cannot be the location itself. Metadata keys include "field_mask" and "value". |
MISSING_ADDRESS_COMPONENTS |
Missing value for address components. Metadata keys include "field_mask". |
READ_ONLY_ADDRESS_COMPONENTS |
Can't edit readonly address components. Metadata keys include "field_mask". |
STRING_TOO_LONG |
The string is too long. Metadata keys include "field_mask" and "max_length". |
STRING_TOO_SHORT |
The string is too short. Metadata keys include "field_mask" and "min_length". |
REQUIRED_FIELD_MISSING_VALUE |
Missing value for required field. Metadata keys include "field_mask". |
ATTRIBUTE_PROVIDER_URL_NOT_ALLOWED |
URL for a provider cannot be added or edited. Metadata keys include "attribute_name". |
ATTRIBUTE_INVALID_ENUM_VALUE |
Unknown value for enum attribute. Metadata keys include "attribute_name". |
ATTRIBUTE_NOT_AVAILABLE |
Scalable attribute not valid for this location. Metadata keys include ""attribute_name". |
ATTRIBUTE_CANNOT_BE_REPEATED |
Scalable attribute only be specified once. Metadata keys include "attribute_name". |
ATTRIBUTE_TYPE_NOT_COMPATIBLE_FOR_CATEGORY |
Scalable attribute is not compatible with the categories set on the location. Metadata keys include "attribute_name". |
ADDRESS_REMOVAL_NOT_ALLOWED |
Address removal is not allowed for your business. Metadata keys include "field_mask". |
AMBIGUOUS_TITLE |
Best name is ambiguous for a language. Metadata keys include "field_mask". |
INVALID_CATEGORY_FOR_SAB |
A pure SAB cannot have gcids that are subtypes of gcid:establishment_poi. Metadata keys include "field_mask" and "value". |
RELATION_ENDPOINTS_TOO_FAR |
Relation endpoints are too far from each other. Metadata keys include "field_mask" and "value". |
INVALID_SERVICE_ITEM |
Neither structured_service_item nor free_form_service_item is set. Metadata keys include "field_mask". |
SERVICE_ITEM_LABEL_NO_DISPLAY_NAME |
Label is missing display name. Metadata keys include "field_mask". |
SERVICE_ITEM_LABEL_DUPLICATE_DISPLAY_NAME |
Display name is not unique for all labels across all price lists. Metadata keys include "field_mask". |
SERVICE_ITEM_LABEL_INVALID_UTF8 |
Label contains invalid UTF-8 symbols. Metadata keys include "field_mask". |
FREE_FORM_SERVICE_ITEM_WITH_NO_CATEGORY_ID |
Missing category_id field in free_form_service_item. Metadata keys include "field_mask". |
FREE_FORM_SERVICE_ITEM_WITH_NO_LABEL |
Missing label in free_form_service_item. Metadata keys include "field_mask". |
SERVICE_ITEM_WITH_NO_SERVICE_TYPE_ID |
Missing service_type_id field in structured_service_item. Metadata keys include "field_mask". |
INVALID_LANGUAGE |
Language code is invalid. Metadata keys include "field_mask". |
PRICE_CURRENCY_MISSING |
Missing ISO 4217 currency code. Metadata keys include "field_mask". |
PRICE_CURRENCY_INVALID |
Provided currency code is not valid ISO 4217. Metadata keys include "field_mask". |
SERVICE_TYPE_ID_DUPLICATE |
Service type ids are not unique within the Location. Metadata keys include "field_mask". |
PIN_DROP_REQUIRED |
The specified address cannot be located. Please use the UI to provide a pin drop. Metadata keys include "field_mask". |
STALE_DATA |
One or more items were recently updated by Google. Only the owner of this business can make changes to the data located in "field" at this time by visiting business.google.com. Metadata keys include "field_mask". |
GetAttributesRequest
Request for AttributesService.GetAttributes.
Fields | |
---|---|
name |
Required. Google identifier for this location in the form of |
GetChainRequest
Request message for Locations.GetChain.
Fields | |
---|---|
name |
Required. The chain's resource name, in the format |
GetGoogleUpdatedAttributesRequest
Request for AttributesService.GetGoogleUpdatedAttributes.
Fields | |
---|---|
name |
Required. Google identifier for this location in the form of |
GetGoogleUpdatedLocationRequest
Request message for Locations.GetGoogleUpdatedLocation.
Fields | |
---|---|
name |
Required. The name of the location to fetch. |
read_mask |
Required. Read mask to specify what fields will be returned in the response. |
GetLocationRequest
Request message for Locations.GetLocation.
Fields | |
---|---|
name |
Required. The name of the location to fetch. |
read_mask |
Required. Read mask to specify what fields will be returned in the response. |
GoogleLocation
Represents a Location
that is present on Google. This can be a location that has been claimed by the user, someone else, or could be unclaimed.
Fields | |
---|---|
name |
Resource name of this GoogleLocation, in the format |
location |
The sparsely populated |
request_admin_rights_uri |
A URL that will redirect the user to the request admin rights UI. This field is only present if the location has already been claimed by any user, including the current user. |
GoogleUpdatedLocation
Represents a location that was modified by Google.
Fields | |
---|---|
location |
The Google-updated version of this location. |
diff_mask |
The fields that Google updated. |
pending_mask |
The fields that have pending edits that haven't yet been pushed to Maps and Search. |
Label
Label to be used when displaying the price list, section, or item.
Fields | |
---|---|
display_name |
Required. Display name for the price list, section, or item. |
description |
Optional. Description of the price list, section, or item. |
language_code |
Optional. The BCP-47 language code that these strings apply for. Only one set of labels may be set per language. |
ListAttributeMetadataRequest
Request for AttributesService.ListAttributeMetadata.
Fields | |
---|---|
parent |
Resource name of the location to look up available attributes. If this field is set, category_name, region_code, language_code and show_all are not required and must not be set. |
category_name |
The primary category stable ID to find available attributes. Must be of the format categories/{category_id}. |
region_code |
The ISO 3166-1 alpha-2 country code to find available attributes. |
language_code |
The BCP 47 code of language to get attribute display names in. If this language is not available, they will be provided in English. |
show_all |
Metadata for all available attributes are returned when this field is set to true, disregarding parent and category_name fields. language_code and region_code are required when show_all is set to true. |
page_size |
How many attributes to include per page. Default is 200, minimum is 1. |
page_token |
If specified, the next page of attribute metadata is retrieved. |
ListAttributeMetadataResponse
Response for AttributesService.ListAttributeMetadata.
Fields | |
---|---|
attribute_metadata[] |
A collection of attribute metadata for the available attributes. |
next_page_token |
If the number of attributes exceeded the requested page size, this field will be populated with a token to fetch the next page of attributes on a subsequent call to |
ListCategoriesRequest
Request message for BusinessCategories.ListCategories.
Fields | |
---|---|
region_code |
Required. The ISO 3166-1 alpha-2 country code. |
language_code |
Required. The BCP 47 code of language. |
filter |
Optional. Filter string from user. The only field that supported is |
page_size |
Optional. How many categories to fetch per page. Default is 100, minimum is 1, and maximum page size is 100. |
page_token |
Optional. If specified, the next page of categories will be fetched. |
view |
Required. Specifies which parts to the Category resource should be returned in the response. |
ListCategoriesResponse
Response message for BusinessCategories.ListCategories.
Fields | |
---|---|
categories[] |
The matching categories based on the requested parameters. |
next_page_token |
If the number of categories exceeded the requested page size, this field will be populated with a token to fetch the next page of categories on a subsequent call to |
ListLocationsRequest
Request message for Locations.ListLocations.
Fields | |
---|---|
parent |
Required. The name of the account to fetch locations from. If the parent [Account] [google.mybusiness.accountmanagement.v1.Account] is of [AccountType] [google.mybusiness.accountmanagement.v1.Account.AccountType] PERSONAL, only Locations that are directly owned by the Account are returned, otherwise it will return all accessible locations from the Account, either directly or indirectly. |
page_size |
Optional. How many locations to fetch per page. Default value is 10 if not set. Minimum is 1, and maximum page size is 100. |
page_token |
Optional. If specified, it fetches the next |
filter |
Optional. A filter constraining the locations to return. The response includes only entries that match the filter. If For more information about valid fields and example usage, see Work with Location Data Guide. |
order_by |
Optional. Sorting order for the request. Multiple fields should be comma-separated, following SQL syntax. The default sorting order is ascending. To specify descending order, a suffix " desc" should be added. Valid fields to order_by are title and store_code. For example: "title, store_code desc" or "title" or "store_code desc" |
read_mask |
Required. Read mask to specify what fields will be returned in the response. |
ListLocationsResponse
Response message for Locations.ListLocations.
Fields | |
---|---|
locations[] |
The locations. |
next_page_token |
If the number of locations exceeded the requested page size, this field is populated with a token to fetch the next page of locations on a subsequent call to |
total_size |
The approximate number of Locations in the list irrespective of pagination. |
Location
A location. See the help center article for a detailed description of these fields, or the category endpoint for a list of valid business categories.
Fields | |
---|---|
name |
Google identifier for this location in the form: |
language_code |
Immutable. The language of the location. Set during creation and not updateable. |
store_code |
Optional. External identifier for this location, which must be unique within a given account. This is a means of associating the location with your own records. |
title |
Required. Location name should reflect your business's real-world name, as used consistently on your storefront, website, and stationery, and as known to customers. Any additional information, when relevant, can be included in other fields of the resource (for example, |
phone_numbers |
Optional. The different phone numbers that customers can use to get in touch with the business. |
categories |
Optional. The different categories that describe the business. |
storefront_address |
Optional. A precise, accurate address to describe your business location. PO boxes or mailboxes located at remote locations are not acceptable. At this time, you can specify a maximum of five |
website_uri |
Optional. A URL for this business. If possible, use a URL that represents this individual business location instead of a generic website/URL that represents all locations, or the brand. |
regular_hours |
Optional. Operating hours for the business. |
special_hours |
Optional. Special hours for the business. This typically includes holiday hours, and other times outside of regular operating hours. These override regular business hours. This field cannot be set without regular hours. |
service_area |
Optional. Service area businesses provide their service at the customer's location. If this business is a service area business, this field describes the area(s) serviced by the business. |
labels[] |
Optional. A collection of free-form strings to allow you to tag your business. These labels are NOT user facing; only you can see them. Must be between 1-255 characters per label. |
ad_words_location_extensions |
Optional. Additional information that is surfaced in AdWords. |
latlng |
Optional. User-provided latitude and longitude. When creating a location, this field is ignored if the provided address geocodes successfully. This field is only returned on get requests if the user-provided |
open_info |
Optional. A flag that indicates whether the location is currently open for business. |
metadata |
Output only. Additional non-user-editable information. |
profile |
Optional. Describes your business in your own voice and shares with users the unique story of your business and offerings. This field is required for all categories except lodging categories (e.g. hotels, motels, inns). |
relationship_data |
Optional. All locations and chain related to this one. |
more_hours[] |
Optional. More hours for a business's different departments or specific customers. |
service_items[] |
Optional. List of services supported by merchants. A service can be haircut, install water heater, etc. Duplicated service items will be removed automatically. |
Metadata
Additional non-user-editable information about the location.
Fields | |
---|---|
has_google_updated |
Output only. Indicates whether the place ID associated with this location has updates that need to be updated or rejected by the client. If this boolean is set, you should call the |
has_pending_edits |
Output only. Indicates whether any of this Location's properties are in the edit pending state. |
can_delete |
Output only. Indicates whether the location can be deleted using the API. |
can_operate_local_post |
Output only. Indicates if the listing can manage local posts. |
can_modify_service_list |
Output only. Indicates if the listing can modify the service list. |
can_have_food_menus |
Output only. Indicates if the listing is eligible for food menu. |
can_operate_health_data |
Output only. Indicates whether the location can operate on Health data. |
can_operate_lodging_data |
Output only. Indicates whether the location can operate on Lodging data. |
place_id |
Output only. If this locationappears on Google Maps, this field is populated with the place ID for the location. This ID can be used in various Places APIs. This field can be set during Create calls, but not for Update. |
duplicate_location |
Output only. The location resource that this location duplicates. |
maps_uri |
Output only. A link to the location on Maps. |
new_review_uri |
Output only. A link to the page on Google Search where a customer can leave a review for the location. |
can_have_business_calls |
Output only. Indicates if the listing is eligible for business calls. |
has_voice_of_merchant |
Output only. Indicates if the listing has Voice of Merchant. If this boolean is false, you should call the locations.getVoiceOfMerchantState API to get details as to why they do not have Voice of Merchant. |
MoreHours
The time periods during which a location is open for certain types of business.
Fields | |
---|---|
hours_type_id |
Required. Type of hours. Clients should call {#link businessCategories:BatchGet} to get supported hours types for categories of their locations. |
periods[] |
Required. A collection of times that this location is open. Each period represents a range of hours when the location is open during the week. |
MoreHoursType
More hours types that a business can offers, in addition to its regular hours.
Fields | |
---|---|
hours_type_id |
Output only. A stable ID provided by Google for this hours type. |
display_name |
Output only. The human-readable English display name for the hours type. |
localized_display_name |
Output only. The human-readable localized display name for the hours type. |
OpenInfo
Information related to the opening state of the business.
Fields | |
---|---|
status |
Required. Indicates whether or not the Location is currently open for business. All locations are open by default, unless updated to be closed. |
can_reopen |
Output only. Indicates whether this business is eligible for re-open. |
opening_date |
Optional. The date on which the location first opened. If the exact day is not known, month and year only can be provided. The date must be in the past or be no more than one year in the future. |
OpenForBusiness
Indicates the status of a location.
Enums | |
---|---|
OPEN_FOR_BUSINESS_UNSPECIFIED |
Not specified. |
OPEN |
Indicates that the location is open. |
CLOSED_PERMANENTLY |
Indicates that the location has been permanently closed. |
CLOSED_TEMPORARILY |
Indicates that the location has been temporarily closed. |
PhoneNumbers
A collection of phone numbers for the business. During updates, both fields must be set. Clients may not update just the primary or additional phone numbers using the update mask. International phone format is preferred, such as "+1 415 555 0132", see more in (https://developers.google.com/style/phone-numbers#international-phone-numbers).
Fields | |
---|---|
primary_phone |
Required. A phone number that connects to your individual business location as directly as possible. Use a local phone number instead of a central, call center helpline number whenever possible. |
additional_phones[] |
Optional. Up to two phone numbers (mobile or landline, no fax) at which your business can be called, in addition to your primary phone number. |
PlaceInfo
Defines an area that's represented by a place ID.
Fields | |
---|---|
place_name |
Required. The localized name of the place. For example, |
place_id |
Required. The ID of the place. Must correspond to a region. (https://developers.google.com/places/web-service/supported_types#table3) |
Places
Defines the union of areas represented by a set of places.
Fields | |
---|---|
place_infos[] |
The areas represented by place IDs. Limited to a maximum of 20 places. |
Profile
All information pertaining to the location's profile.
Fields | |
---|---|
description |
Required. Description of the location in your own voice, not editable by anyone else. |
RelationshipData
Information of all parent and children locations related to this one.
Fields | |
---|---|
parent_location |
The parent location that this location has relations with. |
children_locations[] |
The list of children locations that this location has relations with. |
parent_chain |
The resource name of the Chain that this location is member of. [How to find Chain ID] [Locations.SearchChains] |
RelevantLocation
Information about another location that is related to current one. The relation can be any one of DEPARTMENT_OF or INDEPENDENT_ESTABLISHMENT_OF, and the location specified here can be on either side (parent/child) of the location.
Fields | |
---|---|
place_id |
Required. Specify the location that is on the other side of the relation by its placeID. |
relation_type |
Required. The type of the relationship. |
RelationType
The type relations to be specified.
Enums | |
---|---|
RELATION_TYPE_UNSPECIFIED |
Type unspecified. |
DEPARTMENT_OF |
This represents a relation between 2 locations which share one physical area, same brand/upper management/organization, but with different key attributes like store hours or phone numbers. For example, Costco Pharmacy is a department in Costco Wholesale. |
INDEPENDENT_ESTABLISHMENT_IN |
This represents the cases where 2 locations are co-located in the same physical location, but from different companies (e.g. Starbucks in a Safeway, shops in a mall). |
RepeatedEnumAttributeValue
Values for an attribute with a value_type
of REPEATED_ENUM. This consists of two lists of value IDs: those that are set (true) and those that are unset (false). Values absent are considered unknown. At least one value must be specified.
Fields | |
---|---|
set_values[] |
Enum values that are set. |
unset_values[] |
Enum values that are unset. |
SearchChainsRequest
Request message for Locations.SearchChains.
Fields | |
---|---|
chain_name |
Required. Search for a chain by its name. Exact/partial/fuzzy/related queries are supported. Examples: "walmart", "wal-mart", "walmmmart", "沃尔玛" |
page_size |
The maximum number of matched chains to return from this query. The default is 10. The maximum possible value is 500. |
SearchChainsResponse
Response message for Locations.SearchChains.
Fields | |
---|---|
chains[] |
Chains that match the queried chain_display_name in SearchChainsRequest. If there are no matches, this field will be empty. Results are listed in order of relevance. |
SearchGoogleLocationsRequest
Request message for GoogleLocations.SearchGoogleLocations.
Fields | |
---|---|
page_size |
The number of matches to return. The default value is 3, with a maximum of 10. Note that latency may increase if more are requested. There is no pagination. |
Union field search_query . Search query. This can be provided either as a location object or as a string query. search_query can be only one of the following: |
|
location |
Location to search for. If provided, will find locations which match the provided location details. |
query |
Text query to search for. The search results from a query string will be less accurate than if providing an exact location, but can provide more inexact matches. |
SearchGoogleLocationsResponse
Response message for GoogleLocations.SearchGoogleLocations.
Fields | |
---|---|
google_locations[] |
A collection of GoogleLocations that are potential matches to the specified request, listed in order from most to least accuracy. |
ServiceAreaBusiness
Service area businesses provide their service at the customer's location (for example, a locksmith or plumber).
Fields | |
---|---|
business_type |
Required. Indicates the [type] [google.mybusiness.businessinfo.v1.ServiceAreaBusiness.BusinessType] of the service area business. |
places |
The area that this business serves defined through a set of places. |
region_code |
Immutable. CLDR region code of the country/region that this service area business is based in. See http://cldr.unicode.org/ and http://www.unicode.org/cldr/charts/30/supplemental/territory_information.html for details. Example: "CH" for Switzerland. This field is required for CUSTOMER_LOCATION_ONLY businesses, and is ignored otherwise. The region specified here can be different from regions for the areas that this business serves (e.g. service area businesses that provide services in regions other than the one that they are based in). If this location requires verification after creation, the address provided for verification purposes must be located within this region, and the business owner or their authorized representative must be able to receive postal mail at the provided verification address. |
BusinessType
Indicates whether this business only offers services onsite at a customer location (for example, a tow truck), or at both an address and onsite (for example, a pizza store with a dining area, that also delivers to customers).
Enums | |
---|---|
BUSINESS_TYPE_UNSPECIFIED |
Output only. Not specified. |
CUSTOMER_LOCATION_ONLY |
Offers service only in the surrounding area (not at the business address). If a business is being updated from a CUSTOMER_AND_BUSINESS_LOCATION to a CUSTOMER_LOCATION_ONLY, the location update must include field mask storefront_address and set the field to empty. |
CUSTOMER_AND_BUSINESS_LOCATION |
Offers service at the business address and the surrounding area. |
ServiceItem
A message that describes a single service item. It is used to describe the type of service that the merchant provides. For example, haircut can be a service.
Fields | |
---|---|
price |
Optional. Represents the monetary price of the service item. We recommend that currency_code and units should be set when including a price. This will be treated as a fixed price for the service item. |
Union field service_item_info . One of the following fields should always be set. service_item_info can be only one of the following: |
|
structured_service_item |
Optional. This field will be set case of structured services data. |
free_form_service_item |
Optional. This field will be set case of free-form services data. |
FreeFormServiceItem
Represents a free-form service offered by the merchant. These are services that are not exposed as part of our structure service data. The merchant manually enters the names for of such services via a geomerchant surface.
Fields | |
---|---|
category |
Required. This field represents the category name (i.e. the category's stable ID). The |
label |
Required. Language-tagged labels for the item. We recommend that item names be 140 characters or less, and descriptions 250 characters or less. This field should only be set if the input is a custom service item. Standardized service types should be updated via service_type_id. |
StructuredServiceItem
Represents a structured service offered by the merchant. For eg: toilet_installation.
Fields | |
---|---|
service_type_id |
Required. The |
description |
Optional. Description of structured service item. The character limit is 300. |
ServiceType
A message describing a service type that the business offers.
Fields | |
---|---|
service_type_id |
Output only. A stable ID (provided by Google) for this service type. |
display_name |
Output only. The human-readable display name for the service type. |
SpecialHourPeriod
Represents a single time period when a location's operational hours differ from its normal business hours. A special hour period must represent a range of less than 24 hours. The open_time
and start_date
must predate the close_time
and end_date
. The close_time
and end_date
can extend to 11:59 a.m. on the day after the specified start_date
. For example, the following inputs are valid:
start_date=2015-11-23, open_time=08:00, close_time=18:00
start_date=2015-11-23, end_date=2015-11-23, open_time=08:00,
close_time=18:00 start_date=2015-11-23, end_date=2015-11-24,
open_time=13:00, close_time=11:59
The following inputs are not valid:
start_date=2015-11-23, open_time=13:00, close_time=11:59
start_date=2015-11-23, end_date=2015-11-24, open_time=13:00,
close_time=12:00 start_date=2015-11-23, end_date=2015-11-25,
open_time=08:00, close_time=18:00
Fields | |
---|---|
start_date |
Required. The calendar date this special hour period starts on. |
open_time |
Optional. Valid values are 00:00-24:00 where 24:00 represents midnight at the end of the specified day field. Must be specified if |
end_date |
Optional. The calendar date this special hour period ends on. If |
close_time |
Optional. Valid values are 00:00-24:00, where 24:00 represents midnight at the end of the specified day field. Must be specified if |
closed |
Optional. If true, |
SpecialHours
Represents a set of time periods when a location's operational hours differ from its normal business hours.
Fields | |
---|---|
special_hour_periods[] |
Required. A list of exceptions to the business's regular hours. |
TimePeriod
Represents a span of time that the business is open, starting on the specified open day/time and closing on the specified close day/time. The closing time must occur after the opening time, for example later in the same day, or on a subsequent day.
Fields | |
---|---|
open_day |
Required. Indicates the |
open_time |
Required. Valid values are 00:00-24:00, where 24:00 represents midnight at the end of the specified day field. |
close_day |
Required. Indicates the |
close_time |
Required. Valid values are 00:00-24:00, where 24:00 represents midnight at the end of the specified day field. |
UpdateAttributesRequest
Request for AttributesService.UpdateAttributes.
Fields | |
---|---|
attributes |
A collection of attributes that need to be updated. |
attribute_mask |
Required. Attribute name of attributes that you'd like to update. Represented by Updates: All attributes provided in the attributes field that you would like to update must be set in the Deletes: If you'd like to delete certain attributes, they must be specified in the |
UpdateLocationRequest
Request message for Locations.UpdateLocation.
Fields | |
---|---|
location |
Required. The updated location information. |
update_mask |
Required. The specific fields to update. |
validate_only |
Optional. If true, the request is validated without actually updating the location. When this field is set, we will only return validation errors if there were any. The response will be empty if no errors were found. |
UriAttributeValue
Values for an attribute with a value_type
of URL.
Fields | |
---|---|
uri |
Required. The proposed URI value for this attribute. |