Bedrock: [1m] context suffix leaks into model ID causing 400 errors
Resolved 💬 3 comments Opened Apr 17, 2026 by Sukrit3007 Closed Apr 20, 2026
Bug
When using Claude Code with AWS Bedrock, the [1m] context-window suffix is included in the actual API request model ID, causing 400 errors.
Expected model ID sent to Bedrock: global.anthropic.claude-opus-4-7
Actual model ID sent: global.anthropic.claude-opus-4-7[1m]
Reproduction
- Configure Claude Code with
"model": "global.anthropic.claude-opus-4-7"in settings.json (or select via/model) - Claude Code appends
[1m]to the model ID - Bedrock returns:
400 The provided model identifier is invalid
Verification
Direct Bedrock invocation with global.anthropic.claude-opus-4-7 succeeds. The [1m] suffix is an internal Claude Code tag for the 1M context variant and should be stripped before sending to the API.
Environment
- Claude Code v2.1.112
- AWS Bedrock (us-east-1)
- macOS
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗