---
title: "List Api Keys"
method: GET
path: "/api/v1/keys"
tags: ["API Keys"]
---

# List Api Keys

`GET /api/v1/keys`

## Request

- Base URL: `https://api.seoproai.co`
- URL: `https://api.seoproai.co/api/v1/keys`
- Auth: one of:
  - HTTP bearer
  - OAuth 2 (authorization code, authorization URL `https://dajosjnaalanhqksxrpe.supabase.co/auth/v1/authorize`, token URL `https://dajosjnaalanhqksxrpe.supabase.co/auth/v1/token`)

List all API keys for the authenticated user.

Returns all API keys with metadata but NOT the full keys.

Args:
    user_id: Authenticated user ID (from JWT)
    db: Database client

Returns:
    List of API keys with metadata

## Headers

- `X-User-Id` string, nullable
- `X-Organization-Id` string, nullable
- `Authorization` string, nullable

## Response `200`

Successful Response

- APIKeyListResponse: Response model for listing all API keys
  - `keys` APIKeyListItem[], required
    - `id` string, required
    - `name` string, required
    - `key_prefix` string, required
    - `created_at` string, required
    - `last_used_at` string, nullable, required
    - `expires_at` string, nullable, required
    - `is_active` boolean, required
    - `scopes` string[], required
    - `request_count` integer
  - `total` integer, required

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/seoproai/apis/seopro-ai.md) · [All operations](https://skmtc.dev/seoproai/apis/seopro-ai/llms.txt) · [OpenAPI document](https://skmtc.dev/seoproai/apis/seopro-ai/revisions/5b4b6391ddc9?raw)
