Overview
Revokes an API key, immediately invalidating it. Any system currently using this key will begin receiving 401 Unauthorized errors.
Required role: admin or owner
Revoking a key is immediate. Any webhooks or integrations using this key will start receiving 401 errors right away. Update your monitoring tool configuration before revoking to avoid gaps in alert delivery.
Path parameters
The unique identifier of the API key to revoke. Example: key_01HX9VTPQR3KF8MZWBYD5N6JCE.
Response
Returns 204 No Content on success. No response body is returned.
Error responses
| Status | Error code | Description |
|---|
403 | forbidden | The authenticated user does not have admin or owner role |
404 | not_found | No API key exists with the provided keyId for this tenant |
409 | conflict | The API key has already been revoked |
Examples
curl https://api.causeflow.ai/v1/api-keys/key_01HX9VTPQR3KF8MZWBYD5N6JCE \
-X DELETE \
-H "Authorization: Bearer <token>"