session isn't eligible:Claude Code Local Routing
Quick fix
使用非 Anthropic 上游或格式转换时,在 provider 的 env 中设置 CLAUDE_CODE_AUTO_MODE_SERVER=0,以关闭提示并继续使用本地分类器。
Symptom
Section titled “Symptom”We're changing auto mode to no longer charge for classifier requests in Claude Code. However, this session isn't eligible because your requests go through `<gateway>`, which isn't compatible with this update. Nothing breaks: auto mode keeps working, and its classifier requests are billed as before.Claude Code 的服务端免费分类器依赖 Anthropic 格式上游返回 `safeguard_results`。维护者说明,Anthropic-format provider 的 Local Routing 已原样转发 `safeguards` 并返回 `safeguard_results`;但 OpenAI Chat、OpenAI Responses、Gemini 等格式转换,以及任何非 Anthropic 上游,都没有该服务端分类器,因此 Claude Code 会回退到本地、计费的分类器并显示一次提示。
Issue 中有评论称转换链路曾丢失相关字段并提到 #7636,但维护者的最终状态说明仍明确:非 Anthropic 上游会始终回退。该场景不是 Auto Mode 功能失效,而是服务端免费分类器不可用导致的计费与提示变化。
确认 provider 是否使用 Anthropic 格式;若是 Anthropic-format provider,检查是否有位于 CC Switch 与 Anthropic 上游之间、会移除 `safeguards` 或 `safeguard_results` 的中继。
若 provider 使用 OpenAI Chat、OpenAI Responses、Gemini 等格式转换,或上游不是 Anthropic,在该 provider 的 `env` 中设置 `CLAUDE_CODE_AUTO_MODE_SERVER=0`,然后重新启动 Claude Code。
Affected Versions
Section titled “Affected Versions”Source Issues
Section titled “Source Issues”本页汇总自 2 个真实 issue
(暂无 FAQ)
这是一个非官方社区 wiki,与 cc-switch 作者及项目本身无隶属关系。内容整理自项目公开的 GitHub issues。本站不分发任何软件。