Providers

Quantized routes each request to a provider based on the endpoint and your configuration. You don’t need to manage separate API keys or accounts for each provider.

Supported providers

Provider Slug Capabilities
OpenRouter openrouter Chat completions, Responses, Models
Anthropic anthropic Chat completions, Models
Exa exa Web search, Content fetch
Tavily tavily Web search, Content fetch

Default routing

Each capability has a default provider:

Capability Default Provider
Chat completions OpenRouter
Responses OpenRouter
Models OpenRouter
Web search Exa
Content fetch Exa

Choosing a provider

Use the X-Quantized-Provider header to override the default:

# Use Anthropic directly instead of OpenRouter
curl -X POST https://api.quantized.us/v1/chat/completions \
  -H "Authorization: Bearer sk-quantized-YOUR-KEY" \
  -H "X-Quantized-Provider: anthropic" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "claude-sonnet-4-20250514",
    "messages": [{"role": "user", "content": "Hello!"}]
  }'
# Use Tavily instead of Exa for web search
curl -X POST https://api.quantized.us/v1/web-search \
  -H "Authorization: Bearer sk-quantized-YOUR-KEY" \
  -H "X-Quantized-Provider: tavily" \
  -H "Content-Type: application/json" \
  -d '{"query": "latest AI news"}'
Model naming

When using OpenRouter, models use the provider/model format (e.g., openai/gpt-4.1-mini).
When using Anthropic directly, use the native model ID (e.g., claude-sonnet-4-20250514).

Capability matrix

Endpoint OpenRouter Anthropic Exa Tavily
POST /v1/chat/completions Yes (default) Yes
POST /v1/responses Yes (default)
GET /v1/models Yes (default) Yes
POST /v1/web-search Yes (default) Yes
POST /v1/fetch Yes (default) Yes

Provider errors

If the upstream provider fails (timeout, rate limit, authentication error), Quantized returns a 503 with a generic message:

{
  "error": {
    "message": "Service temporarily unavailable"
  }
}

Internal provider errors are masked to avoid leaking infrastructure details. See Errors for the full error reference.