Build
Routing
Forge can pick the best upstream channel for a request based on price, latency, region, or a fallback chain you define.
Modes
cheapest— minimum cost among eligible channels.fastest— lowest p50 TTFT in the last 5 minutes.balanced(default) — weighted score across cost, latency, and recent error rate.pinned— always use the exact channel set on the key.
Per-request override
bashbash
curl https://api.cytokenhub.com/v1/chat/completions \
-H "Authorization: Bearer $FORGE_KEY" \
-H "X-Forge-Route: cheapest" \
-d '{ "model": "anthropic/claude-4.5-sonnet", "messages": [...] }'Fallback chains
Provide a comma-separated list of model IDs. Forge tries each in order and falls through on 429 / 5xx / timeout.
httphttp
X-Forge-Route: openai/gpt-5,anthropic/claude-4.5-sonnet,google/gemini-3-pro
Routing rules in the console
Open Channels → Routes in the console to author rules declaratively — match by model glob, region, or header, then choose a channel and a fallback chain. Rules are evaluated top-down.