Assign Google Business Profile location to another profile
Connect a Google Business Profile location onto a DIFFERENT profile by reusing the OAuth grant from an already-connected Google Business Profile account, with no browser and no re-authorization. Built for agencies whose single Google account has manager access to many client locations and who run one profile per client: connect one location the normal way (browser OAuth), then bulk-assign the rest onto each client's profile via this endpoint. The path accountId is a SOURCE connected Google Business Profile account (the token holder); the body profileId is the TARGET profile, which may already hold other locations; assigning a location it already holds refreshes that account.
Authorization
bearerAuth API key authentication: send your Zernio API key in the Authorization header, prefixed with Bearer.
In: header
Path Parameters
A source connected Google Business Profile account whose OAuth grant is reused.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
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.assignGoogleBusinessLocation({ path: { accountId: 'account_abc123', }, body: { profileId: 'profile_abc123', selectedLocationId: 'selectedlocation_abc123', },});console.log(data);{ "message": "Google Business location assigned to profile successfully", "account": { "accountId": "6a41f0ab70e2d329a7741307", "platform": "googlebusiness", "username": "Snap Fitness Dianella", "displayName": "Snap Fitness Dianella", "isActive": true, "selectedLocationName": "Snap Fitness Dianella", "selectedLocationId": "12345678901234567890" }}Select Google Business Profile location
Complete the headless Google Business Profile 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.
List Google Business Profile 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, or raise limit to enumerate an account with more than 100 locations.