Repository navigation
feat: add OrcaRouter as a named OpenAI-compatible gateway provider - #818
Merged
Merged
Conversation
pancacake
added a commit
that referenced
this pull request
Aug 12, 2026
An adversarial pass over #818 / #789 / #780 after merging. **Codex sign-ins from before this week stopped working (#789).** ``validate_runtime_profile`` compared the profile's ``codex_account_binding`` for equality, but that key is written only by ``sync_codex_catalog`` — every managed profile published by #690/#774 has none, so ``None != <hash>`` made each of them look like another account's and locked its owner out of Codex until they re-ran "Refresh models". Absent now reads as legacy; a binding that is present and different is still an account switch and still refused. **Overriding reasoning effort for one turn returned 409 (#789).** The same function also required the request's effort to be byte-equal to the value stored in the catalog. Effort is a per-request knob, not part of the identity that ties a config to a token — the check now stops at model membership. Its test asserted the old behaviour and has been rewritten around what the function is actually for. **The reasoning-effort endpoint left the runtime caches stale (#789).** It writes the catalog the runtime resolves against, like every other catalog write in this router, but skipped ``_invalidate_runtime_caches()``. **OrcaRouter claimed Anthropic prompt caching (#818).** ``supports_prompt_caching`` makes ``_build_kwargs`` inject ``cache_control`` blocks into any ``anthropic/*`` or ``claude*`` request — an OpenRouter extension. No other gateway sets it and nothing established the second one accepts it; a strict gateway would 400 every Claude turn. Also fixed ``anthropic/claude-sonnet-4.6`` in the fallback list, which the rest of the repo spells with dashes, so a user picking it from our own menu would have got "model not found". **OrcaRouter inserted itself into the curated menus (#818).** The featured lists are hand-picked and rendered as a positional numbered menu, so adding an entry shifted Ollama from [10] to [11]. The registry entry alone already makes a provider reachable via "Show all" and the Settings dropdown; which providers are featured is a maintainer decision. The README paragraph goes with it — no other provider has per-provider prose there, and it would have been translated into ten languages.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This registers OrcaRouter the same way the existing OpenRouter provider is wired, so the model picker, config reference and docs stay consistent. OrcaRouter is an OpenAI-compatible gateway: one
ORCAROUTER_API_KEY(keys start withsk-orca-) unlocks 150+ models from OpenAI, Anthropic, Google, DeepSeek, Qwen, MiniMax and xAI behind a singlehttps://api.orcarouter.ai/v1endpoint. It also runs gateway-level, zero-trust security for AI agents on the same endpoint — screening every prompt/response and governing every tool call on a default-deny basis, with no application code changes.I'm an engineer on the OrcaRouter team.
Related Issues
Module(s) Affected
agentsapiconfigcoreknowledgeloggingservicestoolsutilsweb(Frontend)docs(Documentation)scriptstests...Checklist
pre-commit run --all-filesand fixed any issues.