Customer-controlled keys
Your DeepSeek key stays in the router process on your machine or server. Agents receive only the Tekiz endpoint and optional client key.
DeepSeek BYOK
Put one or more DeepSeek API keys on your Tekiz host, point Codex
or any OpenAI-compatible client at port 8790, and keep
failures isolated to the key that failed.
Your DeepSeek key stays in the router process on your machine or server. Agents receive only the Tekiz endpoint and optional client key.
A 401, 402, 403, or 429 cools the affected credential fingerprint. Other DeepSeek keys and eligible provider routes remain available.
Use deepseek/deepseek-v4-flash directly or let Balanced
and Frontier profiles choose among authorized routes.
DEEPSEEK_API_KEY on the machine running Sage
Router, then start the router on port 8790.
http://127.0.0.1:8790/v1. The
provider key does not need to be copied into Codex or another
agent.
export DEEPSEEK_API_KEY=your_deepseek_key
git clone https://github.com/earlvanze/sage-router.git
cd sage-router
python3 router.py --port 8790
curl http://127.0.0.1:8790/v1/chat/completions \
-H 'Content-Type: application/json' \
-d '{
"model": "deepseek/deepseek-v4-flash",
"messages": [{"role": "user", "content": "Reply with DEEPSEEK_OK"}]
}'
Teams can configure an ordered pool for separate accounts, quota domains, or key rotation. A failed key does not disable DeepSeek provider-wide.
export SAGE_ROUTER_DEEPSEEK_API_KEYS='["team-a-key","team-b-key"]' export SAGE_ROUTER_CREDENTIAL_STRATEGY=failover
Supported strategies are failover,
round-robin, lru, and random.
[model_providers.sage_router] name = "Tekiz" base_url = "http://127.0.0.1:8790/v1" env_key = "SAGE_ROUTER_API_KEY" wire_api = "responses" [profiles.sage_deepseek] model_provider = "sage_router" model = "deepseek/deepseek-v4-flash"
DeepSeek currently documents V4 Flash as its Codex-compatible model.
Use codex --profile sage_deepseek.
A generated sk_sage_* key uses hosted capacity enabled
for your Tekiz account. A
DEEPSEEK_API_KEY environment variable belongs on your
self-hosted router; setting it on a client does not upload it to the
hosted service. See the
integration matrix for BYOK, BYOS, local,
and managed-access boundaries.