Skip to content

Show a stored credential's secret, for a person signing in to the device (ADR-210). Admin only since stage 8: an Operator replaces secrets but never reads one back.

POST
/api/v1/credentials/{id}/reveal
curl --request POST \
--url https://example.com/api/v1/credentials/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/reveal \
--header 'Authorization: Bearer <token>'

A POST although it changes nothing, so audit_mw writes a row naming who read which credential — the same reason the relocation download is one. The answer is never cached (Cache-Control: no-store). Refused to an API token (token_not_permitted) and to an account restricted to folders (scope_unsupported): the shelf belongs to no folder, so a scoped caller could otherwise read the login of a site it cannot see. An integration key and a kind this server does not know are refused (not_revealable).

id
required
string format: uuid

Credential id

The secret in plaintext. Every call is recorded in the audit log

Media typeapplication/json

A credential’s secret, in plaintext.

object
fields
required

The parts of the secret, in the order a person types them into a device.

Array<object>

One part of a revealed secret and its value.

object
field
required

One part of a revealed secret. Which parts a credential has depends on its kind.

string
Allowed values: community user security_level auth_protocol auth_key priv_protocol priv_key scheme username password token header_name header_value enable
secret
required

Whether the value is itself secret (a passphrase, a password, a token) rather than a setting beside it (a protocol, a user name).

boolean
value
required
string
id
required
string format: uuid
kind
required
string
Example
{
"fields": [
{
"field": "community"
}
]
}

An integration key or an unknown kind, which is not revealed (not_revealable)

Media typeapplication/json

The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies undescribed — a client that has to guess the failure shape ends up parsing the success shape and reading undefined.

object
error
required
object
code
required

Stable machine-readable code. Clients branch on this, never on the message.

string
message
required

Operator-facing sentence. Safe to display; never carries an internal error’s own text.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example"
}
}

No valid bearer token

Media typeapplication/json

The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies undescribed — a client that has to guess the failure shape ends up parsing the success shape and reading undefined.

object
error
required
object
code
required

Stable machine-readable code. Clients branch on this, never on the message.

string
message
required

Operator-facing sentence. Safe to display; never carries an internal error’s own text.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example"
}
}

Role does not hold RevealCredentials, the caller is an API token (token_not_permitted), or the account is restricted to folders (scope_unsupported)

Media typeapplication/json

The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies undescribed — a client that has to guess the failure shape ends up parsing the success shape and reading undefined.

object
error
required
object
code
required

Stable machine-readable code. Clients branch on this, never on the message.

string
message
required

Operator-facing sentence. Safe to display; never carries an internal error’s own text.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example"
}
}

No such credential

Media typeapplication/json

The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies undescribed — a client that has to guess the failure shape ends up parsing the success shape and reading undefined.

object
error
required
object
code
required

Stable machine-readable code. Clients branch on this, never on the message.

string
message
required

Operator-facing sentence. Safe to display; never carries an internal error’s own text.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example"
}
}

The stored secret cannot be decrypted or does not parse for its kind

Media typeapplication/json

The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies undescribed — a client that has to guess the failure shape ends up parsing the success shape and reading undefined.

object
error
required
object
code
required

Stable machine-readable code. Clients branch on this, never on the message.

string
message
required

Operator-facing sentence. Safe to display; never carries an internal error’s own text.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example"
}
}

Skeleton mode has no credential store

Media typeapplication/json

The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies undescribed — a client that has to guess the failure shape ends up parsing the success shape and reading undefined.

object
error
required
object
code
required

Stable machine-readable code. Clients branch on this, never on the message.

string
message
required

Operator-facing sentence. Safe to display; never carries an internal error’s own text.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example"
}
}