models.fyi

One key. Every model, every host, every effort.

The gateway speaks the OpenAI Chat Completions dialect, so existing SDKs work by changing the base URL. What's new: the model id addresses a specific serving (host + quantization), and reasoning_effort is a first-class routing parameter — the two dimensions the analysis pages measure.

https://models.fyi/api/v1

local dev: http://localhost:3000/api/v1

Bearer mfyi_…

create keys on /dashboard

mock placeholder

env-switchable to any OpenAI-compatible upstream

Three requests to fluency

1 · chat completion (host-pinned)
curl https://models.fyi/api/v1/chat/completions \
  -H "Authorization: Bearer $MFYI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "glm-5.2@fireworks",
    "reasoning_effort": "medium",
    "messages": [{"role": "user", "content": "Summarize this diff..."}]
  }'
2 · streaming (SSE passthrough)
curl -N https://models.fyi/api/v1/chat/completions \
  -H "Authorization: Bearer $MFYI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "gpt-5.5", "stream": true,
       "messages": [{"role": "user", "content": "hi"}]}'
openai sdk · javascript
import OpenAI from "openai";

const client = new OpenAI({
  baseURL: "https://models.fyi/api/v1",
  apiKey: process.env.MFYI_API_KEY,
});

const res = await client.chat.completions.create({
  model: "claude-fable-5",
  reasoning_effort: "high",
  messages: [{ role: "user", content: "Refactor this function..." }],
});
openai sdk · python
from openai import OpenAI

client = OpenAI(
    base_url="https://models.fyi/api/v1",
    api_key=os.environ["MFYI_API_KEY"],
)

res = client.chat.completions.create(
    model="deepseek-v3.2",
    reasoning_effort="low",   # the sweet spot for everyday tasks
    messages=[{"role": "user", "content": "Draft a reply..."}],
)

Ids that name a serving, not a vibe

IdMeaning
glm-5.2Reference serving (official host) of GLM-5.2
glm-5.2@fireworksSame weights served by Fireworks (fp8) — different scores, price, speed
kimi-k2-thinking@groqGroq serving — 720 tok/s, −3.5% quality; the trade-off is yours to make

Full catalog with per-variant pricing: GET /api/v1/models (no auth required). Every id and its measured scores appear on the model pages.

reasoning_effort, resolved honestly

  • Tiers: minimal · low · medium · high · xhigh. If a model doesn't support the tier you asked for, the gateway resolves to the nearest lower supported tier — the same rule the leaderboard uses.
  • Defaults are per-model (each model's page shows its default and its sweet spots). Omitting the field uses the default, never silently xhigh.
  • Usage records store the resolved effort, so your dashboard shows spend per tier — the bill finally matches the quality dial.
error shape (openai-compatible)
{
  "error": {
    "message": "Model 'glm-9' not found. List ids via GET /api/v1/models ...",
    "type": "invalid_request_error",
    "code": "model_not_found"
  }
}

Official providers, routed per model

Each model routes to its official provider's API — set a provider key and its models go live (translation to native dialects, e.g. the Anthropic Messages API, happens inside the gateway; the client contract never changes). GET /api/v1/models reports upstream: "live" | "mock" per model. Models without a key answer from the clearly-labeled built-in mock, so the full contract runs end-to-end either way.

environment
OPENAI_API_KEY=sk-...        # gpt-5.5
ANTHROPIC_API_KEY=sk-ant-... # claude-fable-5 · claude-opus-4.8 · claude-sonnet-5
GOOGLE_API_KEY=AIza...       # gemini-3-pro

# optional global fallback for unrouted models (any OpenAI-compatible endpoint)
UPSTREAM_BASE_URL=https://openrouter.ai/api/v1
UPSTREAM_API_KEY=sk-...