claude-code icon indicating copy to clipboard operation
claude-code copied to clipboard

[BUG] Regression - Azure Foundry auth failing since 2.0.70

Open JC-wk opened this issue 4 weeks ago • 3 comments

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?

The latest version of claude code fails to authenticate with Azure foundry it works in 2.0.62

What Should Happen?

claude should work

Error Messages/Logs

Invalid API key · Please run /login

Steps to Reproduce

  1. Update to latest version 2.0.72
  2. export keys for connecting to foundry
  3. observe errors when trying to connect to claude
  4. revert to 2.0.62
  5. everything works fine

Claude Model

Sonnet (default)

Is this a regression?

Yes, this worked in a previous version

Last Working Version

2.0.62

Claude Code Version

N/A

Platform

Other

Operating System

Ubuntu/Debian Linux

Terminal/Shell

VS Code integrated terminal

Additional Information

No response

JC-wk avatar Dec 17 '25 16:12 JC-wk

What are the names of the environment variables you're setting for Foundry? When you submit a prompt, what error do you get?

ant-kurt avatar Dec 17 '25 19:12 ant-kurt

Hi @ant-kurt I have the following set

# Claude Code + Azure AI Foundry configuration
CLAUDE_CODE_USE_FOUNDRY=1

# Your Foundry resource base URL
ANTHROPIC_FOUNDRY_RESOURCE=<redacted>

# API key from your Foundry deployment
ANTHROPIC_FOUNDRY_API_KEY=<redacted>

# Optional: default models for Claude Code
ANTHROPIC_DEFAULT_HAIKU_MODEL=claude-haiku-4-5
ANTHROPIC_DEFAULT_SONNET_MODEL=claude-sonnet-4-5
ANTHROPIC_DEFAULT_OPUS_MODEL=claude-opus-4-5
ANTHROPIC_MODEL=claude-haiku-4-5

Image

When I downgrade:

Image

JC-wk avatar Dec 18 '25 09:12 JC-wk