Skip to main content
PUT
Attach a secret to an agent
Availability: Cloud · Community (self-hosted) · Enterprise (self-hosted)

Authorizations

Authorization
string
header
required

A workspace API key (oc_…) or organization API key (oc_org_…). Workspace-scoped endpoints called with an organization key also need X-Workspace-Id.

Path Parameters

agentId
string
required
secretId
string
required

Response

The agent's updated grant set

An agent's full grant set — returned by grant reads and by every grant write.

agentId
string
mode
enum<string>

Always grants on current servers. The all value is wire compatibility with older self-hosted releases; never branch behavior on it.

Available options:
all,
grants
connections
object[]
secrets
object[]