OpenRouter provider reference
@tailored-ai/provider-openrouter connects hundreds of models across vendors
through one API key. OpenRouter speaks the OpenAI wire format, so the plugin is
a thin configuration of core's OpenAIProvider: chat, streaming, tool calling,
and model discovery work out of the box.
Still choosing a model API? Start with Configure a model provider, then return here for OpenRouter-specific options.
Install
tai plugin install @tailored-ai/provider-openrouter
The installer adds the package to your plugins: list automatically.
Configure
providers:
openrouter:
apiKey: "${OPENROUTER_API_KEY}" # https://openrouter.ai/keys
defaultModel: "anthropic/claude-haiku-4.5"
agent:
defaultProvider: openrouter
Per-agent override:
agents:
researcher:
provider: openrouter
model: "google/gemini-2.5-flash"
| Field | Required | Notes |
|---|---|---|
apiKey | yes | Use ${OPENROUTER_API_KEY} to read from the environment. |
defaultModel | yes | An OpenRouter model id (vendor/model). |
baseUrl | no | Defaults to https://openrouter.ai/api/v1. Override for proxies. |
Model ids
OpenRouter ids are vendor/model, optionally with a :variant suffix (:free, :nitro). Browse at openrouter.ai/models — or run tai edit, where the model field lists the catalog via listModels.
Not yet
Attribution headers (HTTP-Referer / X-Title, used for OpenRouter's app rankings) and provider-routing preferences need a small core seam, tracked in #234.