Recent versions of Claude Code attach some experimental parameters to requests (beta headers, cache scope, context management, and so on). Some channels, such as AWS Bedrock, don't accept these parameters yet and return HTTP 400. In most cases a single environment variable fixes it.Quick fix#
Add CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS to env in ~/.claude/settings.json, then restart Claude Code:{
"env": {
"ANTHROPIC_BASE_URL": "https://studio.dataeyes.ai",
"ANTHROPIC_AUTH_TOKEN": "sk-xxx",
"CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS": "1"
}
}
If you use environment variables:This variable only turns off experimental features that not every channel supports yet. It doesn't affect normal conversations, tool use, or prompt caching.
Common errors#
| Error message (keywords) | Cause | Fix |
|---|
Unexpected value(s) ... for the anthropic-beta header | The channel doesn't recognize a new beta header | Set CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS=1 |
context_management: Extra inputs are not permitted | The channel doesn't support context management parameters | Same as above |
cache_control.scope: Extra inputs are not permitted | The channel doesn't support the cache scope parameter; common when resuming with --resume | Same as above |
output_config.effort: Extra inputs are not permitted | The model or channel doesn't support the reasoning effort parameter | Same as above; if it persists, switch to a model that supports it, such as claude-sonnet-5-5 |
system content must contain at least one block | The model or reasoning effort was changed mid-session | Run /clear to start a new session and retry; avoid switching repeatedly within one session |
The provided model identifier is invalid / model not found | The default model isn't available in the current group | Set ANTHROPIC_DEFAULT_OPUS_MODEL and related variables to platform model names; see step 3 of Claude Code |
no low surrogate in string / Invalid JSON | The session contains malformed Unicode characters | Start a new session; don't use --resume to restore the failing session |
x-anthropic-billing-header is a reserved keyword | Known issue in older Claude Code versions | Upgrade Claude Code to the latest version |
Still not resolved#
1.
Upgrade Claude Code: run claude update for the native install, or npm install -g @anthropic-ai/claude-code@latest for the npm install.
2.
Find the failed request in Usage Logs or Call Diagnostics in the console, and note its request ID (request id). 3.
Send the full error message, your Claude Code version (claude --version), and the request ID to support.
We don't recommend setting DISABLE_PROMPT_CACHING=1 as a workaround. Turning off prompt caching significantly increases token usage.