POST

Authorizations

x-api-key
string
header
required

Headers

bma-workspace-id
string

Project scope. Required when the API key can access more than one project. Also accepted as anthropic-workspace-id; headers sent together must agree, otherwise the request is a 400 workspace_id_conflict.

Idempotency-Key
string

Replays the first result of a create; the same key with another body is 400 idempotency_key_reused, one while the first still runs 409 idempotency_key_in_use.

Required string length: 1 - 255

Path Parameters

vault_id
string
required

ID of the vault (vlt_ followed by 26 lowercase base32 characters; a few older vaults keep an ID of another form, such as sec_…).

Body

application/json
auth
object
required

The kind of credential and its settings and secrets, chosen by type.

display_name
string | null

Name of the credential, 1-255 characters on one line. Omitted or null leaves it unnamed.

Maximum string length: 255
metadata
object

Optional key-value pairs, at most 16; keys are 1-64 characters, values strings of at most 512 characters. Omitted stores none.

Response

Success.

A credential of a vault, with its non-secret settings only; secret values are never returned.

id
string
required

ID of the credential (vcrd_ followed by 26 lowercase base32 characters; a few older credentials keep an ID of another form, such as sec_…).

type
string
required

Always vault_credential.

Allowed value: "vault_credential"
vault_id
string
required

ID of the vault the credential belongs to.

display_name
string | null
required

Name of the credential, 1-255 characters on one line; null when none was given.

metadata
object
required

Your key-value pairs, at most 16; {} when there are none.

auth
object
required

The kind of credential and its non-secret settings, chosen by type.

created_at
string<date-time>
required

When the credential was created (RFC 3339, UTC).

updated_at
string<date-time>
required

When the credential was last changed, rotated, refreshed or archived (RFC 3339, UTC).

archived_at
string<date-time> | null
required

When the credential was archived and its secret erased (RFC 3339, UTC); null while it is active.