Connect Claude Code to Amazon Bedrock or Google Cloud Vertex AI
If your organisation uses AWS or Google Cloud, you can route Claude Code through Amazon Bedrock or Google Cloud Vertex AI instead of calling the Anthropic API directly. Traffic stays within your existing cloud security perimeter and billing — no separate Anthropic API key needed.
Amazon Bedrock
# Add to your shell profile or CI environment
export CLAUDE_CODE_USE_BEDROCK=1
export AWS_REGION=us-east-1
# Authenticate using your existing AWS credentials
aws sso login
# or: aws configure
# Launch Claude Code — it routes through Bedrock automatically
claude
Google Cloud Vertex AI
export CLAUDE_CODE_USE_VERTEX=1
export CLOUD_ML_REGION=us-east5
export ANTHROPIC_VERTEX_PROJECT_ID=your-gcp-project-id
# Authenticate using Application Default Credentials
gcloud auth application-default login
claude
Claude Code picks up your cloud credentials automatically when these variables are set. You do not need to set ANTHROPIC_API_KEY.
This setup is particularly valuable for teams that:
- Need AI traffic within a specific cloud account for compliance or data residency
- Want AI costs consolidated under existing cloud billing and reserved capacity
- Are subject to security policies that prohibit direct third-party API access from CI systems
Model availability varies by region and provider — check the Claude on Amazon Bedrock and Claude on Vertex AI docs for the current list.
Your existing cloud credentials unlock Claude Code — keep everything within your security boundary without a separate API key.
Log in to leave a comment.
When Claude writes error messages, button labels, validation text, or onboarding flows, it defaults to generic developer-speak. Add a "Users" section to your CLAUDE.md describing who your actual users are — their technical level, industry jargon, and what they care about — so Claude writes copy that makes sense to THEM, not to developers.
Use the --agent flag with custom markdown files in .claude/agents/ to launch purpose-built Claude sessions with restricted tools and scoped system prompts.
Every project has traps — the billing module that silently fails if you forget to queue the job, the legacy table with column names that don't match the model, the config value that must be set before tests run. Document these gotchas in your CLAUDE.md so Claude avoids the same mistakes your team spent days debugging.