Search API Connector Documentation
Import Google Business Profile Data to Google Sheets
In this guide, we’ll walk through how to pull Google Business Profile (aka Google My Business) API data directly into Google Sheets, using the API Connector add-on for Sheets.
- Before You Begin
- Part 1: Connect to the Google Business Profile API
- Part 2: Pull Google Business Data into Sheets
- Part 3: Create a Custom API Request
- Part 4: Handle Pagination
- Part 5: API Documentation
Before You Begin
Click here to install the API Connector add-on from the Google Marketplace.
Part 1: Connect to the Google Business Profile API
The easiest way to get started with the Google Business Profile API is through API Connector's built-in integration.
- In Sheets, open API Connector and create a new request (Extensions > API Connector > Open > Create request)
- Select Google Business from the drop-down list of applications
- Under Authorization, click Connect to Google My Business
- You will be directed to google.com and asked to allow Mixed Analytics to access your Google business listings. Click Allow.
- You'll then be returned to your Google Sheet, and can verify that your Google Business connection is active in the Connections screen.
Part 2: Pull Google Business API Data into Sheets
Now that we’re connected, let’s pull some data into Sheets. We'll first fetch the IDs we need for subsequent requests.
Request #1 - account IDs
For this first example, you'll fetch the account IDs to which you have access.
- Select the
- In the "Path parameters" section, set the
mybusinessaccountmanagement. This is the required subdomain for this endpoint, so there are no other options.
- Optionally add a filter or change the
- Choose a destination sheet, name your request, and hit Run. A moment later you'll see the response data in your sheet.
- Note the numeric value located in the
accounts.namefield, after "accounts/". This is your account ID, which you'll use in the next request.
Request #2 - location IDs
In this next example, we'll get the business location ID, hours, and other data.
- Select the
- In the "Path parameters" section, populate the
account_idparameter with the account ID you retrieved in the first request. Also set the
mybusinessbusinessinformation(again, this is the only option).
- In the "Request parameters" section, use the
readMaskparameter to select the fields you'd like to see in your report. This is required.
- Optionally set other parameters, e.g. filters and sort.
- Choose a destination sheet, name your request, and hit Run. A moment later you'll see the location response data in your sheet.
- As before note the numeric ID. This is your location ID, which you'll use in most subsequent requests.
You can now plug the account and location IDs into the other available endpoints to fetch performance metrics and business reviews.
Part 3: Create a Custom API Request
Alternatively, you can create a custom request instead of using API Connector’s built-in integration, using any of the endpoints and parameters shown in the API documentation. Here's an example request setup:
- Open up Google Sheets and click Extensions > API Connector > Open > Create request.
- In the request form enter the following, substituting in your own location ID where it says
- Request URL:
Google My Business
- Create a new tab and click Set current to use that tab as your data destination.
- Name your request and click Run.
Part 4: Handle Pagination
By default, the Google Business API will limit records returned in the response. To get more records, set the
pageSize parameter to 50 or 100 as shown in the examples above (different endpoints have different
If you need more records after that, you can loop through them using pagination handling:
- Pagination type:
- Next token parameter:
- Next token path:
- Run until: choose when to stop running the request
Part 5: API Documentation
Official API documentation: https://developers.google.com/my-business/reference/rest