---
title: "List API keys"
method: GET
path: "/api/token/"
---

# List API keys

`GET /api/token/`

List API keys for the authenticated account. The newest keys are returned first.

## Query parameters

- `p` integer
- `page_size` integer

## Response `200`

Paginated API key list.

- object
  - `success` boolean, required
  - `message` string, required
  - `data` object, required
    - `page` integer, required
    - `page_size` integer, required
    - `total` integer, required
    - `items` ApiKey[], required
      - `id` integer — Numeric API key ID. Use this value with the get, update, and delete endpoints.
      - `user_id` integer — Account user ID that owns the key.
      - `key` string — API key value returned by the management API. Treat it as a secret and use it as `Authorization: Bearer $COMETAPI_KEY` for model requests.
      - `status` 1 | 2 | 3 | 4 — Operational status for the key. `1` means enabled, `2` disabled, `3` expired, and `4` exhausted. Only enabled keys are accepted by model endpoints.
      - `name` string — User-readable display name for the API key.
      - `created_time` integer — Unix timestamp in seconds when the key was created.
      - `accessed_time` integer — Unix timestamp in seconds when the key was last used. Newly created keys may show the creation time until first use.
      - `expired_time` integer — Unix timestamp in seconds when the key expires. `-1` means no expiration.
      - `remain_quota` integer — Remaining quota for this key in CometAPI internal quota units. When this reaches `0` and `unlimited_quota` is `false`, model requests are rejected as quota exhausted.
      - `unlimited_quota` boolean — Whether the key bypasses remaining-quota checks.
      - `model_limits_enabled` boolean — Whether model restrictions are active for this key. When `false`, `model_limits` is ignored.
      - `model_limits` string — Comma-separated model IDs allowed by this key when `model_limits_enabled` is `true`. Empty means no configured model list.
      - `allow_ips` string, nullable — Optional IP allowlist stored as one newline-separated string. Each entry can be a single IPv4 address, single IPv6 address, IPv4 CIDR, or IPv6 CIDR. Example: `198.51.100.10\n203.0.113.0/24\n2001:db8::/32`. `null` or `""` means IP restrictions are disabled.
      - `used_quota` integer — Quota already consumed by this key in CometAPI internal quota units.
      - `group` string — Account group restriction for this key. Empty means no explicit group restriction.
      - `cross_group_retry` boolean — Whether cross-group retry is enabled for automatic group routing. This is only meaningful when the key uses an auto-routed group such as `auto`.

---

[API](https://skmtc.net/cometapi/apis/create-api-key.md) · [All operations](https://skmtc.net/cometapi/apis/create-api-key/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/cometapi/create-api-key/versions/0863102dbf34/schema)
