Claude Code request fails when advisor_20260301 is included in tools
Environment
- cc-switch-cli:
5.10.5
- Provider: DeepSeek
- Claude route: local proxy on
127.0.0.1:15721
- Claude Code using CC Switch local proxy through
ANTHROPIC_BASE_URL
Problem
After a recent Claude Code update, requests through the CC Switch Claude proxy fail with:
API Error: 400 Failed to deserialize the JSON body into the target type:
tools[32]: unknown variant `advisor_20260301`,
expected `web_search_20250305` or `web_search_20260209`
at line 1 column 143873
The request body itself is valid JSON and is parsed successfully until the tools array is reached.
The new Claude Code version appears to include the Anthropic Advisor server tool:
{
"type": "advisor_20260301"
}
The current Claude proxy or Anthropic compatibility layer appears to deserialize server tool types using an older schema that only recognizes:
web_search_20250305
web_search_20260209
Steps to reproduce
- Configure Claude Code to use the CC Switch local proxy.
- Select DeepSeek as the Claude provider in CC Switch.
- Start a recent Claude Code version.
- Send a simple prompt such as:
- The request fails before model inference with the error above.
Expected behavior
CC Switch should either:
- Support and correctly handle the
advisor_20260301 Anthropic server tool, or
- Strip or disable unsupported Anthropic server tools before forwarding to a provider that does not support them.
Actual behavior
The request is rejected during tool schema deserialization:
unknown variant `advisor_20260301`
Workaround
Disabling experimental Claude Code beta features avoids the issue:
export CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1
This suggests the failure is specifically related to newly introduced Anthropic beta tools rather than the underlying DeepSeek request itself.
Notes
This looks like a compatibility issue introduced by newer Claude Code request schemas. CC Switch currently handles older Anthropic server tool variants, but the new Advisor tool is not accepted by the current conversion or deserialization path.
Claude Code request fails when
advisor_20260301is included in toolsEnvironment
5.10.5127.0.0.1:15721ANTHROPIC_BASE_URLProblem
After a recent Claude Code update, requests through the CC Switch Claude proxy fail with:
The request body itself is valid JSON and is parsed successfully until the
toolsarray is reached.The new Claude Code version appears to include the Anthropic Advisor server tool:
{ "type": "advisor_20260301" }The current Claude proxy or Anthropic compatibility layer appears to deserialize server tool types using an older schema that only recognizes:
Steps to reproduce
Expected behavior
CC Switch should either:
advisor_20260301Anthropic server tool, orActual behavior
The request is rejected during tool schema deserialization:
Workaround
Disabling experimental Claude Code beta features avoids the issue:
export CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1This suggests the failure is specifically related to newly introduced Anthropic beta tools rather than the underlying DeepSeek request itself.
Notes
This looks like a compatibility issue introduced by newer Claude Code request schemas. CC Switch currently handles older Anthropic server tool variants, but the new Advisor tool is not accepted by the current conversion or deserialization path.