---
search:
  tags:
    - API keys
    - DELETE
seo:
  description: >-
    Ends an API key at once. Requests that send it are refused from then on.
    Reference for the DELETE /_luna/tokens/{id} endpoint in the Luna API.
sidebar:
  label: Revoke an API key
  badge: DELETE
title: Revoke an API key
type: openapi-operation
---
Ends an API key at once. Requests that send it are refused from then on.

`DELETE /_luna/tokens/{id}`

**Responses**

- `200` — Whether a key was revoked.
- `default` — The request failed. The status says how and \`error.message\` says why.

Response example, 200:

```json
{
  "revoked": true
}
```
