Skip to main content
PUT
Create or replace a secret

Authorizations

Authorization
string
header
required

API key with the vk_ prefix. Create one from the dashboard.

Path Parameters

name
string
required

Secret name, environment-variable style ([A-Za-z_][A-Za-z0-9_]{0,63})

Body

application/json
value
string
required

The secret value. Stored encrypted; never returned by the API.

scope_host
string | null

Optional HTTPS host the value is scoped to (e.g. "api.openai.com"). When set, agent sessions only attach the value to requests for that host; when absent, the value is injected as an environment variable. Hostname only: no scheme, port, path or wildcard.

Response

The stored secret's metadata. The value is never returned.

object
string
required
name
string
required

Environment-variable style name ([A-Za-z_][A-Za-z0-9_]{0,63}).

created_at
string<date-time>
required
updated_at
string<date-time>
required
scope_host
string | null