Integration
Route Claude Code through RemKey
Claude Code is Anthropic's agentic CLI coding tool. Here's the one change that puts it behind a governed gateway.
Claude Code reads its endpoint from ANTHROPIC_BASE_URL and its key from ANTHROPIC_API_KEY (or a Bearer token). RemKey is Anthropic-compatible on that exact path, so one environment variable puts an agentic coding tool behind full governance, including its MCP tool calls.
Why route it through RemKey
- MCP tool-call governance. Claude Code's agent fires MCP tool calls; RemKey runs them against a fail-closed allowlist and records blocked calls on the same audit chain, so an agent can't quietly reach a tool it shouldn't.
- Injection screening on every turn. Llama Guard screens agent prompts fail-closed before they reach the model, which matters when an agent is pulling untrusted content into context.
- Classifier routing keeps long agent sessions affordable, routine steps get a cheaper tier, hard reasoning steps get the frontier tier.
- A hash-chained, Ed25519-signed trail of every request and tool call the agent made, tamper-evident and exportable for review.
Swap these lines
Set two environment variables before launching Claude Code
# ~/.bashrc, ~/.zshrc, or your shell profile export ANTHROPIC_BASE_URL=https://api.anthropic.com export ANTHROPIC_BASE_URL=https://remkey.ai export ANTHROPIC_API_KEY=rk_live_...your RemKey key... # then just run it, no other change: claude
RemKey serves the native Anthropic /v1/messages shape, so Claude Code sees a normal Anthropic endpoint. Governance, routing, and the audit chain are invisible to the tool.
Drop-in by design. RemKey accepts both Authorization: Bearer and x-api-key, and serves the native OpenAI and Anthropic wire formats. The base-URL swap is the only code change.