> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mailofly.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Delete API key

> Permanently revoke an API key.

Revoke an API key immediately. Any subsequent calls utilizing this key will be rejected with `401 Unauthorized`.

### Path Parameters

<ParamField path="id" type="string" required>
  The unique identifier of the API key to revoke.
</ParamField>

### Response

<ResponseField name="data" type="object">
  <ResponseField name="success" type="boolean">True if revoked.</ResponseField>
  <ResponseField name="id" type="string">Revoked key ID.</ResponseField>
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X DELETE https://api.mailofly.com/api/v1/api-keys/key_123456 \
    -H "Authorization: Bearer mf_live_your_api_key"
  ```
</RequestExample>

<ResponseExample>
  ```json 200 OK theme={null}
  {
    "data": {
      "success": true,
      "id": "key_123456"
    }
  }
  ```
</ResponseExample>


## Related topics

- [API Key Security](/guides/api-keys/api-key-security.md)
- [Manage API Keys](/guides/api-keys/manage-api-keys.md)
- [Leaked API Keys](/guides/api-keys/leaked-api-keys.md)
- [Create API key](/api/api-keys/create-api-key.md)
- [List API keys](/api/api-keys/list-api-keys.md)
