Bring Your Own Key (BYOK)
Connect an LLM Gateway, OpenRouter, or CrofAI API key for Critique review and chat, with the same $8/month harness and provider-billed model tokens.
BYOK (Bring Your Own Key) means you connect an LLM Gateway, OpenRouter, or CrofAI (nahcrof) API key in Critique Settings. Critique still runs the product — sandboxes, GitHub checks, repository context, usage telemetry — but model inference is billed to your provider account, not drawn from Critique’s bundled credit pool.
BYOK is about who pays for tokens. BYOA is about who runs the fix agent (Cursor, Codex, Claude Code, Copilot). Connections is about third-party product APIs (Linear, future Slack/Sentry) and crt_ keys for MCP/REST — not model billing. Teams often combine all three: LLM Gateway or OpenRouter BYOK for review depth, BYOA or Remedy for fixes, Linear in Connections for ticket context.
Bundled credits vs BYOK harness
| Bundled plan (Solo / Pro / Team) | BYOK harness | |
|---|---|---|
| You pay Critique for | Monthly credit pool + orchestration | $8/month product harness (Pricing) |
| You pay for model tokens | Through Critique credits | Directly on your BYOK provider |
| Best when | One invoice, predictable bundles | You already use LLM Gateway, OpenRouter, or CrofAI and want raw provider bills and limits |
| Provider key | Not required | Required in Settings |
The harness fee covers orchestration Critique would run anyway: E2B sandboxes for sandbox-native review, OpenCode inside those sandboxes, chat streaming, GitHub publication, repository retrieval, encrypted key storage, and usage ledgers. It is not a markup on every token.
Set up LLM Gateway BYOK
LLM Gateway provides an OpenAI-compatible API at https://api.llmgateway.io/v1 and publishes a broad catalog similar to OpenRouter. As of 29 June 2026, its providers page lists 296 models across 38 providers; Critique currently exposes 35 review-capable models in its review/Remedy catalog.
- Create or sign in to an LLM Gateway account and create an API key.
- In Critique, open Settings → Agents → Bring your own LLM Gateway key.
- Paste the key and Save encrypted key.
- Confirm Usage shows LLM Gateway-backed calls as externally billed where applicable.
When LLM Gateway is active, Critique keeps the same model picker and routes selected model ids through https://api.llmgateway.io/v1. If LLM Gateway, Crof, and OpenRouter keys are all saved, LLM Gateway takes precedence.
Set up OpenRouter BYOK
- Create or sign in to an OpenRouter account and create an API key.
- In Critique, open Settings → Agents → Bring your own OpenRouter key.
- Paste the key and Save encrypted key. Critique stores only a hint (last characters) in the UI after save.
- Confirm Usage shows OpenRouter-backed runs as externally billed where applicable.
Set up CrofAI BYOK
CrofAI (nahcrof) hosts open-weight models through an OpenAI-compatible API. Critique uses the same $8/month harness but switches the upstream endpoint to https://crof.ai/v1 and maps OpenRouter catalog ids (for example moonshotai/kimi-k2.6) to Crof slugs (kimi-k2.6).
- Create a Crof account at ai.nahcrof.com and create an API key.
- In Settings → Agents, open Bring your own CrofAI key.
- Save the key encrypted. New chat and sandbox review runs bill Crof directly.
- If LLM Gateway is not saved and you also save an OpenRouter key, Crof takes precedence until you remove it.
Model picker vs Crof catalog
Critique’s model picker is OpenRouter-shaped. Crof exposes a wider OSS catalog via GET https://crof.ai/v1/models — Kimi K2.6, DeepSeek V4, GLM 5.1, Greg 1, and precision/lightning variants. Frontier OpenAI and Anthropic models in Critique policy are not available on Crof’s OpenAI endpoint; use OpenRouter BYOK for those lanes.
Keys are encrypted at rest and decrypted only server-side for model calls. They are never returned to the browser after save.
BYOK vs execution agents
Saving an OpenRouter key does not replace Cursor, Claude Managed Agent, Codex, or Claude Code for fixes. It changes which account pays for Critique’s review and chat models. To queue fixes on external agents, add BYOA keys in Settings — see BYOA.
What uses your BYOK provider key
When a saved LLM Gateway, OpenRouter, or Crof key is enabled:
| Surface | Behavior |
|---|---|
| Critique Chat | New chat model calls prefer your active BYOK provider; usage is attributed to that provider bill. |
| Sandbox-native PR review | OpenCode runs inside the review sandbox with your key injected; telemetry still appears in Critique Usage with zero Critique credits for those model calls when marked externally billed. |
| Managed review without sandbox | May still use Critique’s managed routing depending on repository path and configuration — check Usage after your first runs. |
Critique continues to record stages, call metadata, and token counts where available so you can reconcile against the OpenRouter dashboard.
Credits and review gates
With an active BYOK provider key:
- Model calls on the BYOK path typically show 0 Critique credits in Usage (OpenRouter invoices you separately).
- PR review queue gate — Teams with BYOK can queue automated reviews even when the Critique credit balance is below the usual minimum for managed review (because inference is not on Critique’s pool). You still need an active Critique subscription that includes the BYOK harness where your plan requires it.
- Non-model work — Sandboxes, indexing, Remedy on managed models, builder jobs, and similar surfaces may still consume Critique credits unless they are also on a BYOK path.
Check Dashboard → Usage after onboarding — it is the source of truth for your account.
When to choose BYOK
Choose BYOK if you:
- Already centralize spend on OpenRouter with budgets, alerts, and model allowlists.
- Run high-variance review volume and want provider-native invoices instead of larger bundled tiers.
- Want frontier models on OpenRouter without buying the largest Critique credit bundle.
Choose bundled credits if you:
- Prefer one line item from Critique for procurement.
- Are evaluating Critique before wiring another vendor key.
- Want simplicity over splitting harness + OpenRouter bills.
Operations checklist
- Set OpenRouter spend limits on the key you give Critique.
- Pick models in review policy that your OpenRouter account can access (Models, Policy fields).
- After the first PR review and chat session, open Usage and confirm
externally billed/ BYOK labeling matches expectations. - For fixes, pick Remedy, BYOA queueing (Cursor, Claude, Codex), or Fix prompt — BYOK does not auto-run those agents.
Related
- Billing & credits
- Bring your own agent — Cursor, Claude Managed Agent, OpenAI Codex, Fix prompt
- Connections & Platform API — Linear, MCP,
crt_keys (not BYOK) - Settings → Agents — OpenRouter, Crof, and BYOA key panels