Skip to main content
GET
Verify the hash chain

Authorizations

X-Qanapi-Authorization
string
header
required

A machine credential, qk_ followed by its secret. Only a hash of the secret is stored, so a key is displayed exactly once, when it is created or rotated. A key reaches only the configurations it is linked to.

It may also be sent as Authorization: Bearer qk_..., which is recognised by the prefix.

Query Parameters

from
string<date-time>

Only records at or after this instant.

to
string<date-time>

Only records at or before this instant.

instance_id
string

Only records written by this cluster node. Hash chains are maintained per node, so this is the natural unit for chain verification.

Example:

"node-01"

action
string

An exact action, or a kms.* style prefix that matches a whole namespace.

Examples:

"encryption.encrypt"

"kms.*"

principal_id
string

Only records attributed to this principal: a user id or an API key id.

configuration_id
string<uuid>

Only records attributed to this configuration.

Response

The chain verified over the range examined.

verified
boolean
required

False when any link is broken, or when a gap is not accounted for by a recorded purge and the filters do not explain it.

records
integer
required

Records examined.

The finding that matters: the id of each record whose hash does not follow from its predecessor, which means it was edited after it was written.

gaps
string<uuid>[]
required

The id of each record whose predecessor is missing. Expected whenever the query is filtered, and expected after an authorised purge, so this is reported separately from a broken link rather than raised as tampering.

explained_by_purge
string<uuid>[]
required

The subset of gaps that a recorded purge accounts for. Those records live on in the export that the purge produced.

gaps_expected
boolean
required

Whether the filters themselves narrow the range, in which case gaps carry no information.