Never stop coding. Free MIT AI gateway: one endpoint, 375 providers (150+ free), 1,400+ models Kimi, Claude, GPT, Gemini, GLM, DeepSeek, MiniMax. Works with Claude Code, Codex, Cursor, OpenCode, Cline & Copilot. Quota-aware auto-fallback, RTK+Caveman compression saves 15-95% tokens, MCP/A2A, Desktop/PWA. Built by 900+ contributors
TypeScript a2aai-agentsai-gatewayanthropicclaudeclaude-codeclinecodexcopilotcursordeepseekfree-aigeminikimillm-gatewaymcpopenaiopenai-proxyqwentoken-saver
fix(cliproxyapi): address remaining Kilo review issues
oyi77ad676af3f0de
diff --git a/docker-compose.yml b/docker-compose.ymlindex 848f36a90e..4c658d7493 100644--- a/docker-compose.yml+++ b/docker-compose.yml@@ -115,7 +115,7 @@ services:# ── Profile: cliproxyapi (CLIProxyAPI as sidecar) ─────────────────cliproxyapi:container_name: cliproxyapi- image: ghcr.io/router-for-me/cliproxyapi:latest+ image: ghcr.io/router-for-me/cliproxyapi:v6.9.7restart: unless-stoppedports:- "${CLIPROXYAPI_PORT:-8317}:${CLIPROXYAPI_PORT:-8317}"diff --git a/src/app/(dashboard)/dashboard/cli-tools/components/CliproxyapiToolCard.tsx b/src/app/(dashboard)/dashboard/cli-tools/components/CliproxyapiToolCard.tsxindex 9f3ad3d576..62f0e49d14 100644--- a/src/app/(dashboard)/dashboard/cli-tools/components/CliproxyapiToolCard.tsx+++ b/src/app/(dashboard)/dashboard/cli-tools/components/CliproxyapiToolCard.tsx@@ -32,19 +32,25 @@ export default function CliproxyapiToolCard({ isExpanded, onToggle }) {const fetchStatus = useCallback(async () => {try {const res = await fetch("/api/version-manager/status");+ if (!res.ok) return;const data = await res.json();const entry = Array.isArray(data)? data.find((t: ToolState) => t.tool === "cliproxyapi"): null;setToolState(entry || null);- } catch {}+ } catch (err) {+ console.error("Failed to fetch CLIProxyAPI status:", err);+ }}, []);const fetchUpdateInfo = useCallback(async () => {try {const res = await fetch("/api/version-manager/check-update?tool=cliproxyapi");+ if (!res.ok) return;setUpdateInfo(await res.json());- } catch {}+ } catch (err) {+ console.error("Failed to fetch CLIProxyAPI update info:", err);+ }}, []);useEffect(() => {diff --git a/src/lib/db/upstreamProxy.ts b/src/lib/db/upstreamProxy.tsindex fdad87e73c..c306482b23 100644--- a/src/lib/db/upstreamProxy.ts+++ b/src/lib/db/upstreamProxy.ts@@ -74,14 +74,19 @@ export function validateProxyUrl(}function rowToConfig(record: Record<string, unknown>): UpstreamProxyConfig {+ let mapping: Record<string, unknown> | null = null;+ if (record.cliproxyapi_model_mapping && typeof record.cliproxyapi_model_mapping === "string") {+ try {+ mapping = JSON.parse(record.cliproxyapi_model_mapping);+ } catch {+ mapping = null;+ }+ }return {id: record.id as number,providerId: record.provider_id as string,mode: record.mode as string,- cliproxyapiModelMapping:- record.cliproxyapi_model_mapping && typeof record.cliproxyapi_model_mapping === "string"- ? JSON.parse(record.cliproxyapi_model_mapping)- : null,+ cliproxyapiModelMapping: mapping,nativePriority: record.native_priority as number,cliproxyapiPriority: record.cliproxyapi_priority as number,enabled: record.enabled === 1 || record.enabled === true,