List GBP locations
Returns Google Business Profile locations the connected account can access, plus the currently selected location. The list is bounded (see hasMore); for accounts that own many locations, use the search or filter query params to find a specific one instead of loading them all.
API key authentication - use your Zernio API key as a Bearer token
In: header
Path Parameters
Query Parameters
Free-text search on the business name, applied server-side by Google. Use for accounts with many locations.
Raw Google Business Information API filter expression (advanced; takes precedence over search), e.g. storeCode="LH279411".
Response Body
application/json
application/json
import Zernio from '@zernio/node';const zernio = new Zernio({ apiKey: process.env.ZERNIO_API_KEY });const { data } = await zernio.connect.getGmbLocations({ path: { accountId: 'account_abc123', },});console.log(data);{
"locations": [
{
"id": "12345678901234567890",
"name": "My Business Location",
"accountId": "accounts/123456789",
"accountName": "My Business Account",
"address": "123 Main St, San Francisco, CA",
"category": "Restaurant",
"websiteUrl": "https://mybusiness.com"
}
],
"selectedLocationId": "12345678901234567890",
"cached": true
}{
"error": "Unauthorized"
}Select GBP location POST
Complete the headless GBP flow by saving the user's selected location. The pendingDataToken is returned in your redirect URL after OAuth completes (step=select_location). Tokens and profile data are stored server-side, so only the pendingDataToken is needed here. Use X-Connect-Token header if connecting via API key.
Update GBP location PUT
Switch which GBP location is active for a connected account.