<aside>
:ambient-logo-original: Docs Home
🌐 Homepage
:discord-symbol-blurple: Discord
:github-mark-white-bg: github.com/ambient-xyz
:x-logo-black: @ambient_xyz
:x-logo-black: @IridiumEagle
</aside>
This guide shows how to configure Claude Code to use Ambient's inference API.
npm install -g @anthropic-ai/claude-code)Set the following environment variables:
export ANTHROPIC_BASE_URL=https://api.ambient.xyz
export ANTHROPIC_API_KEY=your-ambient-api-key
Or add them to your shell profile (~/.bashrc, ~/.zshrc, etc.).
Once configured, run Claude Code as normal:
claude
Claude Code will automatically route requests through Ambient's inference API.
You can verify your setup by running:
echo $ANTHROPIC_BASE_URL # Should show: <https://api.ambient.xyz>
echo $ANTHROPIC_API_KEY # Should show your Ambient API key