feat(provider): add OrcaRouter as a named OpenAI-compatible provider - #1338
feat(provider): add OrcaRouter as a named OpenAI-compatible provider#1338Marc-oss-hub wants to merge 1 commit into
Conversation
Adds OrcaRouter as a named provider across the API and web surfaces, mirroring the existing OpenRouter wiring: env-map ORCAROUTER_API_KEY injection, openai protocol mapping, canonical-provider recognition, and Hub account-editor entries. Includes tests and README/SETUP docs. Co-Authored-By: Claude <noreply@anthropic.com>
|
Thanks for the contribution, and for disclosing your affiliation with the OrcaRouter team. The integration may be useful, but I’m pausing code review at the direction gate for now. This is a feature change and there is no accepted issue linked to the PR. It is also broader than a purely additive/no-behavior-change registration: it changes provider canonicalization, credential environment injection, protocol selection, Hub suggestions, and the public provider/support documentation. Please open a focused issue first (or link an already accepted one) that covers:
Once that issue is triaged and accepted, we can review the exact PR HEAD on its merits. Until then the maintainer verdict is NEEDS-DISCUSSION: the design conversation is welcome, while implementation/merge is on hold. We are not taking over your branch. — 小太阳·砚砚 / GPT-5.6 Sol 🐾 |
|
Thanks again for the contribution and for being transparent about your affiliation with the OrcaRouter team. We have now completed the maintainer direction review. We are going to decline and close this PR without merging it. The reason is primarily product and support scope, rather than the amount of implementation work. Clowder AI already supports arbitrary OpenAI-compatible services through a custom API-key account with The current proposal also repeats provider identity across several hard-coded registries. If we expand built-in provider metadata in the future, we would first want a canonical, data-driven provider registry and an accepted design issue covering the support boundary. OrcaRouter can continue to be used through the generic OpenAI-compatible account path. If that path is missing a provider-neutral capability, a focused issue describing that generic gap—with a reproducible user journey—would still be welcome. Thank you for helping us examine this boundary. We are not taking over or modifying your branch. — 小太阳·砚砚 / GPT-5.6 Sol 🐾 |
PR Type
Related Issue
No issue number — this is a purely additive provider registration. Happy to open an issue / feature doc for an F-number if the maintainers prefer tracked features for provider additions.
Feature Doc (Feature PRs only)
Not requested. This change is a thin, purely additive provider registration that mirrors the already-shipped OpenRouter wiring in the same files (
env-map.ts,invoke-single-cat.ts,account-resolver.ts,HubCatEditor.tsx,hub-cat-editor.sections.tsx). No new capability or behavior change, and no roadmap impact — so no F-number is required. If the maintainers would rather track it, I'm glad to open an issue and implement against the resulting Feature Doc.What
Adds OrcaRouter as a named provider across the API and web surfaces, exactly parallel to the existing OpenRouter entry. OrcaRouter is an OpenAI-compatible model routing gateway (base URL
https://api.orcarouter.ai, API rooted at/v1) exposing a broad model catalog under namespaced IDs (e.g.openai/gpt-5.5,anthropic/claude-sonnet-4.6,z-ai/glm-5.2). It also ships gateway-level security controls for AI agents.packages/api/src/domains/cats/services/agents/providers/env-map.ts—orcarouteradded toBUILTIN_ENV_MAPS, so an opencode cat bound to an OrcaRouter API-key profile getsORCAROUTER_API_KEYinjected into its environment.packages/api/src/domains/cats/services/agents/invocation/invoke-single-cat.ts—orcarouter: 'openai'added toprotocolForProvider(same protocol mapping as OpenRouter).packages/api/src/config/account-resolver.ts—orcarouteradded toKNOWN_CANONICAL_PROVIDERSso account resolution treats it as a first-party provider name.packages/web/src/components/hub-cat-editor.sections.tsx+packages/web/src/components/HubCatEditor.tsx—orcarouteradded to the known OpenAI-compatible provider lists in the Hub account editor.env-map.test.js(provider-name resolution),invoke-single-cat.test.js(env-var injection for opencode members bound toorcarouterAPI-key profiles),opencode-config-template.test.js(protocol mapping),hub-cat-editor-oc-providers.test.ts(known-provider list).README.md/README.ja-JP.md/README.zh-CN.mdandSETUP.md/SETUP.zh-CN.mdlist OrcaRouter in the third-party provider guides alongside OpenRouter.Why
The Hub account editor already treats OpenAI-compatible aggregators as named first-class providers (OpenRouter is wired this way). OrcaRouter is the same shape, and routing it through the generic OpenAI-compatible path would silently skip the dedicated
ORCAROUTER_API_KEYenv surface, the named-provider UI, and the protocol mapping every other named gateway gets. Keeping it named gives users the same one-key setup they already have for OpenRouter:export ORCAROUTER_API_KEY=sk-orca-...then pick a model such as
openai/gpt-5.5oranthropic/claude-opus-4.8from the catalog at https://www.orcarouter.ai/models.Tradeoff
ORCAROUTER_API_KEYenv injection, the provider picker entry, and protocol mapping consistency; (2) a shared generic gateway abstraction — rejected as a larger architectural change than warranted; mirroring the OpenRouter entry is the smallest change that keeps the model picker, docs, and config reference consistent.ORCAROUTER_API_KEYresolution only activates when a user explicitly selects OrcaRouter. Existing user flows are unchanged.Test Evidence
I'm an engineer on the OrcaRouter team.