API Keys
Revoke API Key
Permanently revoke an API key by setting its revokedAt timestamp. Once revoked, the key can no longer authenticate API requests. This action cannot be undone. The key remains in the database for audit purposes but is no longer usable.
Authorization
bearerAuth AuthorizationBearer <token>
Use your secret API key as the bearer token
In: header
Path Parameters
id*string
The API key ID to revoke (must start with 'key_' prefix)
Match
^key_Response Body
application/json
application/json
application/json
curl -X DELETE "https://api.getlumen.dev/v1/api-keys/string"{
"success": true,
"data": {
"id": "key_abc123xyz",
"revokedAt": "2025-02-20T15:45:12.982Z"
}
}{
"error": "API key not found"
}{
"error": "Failed to revoke API key",
"details": "Database write failure"
}