AgentRouterDocsStorefront ↗
Menu

Discover models

Read the public model catalog

No authentication or payment is required. HTTP 200 returns a JSON array, not an OpenAI object/list envelope; an empty array is valid. Each model has id, protocols, context_length, max_output_tokens, input_per_1m, and output_per_1m. Prices are USD per million tokens as decimal strings. Optional fields include aliases, cache prices, and free.

Use an offered model with the desired protocol; do not copy old fixture prices. On HTTP 429, respect Retry-After. Browser cross-origin access requires verified CORS.

Request

Shell
curl -sS https://api.agentrouter.cc/v1/models

Expected response

Response schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "HTTP 200 public model catalog body",
  "type": "array",
  "items": {
    "type": "object",
    "required": ["id", "input_per_1m", "output_per_1m", "context_length", "max_output_tokens", "protocols"],
    "properties": {
      "id": { "type": "string" },
      "aliases": { "type": "array", "items": { "type": "string" } },
      "input_per_1m": { "type": "string" },
      "output_per_1m": { "type": "string" },
      "cache_read_per_1m": { "type": "string" },
      "cache_write_per_1m": { "type": "string" },
      "free": { "type": "boolean" },
      "context_length": { "type": "integer" },
      "max_output_tokens": { "type": "integer" },
      "protocols": {
        "type": "array",
        "items": { "type": "string", "enum": ["openai", "anthropic"] }
      }
    }
  }
}