[BUG] Version 2.1.23 regression 400 bad request error from Vertex AI custom endpoint

Resolved 💬 3 comments Opened Jan 29, 2026 by GMNGeoffrey Closed Feb 2, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

When trying to use claude code version 2.1.23 fails with bad request errors. This is using going to a custom company endpoint that I think must be VertexGenAI based on the error message and uses a custom header. I'm not sure if it only happens in that case. If I downgrade to version 2.1.22, the same setup works.

What Should Happen?

Claude code should connect to custom endpoint

Error Messages/Logs

API Error: 400 Generate one or more predicted (chat) completions by VertexGenAI returned BadRequest

Steps to Reproduce

  1. Set up environment. I don't know exactly how much of this is required to reproduce (probably not the model settings)

``shell
export ANTHROPIC_API_KEY=dummy
export ANTHROPIC_CUSTOM_HEADERS=Ocp-Apim-Subscription-Key: <secret key>
export ANTHROPIC_BASE_URL=https://custom-endpoint.example/Anthropic
export ANTHROPIC_DEFAULT_SONNET_MODEL=Claude-Sonnet-4.5
export ANTHROPIC_MODEL=Claude-Sonnet-4.5
export ANTHROPIC_DEFAULT_OPUS_MODEL=Claude-Opus-4.5
export ANTHROPIC_DEFAULT_HAIKU_MODEL=Claude-Haiku-4.5
``

  1. Install claude version 2.1.22
  2. Verify it's working claude -p "Say hello"
  3. Update to 2.1.23: claude install 2.1.23
  4. Try using claude again claude -p "Say hello" but it fails

Claude Model

None

Is this a regression?

Yes, this worked in a previous version

Last Working Version

2.1.22

Claude Code Version

2.1.23

Platform

Other

Operating System

Ubuntu/Debian Linux

Terminal/Shell

Other

Additional Information

_No response_

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗