Bring your own key (BYOK)
BYOK lets you route requests through your own OpenRouter key. When active for a model, KhaBot calls OpenRouter directly with your key.
- Billed at $0 by KhaBot — you pay OpenRouter directly.
- Does not consume your dollar quotas.
- Does count toward your rate limit.
- Works on
/api/v1/chat/completionsonly.
BYOK applies to chat on KhaBot's own (khabot/) models only. Pass-through OpenRouter models always run
on KhaBot's key and bill your credit at the provider's cost — see Drop-in from OpenRouter.
BYOK is off by default. An admin enables it per account. Once enabled, manage keys under Dashboard → BYOK.
Managing keys
Add one or more OpenRouter keys, mark a default, and optionally map specific models to specific keys.
Endpoints: GET/POST /api/byok/keys, PATCH/DELETE /api/byok/keys/:id
(they return 403 byok_not_enabled until enabled for you).