Skip to content

HTTP API / Audit

Audit API ​

6 operations. Paths are relative to the API host (http://localhost:5080 in local development). Every operation accepts an OIDC bearer token (Authorization: Bearer …) or a workspace API key (X-Api-Key: keel_live_…); errors are RFC 9457 Problem Details with a code (error codes). Permissions: matrix.

MethodPathSummary
GET/api/v1/audit/chainThe latest hash-chain verification (nightly, F16 AC2).
POST/api/v1/audit/chain:verifyVerify the tenant's hash chain now (Owners). Returns the job.
GET/api/v1/audit/eventsAudit events, newest first. Filters: actor (id or name), asset, action (contains), from/to; cursor paging.
GET/api/v1/audit/exportStreamed export (format=csv|json) of the audit events matching the filters. Metadata only; audited.
GET/api/v1/audit/settingsAudit retention (default 365 days).
PUT/api/v1/audit/settingsChange audit retention (Owners, 30–3650 days). Audited.

GetAuditChainStatus ​

http
GET /api/v1/audit/chain

The latest hash-chain verification (nightly, F16 AC2).

StatusDescriptionBody
200OKAuditChainStatusDto

Response 200: AuditChainStatusDto

FieldTypeNotes
anchorSequenceint64
checkedAtdate-time?
eventsCheckedint64
failurestring?
firstBadSequenceint64?
modestring
statusstring
verifiedThroughSequenceint64?

VerifyAuditChain ​

http
POST /api/v1/audit/chain:verify

Verify the tenant's hash chain now (Owners). Returns the job.

StatusDescriptionBody
202AcceptedVerifyAuditChainResponse

Response 202: VerifyAuditChainResponse

FieldTypeNotes
jobIduuid

ListAuditEvents ​

http
GET /api/v1/audit/events

Audit events, newest first. Filters: actor (id or name), asset, action (contains), from/to; cursor paging.

ParameterInTypeRequiredNotes
actorquerystringno
assetquerystringno
actionquerystringno
fromquerydate-timeno
toquerydate-timeno
cursorquerystringno
limitqueryint32no
StatusDescriptionBody
200OKAuditEventPage

Response 200: AuditEventPage

FieldTypeNotes
itemsAuditEventDto[]
nextCursorstring?

ExportAuditEvents ​

http
GET /api/v1/audit/export

Streamed export (format=csv|json) of the audit events matching the filters. Metadata only; audited.

ParameterInTypeRequiredNotes
formatquerystringno
actorquerystringno
assetquerystringno
actionquerystringno
fromquerydate-timeno
toquerydate-timeno
StatusDescriptionBody
200OKstring
400Bad RequestProblemDetails
403ForbiddenProblemDetails

GetAuditSettings ​

http
GET /api/v1/audit/settings

Audit retention (default 365 days).

StatusDescriptionBody
200OKAuditSettingsDto

Response 200: AuditSettingsDto

FieldTypeNotes
defaultRetentionDaysint32
maxRetentionDaysint32
minRetentionDaysint32
retentionDaysint32

UpdateAuditSettings ​

http
PUT /api/v1/audit/settings

Change audit retention (Owners, 30–3650 days). Audited.

Request body (application/json): UpdateAuditSettingsRequest

FieldTypeNotes
retentionDaysint32
StatusDescriptionBody
204No Content—

Anchor Keel is a working product name: one platform, a shared core and licensed modules (Keel Semantic, Keel Migrate). Documentation built from the repository — facts are derived from code, ADRs and the decisions log.