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

# Delete Token

> Delete a specified API token

> Last updated: 2026-06-06

## Overview

Permanently delete a specified API token. The token's API Key will be invalidated immediately after deletion.

<Note>
  The `/api/token/*` endpoints are mainly for Crazyrouter dashboard automation around API key management. They require a user `access token` plus the `New-Api-User` header, and are not the normal interface for `sk-xxx` model calls.
</Note>

## Authentication

Use user-side authentication with these headers:

```text theme={null}
Authorization: Bearer your_access_token
New-Api-User: 1
```

## Path Parameters

<ParamField path="id" type="integer" required>
  ID of the token to delete
</ParamField>

## Response Format

```json theme={null}
{
  "success": true,
  "message": "Token deleted successfully"
}
```

## Code Examples

<CodeGroup>
  ```python Python theme={null}
  import requests

  headers = {
      "Authorization": "Bearer your_access_token",
      "New-Api-User": "1",
      "User-Agent": "Mozilla/5.0"
  }

  token_id = 10
  response = requests.delete(
      f"https://api.crazyrouter.com/api/token/{token_id}",
      headers=headers
  )

  print(response.json())
  ```

  ```bash cURL theme={null}
  curl -X DELETE https://api.crazyrouter.com/api/token/10 \
    -H "Authorization: Bearer your_access_token" \
    -H "New-Api-User: 1"
  ```
</CodeGroup>

<Warning>
  This operation is irreversible. All applications using this Key will immediately lose API access.
</Warning>
