thinking options type cannot be disabled Claude Code
Quick fix
升级 cc-switch 至 v3.16.4 或更高版本,代理会自动剥离与 DeepSeek 冲突的 reasoning_effort 参数。
Symptom
Section titled “Symptom”API Error: 400 thinking options type cannot be disabled when reasoning_effort is set在 Claude Code 中运行 Dynamic Workflows 或子代理时,系统会强制设置 `thinking: { type: "disabled" }`。当 cc-switch 将请求转发至 DeepSeek 端点时,若同时携带了 `reasoning_effort` 或 `output_config.effort` 参数,DeepSeek API 会因这两个参数互斥而拒绝请求并返回 400 错误。由于用户通常将所有模型映射到 DeepSeek,单纯切换模型无法绕过此问题。
将 cc-switch 升级到 v3.16.4 或更高版本。
确保 DeepSeek 的请求通过 cc-switch 的本地路由转发,新版本会在转发层自动清洗冲突参数。
Affected Versions
Section titled “Affected Versions”ToolClaude Code
Versioncc-switch < 3.16.4 (已在 v3.16.4 修复)
PlatformsmacOS
Source Issues
Section titled “Source Issues”本页汇总自 2 个真实 issue
- 切换模型或降低 effort 级别能解决这个报错吗?
- 不能。因为 cc-switch 将所有模型映射到了同一个 DeepSeek 后端,且 Claude Code 工作流强制禁用 thinking,只要请求中仍携带 reasoning_effort 参数就会触发冲突。必须升级 cc-switch 以启用参数自动清洗。
- 除了 DeepSeek,其他模型也会遇到这个问题吗?
- 直接使用 Anthropic 官方 API 配合 Opus 模型也有类似问题,但切换到 Sonnet 可绕过。而使用 cc-switch 全映射到 DeepSeek 时,所有请求都会触发此冲突。
api failed deserialize json body into按错误类型回退 Claude Code、升级 cc-switch、关闭本地代理或停止发送不支持的字段。API Error: 400 Param Incorrect Claude Code升级 CC Switch 到 v3.16.2 或更新版本,修复 MiMo thinking mode 下 reasoning_content 未回传导致的 400 错误。Request body format invalid 报错 Claude Code升级 cc-switch 并开启 Rectifier 整流器,或添加环境变量 MAX_THINKING_TOKENS=0 以兼容第三方 API 格式。
这是一个非官方社区 wiki,与 cc-switch 作者及项目本身无隶属关系。内容整理自项目公开的 GitHub issues。本站不分发任何软件。