Skip to content
BENIBIX Learn

CLAUDE_CODE_USE_BEDROCK

AI⌨️ Claude CodeConfiguration

Also known as CLAUDE_CODE_USE_VERTEX, CLAUDE_CODE_USE_FOUNDRY, CLAUDE_CODE_USE_MANTLE, CLAUDE_CODE_USE_ANTHROPIC_AWS, CLAUDE_CODE_USE_ANTHROPIC_GOOGLE_CLOUD, CLAUDE_CODE_USE_* variables

Set to 1, it runs Claude Code on Amazon Bedrock.

Think of it like

It is like you choose which shop to buy the same toy from.

Example

Jack's firm buys all its AI from AWS. He sets this to 1, and each request goes through the firm's Bedrock account.

Why it matters

A firm can use Claude Code under the cloud deal and bills it has now.

Definition

CLAUDE_CODE_USE_BEDROCK set to 1 sends Claude Code's requests to Amazon Bedrock. Each other cloud has its own: _VERTEX for Google, _FOUNDRY for Microsoft Foundry and _MANTLE for Mantle on Bedrock. That cloud then signs you in with its own keys. It also bills its own account. A cloud set this way is first in the sign-in order.

Example code

bash
export CLAUDE_CODE_USE_BEDROCK=1
export AWS_REGION=us-east-1
claude
Run Claude Code on your Bedrock account.
Each USE variable opens one road.

Common mistake

Setting two of them at once. Pick one cloud per session, so you know which one you are on.

Key takeaways

  1. 1
    One per cloud. Bedrock, Google, Foundry.
  2. 2
    Set to 1. To turn it on.
  3. 3
    First in line. Beats API keys.