Claude Official check failed: could not extract base_url - Codex
Quick fix
CC Switch proxying and load balancing do not support an official Claude subscription — use a third-party API key. Forcing it errors and risks a ban.
Symptom
Section titled “Symptom”Claude Official 检查出错: 提取 base_url 失败: 配置错误: Claude Provider 缺少 base_url 配置Claude Official check failed: could not extract base_url: config error: Claude Provider is missing base_url configuration
This issue cluster actually mixes several independent variants around CC Switch proxying and routing: 1. **Official subscriptions do not support proxying (the main problem)**: CC Switch proxying and load balancing do not support an official Claude subscription. Trying to proxy it trips a 500 circuit-break on the missing `base_url`, and it is forbidden officially with a ban risk (#643). 2. **Session records "lost"**: in 3.17.0, the Codex sidebar filters strictly by `model_provider`, so switching routing mode hides the other set of sessions in the UI while the local JSONL files are intact (#5323). 3. **WebDAV sync overwriting the port**: cross-device sync overwrites the new device's actual local proxy port (15721) with the old device's (18100), pointing Codex routing at a dead port (#2788). 4. **Login state overwritten**: interference from a local network proxy (VPN) can let the official login state overwrite a third-party key; turning the VPN off and restarting resolves it temporarily (#5995).
Stop enabling proxying or load balancing for Claude Official (the official subscription) in CC Switch, and use a third-party API key provider instead to avoid an account ban.
If WebDAV sync pointed Codex routing at a dead port, change `base_url` in the routing provider config by hand to the port actually being listened on.
Codex 路由 provider 配置 [model_providers.code-switch]base_url = 'http://127.0.0.1:18100'base_url = 'http://127.0.0.1:15721'
Affected Versions
Section titled “Affected Versions”Source Issues
Section titled “Source Issues”This page is distilled from 4 real issues
- Do proxying and load balancing really not support Claude Official?
- Correct — CC Switch does not support proxying an official subscription account. Forcing it errors and circuit-breaks on the missing base_url, and carries a ban risk.
- Why did my Codex sidebar session records disappear after switching routing mode?
- That is the 3.17.0 mechanism: the Codex sidebar filters strictly by the current model_provider. The session JSONL files are not lost — switch back to the original mode and they show again.
- WebDAV sync left Codex routing pointing at a dead port. What now?
- The sync may have overwritten the local proxy port. Check which port CC Switch actually started on and change base_url in the Codex routing config to it by hand.
- I configured a relay API — why does the Codex interface still show the official account?
- Interference from a local network proxy (VPN) may have let the official login state overwrite the third-party key. Turn the VPN off and start Codex again.
Related problems
Section titled “Related problems”This is an unofficial community wiki with no affiliation to the cc-switch authors or the project itself. Its content is compiled from the project's public GitHub issues. This site distributes no software.