AuralisDocs
OperationsAPI keys

Delete a key and its record

Remove a key permanently. Prefer revoking it.

/v1/api-keys/{key_id}Admin
Operation id
delete_api_key
Access
An editor or a viewer is refused.
DELETE/v1/api-keys/{key_id}

Remove a key permanently. Prefer revoking it.

The row is deleted, so the key stops working and also stops being visible in the key list. Revocation is usually what you want instead: it stops the key just as completely and leaves the record of what it was and who minted it, which is what someone reviewing a past incident needs.

Deleting a key id that is not in this workspace, or one already deleted, is refused with 404. A 204 always means a key was really removed, never that the request was merely well formed.

There is no response body.

Tenancy: the request is scoped to one workspace, and the credential presented is what selects it. A caller with no membership in that workspace is refused with 404, which is indistinguishable from a workspace that does not exist.

Authorisation: admin or owner. An editor or viewer receives 403 insufficient_role.

Access: Authorization: Bearer carrying either a realm access token or an API key. A key must hold the admin-resources:write scope, and the workspace role of the person who owns it must meet the floor above.

Authorization

AuthorizationBearer <token>

A realm-issued access token, presented as Authorization: Bearer <token>. It acts as the person who signed in, and every operation resolves their workspace role live from the membership record.

In: header

Path Parameters

key_id*Key Id
Formatuuid

Response Body

application/json

curl -X DELETE "https://example.com/v1/api-keys/497f6eca-6276-4993-bfeb-53cbbbba6f08"
Empty