Guides
Scopes and permissions
Every authenticated call checks two things:
- Scope. The API key holds the ability's scope.
- Role. The principal's role in the workspace allows the ability. Users have
owner,admin,editor,contributororviewer(org owners and admins act asowner/admineverywhere). Agents always have the roleagentin the workspaces they're attached to.
If the scope is missing you get 403 missing_scope. If the scope is there but the role doesn't allow the action
you get 403 role_forbidden. Both carry required_scope and ability. A workspace the key can't see at all
returns 404 not_found. GET /v1/me lists the resulting abilities per workspace, so check that list rather than
guessing. The same matrix is served as JSON in GET /v1/capabilities → abilities.
Scopes#
Agent default means an agent key gets the scope when it's issued without an explicit scopes list
(GET /v1/capabilities → default_agent_scopes).
| Scope | Grants | Agent default |
|---|---|---|
context:read |
Read the workspace context bundle | yes |
design_system:read |
Read the design system | yes |
channels:read |
Read channels, capabilities, slots and connection health | yes |
posts:read |
Read posts, variants, revisions, comments, media, campaigns | yes |
analytics:read |
Read metrics | yes |
drafts:write |
Create and edit drafts, comment | yes |
media:write |
Upload, import and edit media | yes |
posts:submit |
Submit drafts for review | yes |
campaigns:write |
Create, update, archive and delete campaigns | yes |
billing:read |
Read the organization credit balance, prices, spend and ledger | yes |
design_system:write |
Change the design system (PUT/PATCH/restore) | no: human grant |
channels:connect |
Create one-time connect links for a brand owner | no: human grant |
posts:approve |
Approve posts or request changes | no: human grant |
posts:publish |
Schedule, unschedule, publish now, pause publishing, delete from network | no: human grant |
engagement:read |
Read the inbox: comments, replies, mentions and DMs | no: human grant |
engagement:write |
Reply to comments and DMs (and, for humans, manage auto-reply rules) | no: human grant |
webhooks:manage |
Manage webhook endpoints | no: human grant |
billing:manage |
Top up credits by card (users with org role owner, admin or billing) | never for agents |
workspace:admin |
Members, agents, keys, channels (connect/refresh/disconnect), policies, audit | never for agents |
"Human grant" means a workspace owner or admin issues the agent a key that includes the scope
(POST /v1/agents/{id}/keys {"scopes": [...]}). Agents can never issue keys: that needs members.manage, which
requires workspace:admin and the owner/admin role. On top of that, granting posts:approve, posts:publish or
design_system:write to an agent is refused with 403 human_required unless the caller is a user.
workspace:admin isn't accepted on agent keys at all.
Abilities#
ability → scope → roles. "Agent" means the agent role is in the list, so an agent can do it once its key holds
the scope.
| Ability | Scope | Roles | Agent | Main endpoints |
|---|---|---|---|---|
context.read |
context:read |
all | yes | GET /workspaces/{ws}/context |
posts.read |
posts:read |
all | yes | GET /posts…, comments, revisions, diff, campaigns (read), views, approval policy (read), publishing log, POST /validate |
drafts.create |
drafts:write |
owner, admin, editor, contributor | yes | POST /workspaces/{ws}/posts, posts:batch create |
drafts.edit_any |
drafts:write |
owner, admin, editor | no | PATCH /posts/{id} on anyone's draft |
drafts.edit_own |
drafts:write |
owner, admin, editor, contributor | yes | PATCH /posts/{id}, archive/delete, own drafts only |
comments.write |
drafts:write |
owner, admin, editor, contributor | yes | POST /posts/{id}/comments, resolve |
posts.submit |
posts:submit |
owner, admin, editor, contributor | yes | POST /posts/{id}/submit, submit_for_review: true |
posts.approve |
posts:approve |
owner, admin, editor | yes* | POST /posts/{id}/approve, /request-changes |
posts.publish |
posts:publish |
owner, admin, editor | yes* | /schedule, /unschedule, /publish-now, POST /channels/{id}/pause, POST /workspaces/{ws}/pause |
channels.read |
channels:read |
all | yes | channels, capabilities, slots, connections, health, POST /channels/{id}/check |
channels.manage |
workspace:admin |
owner, admin | no | channels/connect, refresh, disconnect, PATCH /channels/{id}, channel groups |
channels.connect_link |
channels:connect |
owner, admin | yes* | GET/POST /workspaces/{ws}/connect-links, DELETE /connect-links/{id} |
design_system.read |
design_system:read |
all | yes | GET /workspaces/{ws}/design-system, /versions |
design_system.write |
design_system:write |
owner, admin, editor | yes* | PUT/PATCH …/design-system, …/versions/{n}/restore, POST …/design-system/import |
campaigns.manage |
campaigns:write |
owner, admin, editor | yes | POST /workspaces/{ws}/campaigns, PATCH/DELETE /campaigns/{id} |
media.read |
posts:read |
all | yes | GET /workspaces/{ws}/media, GET /media/{id} |
media.write |
media:write |
owner, admin, editor, contributor | yes | uploads, presign, import, PATCH /media/{id}, optimize |
analytics.read |
analytics:read |
all | yes | /workspaces/{ws}/analytics, channel metrics |
webhooks.manage |
webhooks:manage |
owner, admin | yes* | /webhooks… |
members.manage |
workspace:admin |
owner, admin | no | members, invitations, workspace settings, agents and agent keys |
policies.manage |
workspace:admin |
owner, admin | no | PUT /workspaces/{ws}/approval-policy |
audit.read |
workspace:admin |
owner, admin | no | GET /workspaces/{ws}/audit |
engagement.read |
engagement:read |
all | yes* | inbox, interactions, rules (read), autoreply-rules/{id}/test, executions, follow-ups |
engagement.reply |
engagement:write |
owner, admin, editor | yes* | POST /interactions/{id}/reply, sync-inbox, approve/reject queued auto-replies |
autoreplies.manage |
engagement:write |
owner, admin, editor | no | create/update/delete auto-reply rules |
* Only when a human grants the scope. Creating workspaces also needs an org owner/admin user
(403 org_admin_required).
Rules that hold even with the scope#
- No self-approval. An agent with
posts:approvestill can't approve a post it wrote (403 self_approval_forbidden). To let an agent's posts through without a human, an admin sets an auto-approve policy (PUT /v1/workspaces/{ws}/approval-policy→auto_approve: [{agent_id, channel_ids?, min_confidence?, require_valid?, require_no_warnings?}]). It's evaluated on submit and logged as a policy approval. - Approve and schedule are separate. Approving with a schedule needs
posts:publishtoo. Without it the call is refused before anything is approved (missing_scope), and you can retry withschedule.mode: "none". - Agents edit only their own drafts, only before approval, and never while a human holds the edit lock
(
423 post_locked). Once a post is approved or scheduled, agents get409 post_not_editable. - Key restrictions apply everywhere.
workspace_idslimits what/meand every list returns,channel_idslimits which channels a key can target (403 channel_not_allowed) and see,ip_allowlistreturns403 ip_not_allowedfrom other addresses, and quotas return429 quota_exceeded.
Why agents never complete OAuth#
Connecting a social account means a person signing in to that network and consenting. The provider's tokens then act with that person's authority on the brand's account. The API therefore keeps OAuth with humans:
POST /v1/workspaces/{ws}/channels/connect(which returns the providerauthorization_url) needschannels.manage=workspace:admin, a scope agents can never hold.- What an agent can do, with
channels:connect, is create a connect link:POST /v1/workspaces/{ws}/connect-links {provider, reconnect_channel_id?, note?, expires_in_hours?, redirect_to?}. The response has a one-timeurl(default 72 h, max 168 h) to hand to the brand owner. The owner opens it in a browser and signs in with the provider. The tokens go straight from the provider to the API and are stored encrypted. The agent never sees them. - The agent watches the result with
GET /v1/workspaces/{ws}/connections(pending_connect_links, thenchannels[].ready), withGET /v1/workspaces/{ws}/connect-links(status: used,result.channel_ids), or with thechannel.connectedwebhook.
