Skip to content
Sign in Create account

List dashboard API keys

GET /api/keys

Lists non-deleted API-key resources and recently revoked keys that remain within the three-day restore window. A revoked key includes its key prefix and restorable_until timestamp; it does not include a revoked_at field or plaintext key material. Requires keys.read and api-keys.read.

Authenticate with a portal session token.

Responses

200 Non-deleted API keys and keys revoked within the three-day restore window that were not rotated out. Key resources include a prefix and never plaintext key material.

application/json object

  • api_keys array of ApiKeyResourceC6b required
  • revoked_keys array of any required

    Each item:

    All of

    • ApiKeyResourceC6b
    • object
      • restorable_until string (date-time) required

        Time when the three-day restore window ends.

Generated sample

{
  "api_keys": [
    {
      "allowed_ips": [
        "string"
      ],
      "created_at": "2026-01-01T00:00:00Z",
      "expires_at": "2026-01-01T00:00:00Z",
      "id": 0,
      "is_active": true,
      "is_default": true,
      "last_used_at": "2026-01-01T00:00:00Z",
      "mirrors_account_settings": true,
      "name": "string",
      "permissions": [
        "string"
      ],
      "prefix": "string",
      "privacy_tier_override": "balanced",
      "rate_limit_rpm": 0
    }
  ],
  "revoked_keys": [
    {
      "allowed_ips": [
        "string"
      ],
      "created_at": "2026-01-01T00:00:00Z",
      "expires_at": "2026-01-01T00:00:00Z",
      "id": 0,
      "is_active": true,
      "is_default": true,
      "last_used_at": "2026-01-01T00:00:00Z",
      "mirrors_account_settings": true,
      "name": "string",
      "permissions": [
        "string"
      ],
      "prefix": "string",
      "privacy_tier_override": "balanced",
      "rate_limit_rpm": 0,
      "restorable_until": "2026-01-01T00:00:00Z"
    }
  ]
}
401 Missing or invalid bearer token.

application/json object

Any keys are accepted.

403 Authenticated caller lacks the required permission, ability, or role.

application/json object

Any keys are accepted.

429 The request was rate limited. API-generated responses are JSON;

Response headers

  • Retry-After string header

    Seconds to wait before retrying, when provided.

  • X-RateLimit-Scope string header

    Identifies the scope of the request limit, when provided.

application/json GenericError

  • error any

    One of

    • string
    • object

      Any keys are accepted.

  • error_code string
  • code string
  • message string
  • detail string
  • status any

    One of

    • string
    • integer
  • errors object

    Any keys are accepted.

text/html string