-
Notifications
You must be signed in to change notification settings - Fork 6.9k
Description
Preflight Checklist
- I have searched existing issues and this hasn't been reported yet
- This is a single bug report (please file separate reports for different bugs)
- I am using the latest version of Claude Code
What's Wrong?
When using Claude Code CLI against AWS Bedrock, selecting the 1M context variant of Claude Opus 4.6 ([1m]) causes requests to fail with:
400 The provided model identifier is invalid.
This looks like a model-ID handling bug specific to the [1m] suffix on Bedrock. After selecting the [1m] option via /model, the CLI appears to persist a non–Bedrock-qualified identifier in settings.json, e.g.:
- Observed in
settings.json:claude-opus-4-6-v1[1m] - Expected for Bedrock:
us.anthropic.claude-opus-4-6-v1[1m]
As a result, Bedrock rejects the request even though the 1M context variant should be reachable when the correct model ID (and any required headers) are used.
What Should Happen?
Claude Code CLI should preserve the fully-qualified Bedrock model ID and successfully execute requests when the [1m] variant is selected, i.e. use:
us.anthropic.claude-opus-4-6-v1[1m]
The call should succeed, and the 1M context option should be active / reported correctly.
Error Messages/Logs
API Error (claude-opus-4-6[1m]): 400 The provided model identifier is invalid.Steps to Reproduce
- Ensure AWS credentials are configured and the us-east-1 region is selected.
- Configure/run Claude Code using the model ID with the
[1m]suffix, for example:export ANTHROPIC_MODEL="claude-opus-4-6[1m]"- Or in Claude Code CLI, set the model via
/modeland select the option that uses the[1m]suffix.
- Run any command that initiates an API call (e.g., ask a question).
Claude Model
Opus
Is this a regression?
Yes, this worked in a previous version
Last Working Version
No response
Claude Code Version
2.1.32 (Claude Code)
Platform
AWS Bedrock
Operating System
macOS
Terminal/Shell
iTerm2
Additional Information
No response