Skip to content
Documentation
Esc
navigateopen⌘Jpreview

Revoke an API key

Revokes the specified API key. The plaintext key is NEVER present in any response. V0 revocation is permanent; re-creating a key produces a new key_id.

Idempotent: revoking an already-revoked key returns the original revoked_at.

DELETE/v1/api-keys/{key_id}
Authorization
AuthorizationBearer token · headerrequired
`Authorization: Bearer <api_key>`
or
x-api-keyAPI key · headerrequired
`x-api-key: <api_key>`
Path parameters
key_idstringrequired
min length 1 · matches ^avtr_key_[A-Za-z0-9_-]+$
Responses
200Key revoked (or was already revoked — idempotent).
key_idstringrequired
API key identifier (server-issued, opaque).
min length 1 · matches ^avtr_key_[A-Za-z0-9_-]+$
revoked_atintegerrequired
Unix epoch milliseconds when the key was revoked.
min 0
statusstringrequired
Always `revoked`. V0 revocation is permanent.
Allowed:revoked
401API key missing or invalid.
Any of:
object
codestringrequired
Allowed:AVTR_PROVIDER_DOWNSTREAM_FAILEDAVTR_PROVIDER_TIMEOUTAVTR_PROVIDER_UNAVAILABLEAVTR_RATE_LIMIT_CONCURRENT_SESSIONSAVTR_RATE_LIMIT_EXCEEDEDAVTR_RATE_LIMIT_PROVIDER_QUOTAAVTR_RENDER_CAPACITYAVTR_RENDER_TIMEOUTAVTR_SESSION_STATE_UNAVAILABLEAVTR_SFU_CONNECTION_FAILEDAVTR_SFU_NEGOTIATION_FAILEDAVTR_SFU_ROOM_FULL
doc_urlstring<uri>required
Absolute HTTPS URL to human-facing documentation for this error code.
matches ^https:\/\/
messagestringrequired
Human-readable, provider-agnostic error message. MUST NOT contain provider names, model ids, infrastructure identifiers (Modal/D1/DO), IP addresses, stack traces, or API keys. Consumers MAY localize.
min length 1
request_idstring<uuid>required
Per-request correlation UUID. Echoes the `X-Request-Id` response header. Used to locate traces and logs.
retry_afterintegerrequired
Seconds the client SHOULD wait before retrying (1..3600). REQUIRED for retryable codes; FORBIDDEN for non-retryable codes. Clients SHOULD honor this value and SHOULD apply jitter.
min 1 · max 3600
object
codestringrequired
Allowed:AVTR_AUTH_EXPIRED_TOKENAVTR_AUTH_FORBIDDENAVTR_AUTH_INVALID_KEYAVTR_AUTH_MISSING_CREDENTIALSAVTR_AUTH_MISSING_SCOPEAVTR_PROVIDER_MISCONFIGUREDAVTR_RENDER_FAILEDAVTR_RENDER_MISCONFIGUREDAVTR_SESSION_CANCELLEDAVTR_SESSION_CONFLICTAVTR_SESSION_ENDEDAVTR_SESSION_NOT_FOUNDAVTR_SFU_NOT_CONFIGURED
doc_urlstring<uri>required
Absolute HTTPS URL to human-facing documentation for this error code.
matches ^https:\/\/
messagestringrequired
Human-readable, provider-agnostic error message. MUST NOT contain provider names, model ids, infrastructure identifiers (Modal/D1/DO), IP addresses, stack traces, or API keys. Consumers MAY localize.
min length 1
request_idstring<uuid>required
Per-request correlation UUID. Echoes the `X-Request-Id` response header. Used to locate traces and logs.
403Missing `api_keys:write` scope.
Any of:
object
codestringrequired
Allowed:AVTR_PROVIDER_DOWNSTREAM_FAILEDAVTR_PROVIDER_TIMEOUTAVTR_PROVIDER_UNAVAILABLEAVTR_RATE_LIMIT_CONCURRENT_SESSIONSAVTR_RATE_LIMIT_EXCEEDEDAVTR_RATE_LIMIT_PROVIDER_QUOTAAVTR_RENDER_CAPACITYAVTR_RENDER_TIMEOUTAVTR_SESSION_STATE_UNAVAILABLEAVTR_SFU_CONNECTION_FAILEDAVTR_SFU_NEGOTIATION_FAILEDAVTR_SFU_ROOM_FULL
doc_urlstring<uri>required
Absolute HTTPS URL to human-facing documentation for this error code.
matches ^https:\/\/
messagestringrequired
Human-readable, provider-agnostic error message. MUST NOT contain provider names, model ids, infrastructure identifiers (Modal/D1/DO), IP addresses, stack traces, or API keys. Consumers MAY localize.
min length 1
request_idstring<uuid>required
Per-request correlation UUID. Echoes the `X-Request-Id` response header. Used to locate traces and logs.
retry_afterintegerrequired
Seconds the client SHOULD wait before retrying (1..3600). REQUIRED for retryable codes; FORBIDDEN for non-retryable codes. Clients SHOULD honor this value and SHOULD apply jitter.
min 1 · max 3600
object
codestringrequired
Allowed:AVTR_AUTH_EXPIRED_TOKENAVTR_AUTH_FORBIDDENAVTR_AUTH_INVALID_KEYAVTR_AUTH_MISSING_CREDENTIALSAVTR_AUTH_MISSING_SCOPEAVTR_PROVIDER_MISCONFIGUREDAVTR_RENDER_FAILEDAVTR_RENDER_MISCONFIGUREDAVTR_SESSION_CANCELLEDAVTR_SESSION_CONFLICTAVTR_SESSION_ENDEDAVTR_SESSION_NOT_FOUNDAVTR_SFU_NOT_CONFIGURED
doc_urlstring<uri>required
Absolute HTTPS URL to human-facing documentation for this error code.
matches ^https:\/\/
messagestringrequired
Human-readable, provider-agnostic error message. MUST NOT contain provider names, model ids, infrastructure identifiers (Modal/D1/DO), IP addresses, stack traces, or API keys. Consumers MAY localize.
min length 1
request_idstring<uuid>required
Per-request correlation UUID. Echoes the `X-Request-Id` response header. Used to locate traces and logs.
404API key not found, or cross-project access denied.
Any of:
object
codestringrequired
Allowed:AVTR_PROVIDER_DOWNSTREAM_FAILEDAVTR_PROVIDER_TIMEOUTAVTR_PROVIDER_UNAVAILABLEAVTR_RATE_LIMIT_CONCURRENT_SESSIONSAVTR_RATE_LIMIT_EXCEEDEDAVTR_RATE_LIMIT_PROVIDER_QUOTAAVTR_RENDER_CAPACITYAVTR_RENDER_TIMEOUTAVTR_SESSION_STATE_UNAVAILABLEAVTR_SFU_CONNECTION_FAILEDAVTR_SFU_NEGOTIATION_FAILEDAVTR_SFU_ROOM_FULL
doc_urlstring<uri>required
Absolute HTTPS URL to human-facing documentation for this error code.
matches ^https:\/\/
messagestringrequired
Human-readable, provider-agnostic error message. MUST NOT contain provider names, model ids, infrastructure identifiers (Modal/D1/DO), IP addresses, stack traces, or API keys. Consumers MAY localize.
min length 1
request_idstring<uuid>required
Per-request correlation UUID. Echoes the `X-Request-Id` response header. Used to locate traces and logs.
retry_afterintegerrequired
Seconds the client SHOULD wait before retrying (1..3600). REQUIRED for retryable codes; FORBIDDEN for non-retryable codes. Clients SHOULD honor this value and SHOULD apply jitter.
min 1 · max 3600
object
codestringrequired
Allowed:AVTR_AUTH_EXPIRED_TOKENAVTR_AUTH_FORBIDDENAVTR_AUTH_INVALID_KEYAVTR_AUTH_MISSING_CREDENTIALSAVTR_AUTH_MISSING_SCOPEAVTR_PROVIDER_MISCONFIGUREDAVTR_RENDER_FAILEDAVTR_RENDER_MISCONFIGUREDAVTR_SESSION_CANCELLEDAVTR_SESSION_CONFLICTAVTR_SESSION_ENDEDAVTR_SESSION_NOT_FOUNDAVTR_SFU_NOT_CONFIGURED
doc_urlstring<uri>required
Absolute HTTPS URL to human-facing documentation for this error code.
matches ^https:\/\/
messagestringrequired
Human-readable, provider-agnostic error message. MUST NOT contain provider names, model ids, infrastructure identifiers (Modal/D1/DO), IP addresses, stack traces, or API keys. Consumers MAY localize.
min length 1
request_idstring<uuid>required
Per-request correlation UUID. Echoes the `X-Request-Id` response header. Used to locate traces and logs.
429Rate limit exceeded.
Any of:
object
codestringrequired
Allowed:AVTR_PROVIDER_DOWNSTREAM_FAILEDAVTR_PROVIDER_TIMEOUTAVTR_PROVIDER_UNAVAILABLEAVTR_RATE_LIMIT_CONCURRENT_SESSIONSAVTR_RATE_LIMIT_EXCEEDEDAVTR_RATE_LIMIT_PROVIDER_QUOTAAVTR_RENDER_CAPACITYAVTR_RENDER_TIMEOUTAVTR_SESSION_STATE_UNAVAILABLEAVTR_SFU_CONNECTION_FAILEDAVTR_SFU_NEGOTIATION_FAILEDAVTR_SFU_ROOM_FULL
doc_urlstring<uri>required
Absolute HTTPS URL to human-facing documentation for this error code.
matches ^https:\/\/
messagestringrequired
Human-readable, provider-agnostic error message. MUST NOT contain provider names, model ids, infrastructure identifiers (Modal/D1/DO), IP addresses, stack traces, or API keys. Consumers MAY localize.
min length 1
request_idstring<uuid>required
Per-request correlation UUID. Echoes the `X-Request-Id` response header. Used to locate traces and logs.
retry_afterintegerrequired
Seconds the client SHOULD wait before retrying (1..3600). REQUIRED for retryable codes; FORBIDDEN for non-retryable codes. Clients SHOULD honor this value and SHOULD apply jitter.
min 1 · max 3600
object
codestringrequired
Allowed:AVTR_AUTH_EXPIRED_TOKENAVTR_AUTH_FORBIDDENAVTR_AUTH_INVALID_KEYAVTR_AUTH_MISSING_CREDENTIALSAVTR_AUTH_MISSING_SCOPEAVTR_PROVIDER_MISCONFIGUREDAVTR_RENDER_FAILEDAVTR_RENDER_MISCONFIGUREDAVTR_SESSION_CANCELLEDAVTR_SESSION_CONFLICTAVTR_SESSION_ENDEDAVTR_SESSION_NOT_FOUNDAVTR_SFU_NOT_CONFIGURED
doc_urlstring<uri>required
Absolute HTTPS URL to human-facing documentation for this error code.
matches ^https:\/\/
messagestringrequired
Human-readable, provider-agnostic error message. MUST NOT contain provider names, model ids, infrastructure identifiers (Modal/D1/DO), IP addresses, stack traces, or API keys. Consumers MAY localize.
min length 1
request_idstring<uuid>required
Per-request correlation UUID. Echoes the `X-Request-Id` response header. Used to locate traces and logs.
Try it
Server
Authorization
Parameters
Request
curl -X DELETE "https://api.avtr.internal/v1/v1/api-keys/avtr_key_01HABCDEFGH" \
  -H "Authorization: Bearer YOUR_TOKEN"
Response
{
  "key_id": "avtr_key_01HABCDEFGH",
  "revoked_at": 0,
  "status": "revoked"
}