Needs permission api-token:write.
Afterwards the token reaches every organisation the account owns, including ones added later, whatever its organisationIds list says. Idempotent. The body is optional: roleId sets the token's role across the account. Giving a token a role needs a caller who manages API tokens where it applies (403 access_management_denied otherwise; a person or an API token alike), and the role's permissions must be ones you hold (403 role_assignment_denied). A role for people only answers 400 role_not_assignable, and while only Administrator can be given out any other role answers 400 role_not_yet_available. A role you leave out on access it did not have is your account's default role (GET /customer/access-settings), and administrator while only Administrator can be given out; when that default role is for people only, the token is refused with 400 role_not_assignable and you name its role. Every response lists the token's role at each place in roles.
This is the widest grant this API makes. A leaked credential holding it reaches everything, so only somebody who already holds account-wide access may grant it — 403 whole_customer_access_denied otherwise, a higher bar than PUT /api-tokens/{clientId}/organisations/{organisationId}, which needs only the one organisation.
The token's direct grants are left as they are, so removing account-wide access later returns it to exactly that set rather than to nothing.
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
