Set account type
Records whether the signed-in person runs Google Ads for their own business (direct_advertiser) or for clients (agency).
PUT /onboarding/account-type
Scope setup · Access Changes data · Operation id onboarding.set_account_type
Try it
productmetrics runs after productmetrics login; curl needs PM_TOKEN (see Authentication).
productmetrics onboarding set-account-type --account-type agency --jsonResponse
API response (200):
{
"data": {
"success": true
},
"request_id": "req_01J10MAPHEF82MC019DKA4NM50"
}CLI output: productmetrics onboarding set-account-type --json prints { "ok": true, "data": …, "request_id": "…" } with the same data.
Before you call
It only records the choice: onboarding.complete saves it to the account, and companies.create needs it saved. So for a new account: this, then onboarding.complete, then companies.create.
Body
| Name | Type | Required | Description |
|---|---|---|---|
account_type | enum | Yes | direct_advertiser for your own business, agency for clients. One of agency, direct_advertiser. |
Errors
A failure answers with its HTTP status and { error: { code, message, details? }, request_id }. Branch on code (stable, lower_snake); show message to the person. The CLI prints the same error with "ok": false.
{
"error": {
"code": "insufficient_scope",
"message": "This operation needs the setup scope; connect again and allow it.",
"details": {
"required_scope": "setup"
}
},
"request_id": "req_01JTRZT8Q5F4YMFZM6DVR39TSD"
}| Status | Code | When |
|---|---|---|
| 400 | invalid_request | A path, query or body value does not match this page. details.issues lists each location, path and message. |
| 401 | invalid_token | The token is missing, expired or revoked: sign in again (productmetrics login). The WWW-Authenticate header says why. |
| 403 | insufficient_scope | The token lacks the setup scope (details.required_scope): sign in again and allow it. |
| 429 | rate_limited | More than 600 requests a minute for this person: wait the Retry-After seconds (60) and retry. |