HarnessRouter Community Edition: the self-hosted, Apache-2.0 edition of the unified interface for agent harnesses. Run Codex, Claude Code, Hermes, PI, DSH, and more through one API, with sessions, streaming, files, cancellation, and failure handling. Implements the Unified Harness Protocol (UHP), an open standard. Your keys, your infrastructure.
Python agent-apiagent-frameworkagent-harnessai-agentsai-infrastructurecoding-agentconformance-testingdeepseek-harnessharness-engineeringhermesllmopen-protocolopen-sourceopen-standardpi-coding-agentself-hosteduhpunified-apiunified-harness-protocolunified-interface
fix(custom): the API-format default the form shows is the format that gets stored
richard-epsilladcf2644e408e
diff --git a/gateway/app.py b/gateway/app.pyindex 37da5090..be15c278 100644--- a/gateway/app.py+++ b/gateway/app.py@@ -3736,6 +3736,13 @@ async def admin_integrations_put(body: IntegrationsBody, request: Request) -> diknown_base = (_PROVIDER_CATALOG.get(provider) or {}).get("base_url")if known_base and not cfg.get("base_url"):cfg["base_url"] = known_base+ # The custom form's API-format select shows "OpenAI Chat Completions" preselected, so a+ # payload that never touched it means the user accepted that default — but a select's+ # visible default is not form STATE, and a custom integration stored without api_format+ # served no backend at all, silently: every picker row said "no provider" while the+ # mapping table happily routed to it (measured live, 2026-08-27). Store what the user saw.+ if provider == "custom" and not cfg.get("api_format"):+ cfg["api_format"] = "openai"# Custom provider URL normalisation. The user's base_url is the literal prefix their# endpoint wants the resource path joined against — for "openai" that's /chat/completions# and for "anthropic" /v1/messages, with NOTHING inserted in between (a custom endpointdiff --git a/ui/src/app/(app)/integrations/page.tsx b/ui/src/app/(app)/integrations/page.tsxindex 5db64dbf..f2e07ad8 100644--- a/ui/src/app/(app)/integrations/page.tsx+++ b/ui/src/app/(app)/integrations/page.tsx@@ -252,7 +252,7 @@ export default function IntegrationsPage() {<button key={c.id} type="button"className={'itg-provider' + (editing.provider === c.id ? ' on' : '')}disabled={Boolean(editingOriginal)}- onClick={() => setEditing({ ...editing, provider: c.id, config: {} })}>+ onClick={() => setEditing({ ...editing, provider: c.id, config: c.id === 'custom' ? { api_format: 'openai' } : {} })}>{c.label}</button>))}@@ -290,7 +290,7 @@ export default function IntegrationsPage() {{editing.config['api_format'] === 'anthropic'? 'Anthropic Messages format works with Claude Code, OpenCode, Pi, and DSH backends.': editing.config['api_format'] === 'openai'- ? 'OpenAI Chat Completions format works with Codex, Hermes, OpenCode, Pi, and DSH backends. Note: Claude Code does not support OpenAI format.'+ ? 'OpenAI Chat Completions format works with Hermes, OpenCode, Pi, and DSH backends. Codex and Claude Code cannot drive a custom OpenAI endpoint.': 'If you use Claude Code, choose Anthropic Messages format.'}</p></div>