Anthropic SDK and Claude Code
Point Claude Code, or the Anthropic SDK, at the router without changing a line of your code.
shell
# Point Claude Code at the router, then run it as usual.export ANTHROPIC_BASE_URL="https://api.blastrouter.com"export ANTHROPIC_AUTH_TOKEN="rl-…" # your router key claudepython
# The Anthropic SDK, pointed at the router: base_url and api_key, nothing else.import anthropic client = anthropic.Anthropic(base_url="https://api.blastrouter.com", api_key="rl-…")msg = client.messages.create( model="claude-sonnet-5", max_tokens=256, messages=[{"role": "user", "content": "hi"}],)print(msg.content[0].text)POST /v1/messages streams when you ask it to; anthropic-version and anthropic-beta pass through untouched. Failover across upstream accounts is automatic.