Store a connection credential

View as Markdown
Stores a secret (an API key, a bot token) for this connection in the encrypted secret store. WRITE-ONLY: the value is never persisted by us, never echoed by any route, and never reaches the agent or its code sandbox — it is read only at call time, to authenticate the outbound request. The response carries the opaque reference. Re-posting the same `purpose` rotates the secret in place (the reference does not change). Authorization: `space:contribute`.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Path parameters

spaceIdstringRequired
connectionIdstringRequired

Request

Write-only. The value goes to the encrypted secret store and is never echoed back.

purposestringRequired1-64 characters
valuestringRequired>=1 character
expiresAtstringOptional

Response

The stored credential reference.
dataobject