Auth & Scopes
Authentication methods
When token enforcement is enabled:
Authorization: Bearer <token>X-Agents-Token: <token>?apiToken=<token>only ifPLUGIN_AGENTS_ALLOW_QUERY_TOKEN=true
How agents use API keys
- Agents do not transport keys themselves; the runtime/tool layer sends HTTP requests.
- Store the key as a runtime secret (for example
AGENTS_API_KEY), not in prompts. - Configure your HTTP tool/client to send either:
Authorization: Bearer <token>X-Agents-Token: <token>
- Validate scope and identity with
GET /agents/v1/auth/whoami.
Credential sources
Runtime auth accepts merged credentials from:
- managed CP keys
PLUGIN_AGENTS_API_CREDENTIALSJSON setPLUGIN_AGENTS_API_TOKENlegacy fallback
Capabilities/auth metadata surfaces also expose runtime profile posture:
environmentProfileenvironmentProfileSourceprofileDefaultsAppliedeffectivePolicyVersion
Core scopes
Read scopes:
health:readreadiness:readauth:readadoption:readmetrics:readlifecycle:readdiagnostics:readproducts:readvariants:readsubscriptions:readtransfers:readdonations:readorders:readorders:read_sensitiveentries:readentries:read_all_statusesassets:readcategories:readtags:readglobalsets:readaddresses:read(only whenPLUGIN_AGENTS_ENABLE_ADDRESSES_API=true)addresses:read_sensitive(only whenPLUGIN_AGENTS_ENABLE_ADDRESSES_API=true)contentblocks:readchanges:readsections:readusers:read(only whenPLUGIN_AGENTS_ENABLE_USERS_API=true)users:read_sensitive(only whenPLUGIN_AGENTS_ENABLE_USERS_API=true)syncstate:readsyncstate:writeentries:write:draft(experimental; only effective whenPLUGIN_AGENTS_WRITES_EXPERIMENTAL=true)- deprecated alias:
entries:write->entries:write:draft - deprecated aliases:
consumers:read,consumers:write schema:readcapabilities:readopenapi:readwebhooks:dlq:readwebhooks:dlq:replay
Control scopes (experimental flag only):
control:policies:readcontrol:policies:writecontrol:approvals:readcontrol:approvals:requestcontrol:approvals:decidecontrol:approvals:write(legacy combined compatibility scope)control:executions:readcontrol:actions:simulatecontrol:actions:executecontrol:audit:read
Notes:
- Control scopes are omitted from capabilities/OpenAPI when
PLUGIN_AGENTS_WRITES_EXPERIMENTAL=false. control:approvals:writeremains accepted for backward compatibility, but new integrations should use request/decide split scopes.
Permission model in CP
Credential management permissions:
agents-viewCredentialsagents-manageCredentialsagents-rotateCredentialsagents-revokeCredentialsagents-deleteCredentials