9 Best Claude Code Gateways for Enterprises
A Claude Code gateway sits between Claude Code and model providers to centralize credentials, budgets, and audit logs. This guide compares 9 Claude Code gateway options, including Bifrost, Anthropic's Claude apps gateway, LiteLLM, Kong AI Gateway, and OpenRouter, for enterprise rollouts.
TL;DR
- A Claude Code gateway is any endpoint that speaks a Claude Code-compatible API format and is set as
ANTHROPIC_BASE_URL, so every model request passes through it. - Gateways give enterprises per-developer credentials, budgets and rate limits, audit logs, and provider switching across the Claude API, Amazon Bedrock, and Google Vertex AI.
- Bifrost offers four Claude Code authentication paths, including Enterprise SSO through Bifrost CLI, and applies the same budgets, logs, and MCP tool governance to every one.
- Anthropic's Claude apps gateway, LiteLLM, Kong AI Gateway, WSO2, and Claude Code Router are self-hosted options; Cloudflare, OpenRouter, and Vercel run as managed services.
- Anthropic does not support routing Claude Code to non-Claude models through any gateway, so treat cross-provider model access as an experiment rather than a production plan.
Claude Code adoption usually starts with individual API keys and ends with platform teams asking who spent what, which models are allowed, and where prompts containing source code are logged. A Claude Code gateway answers those questions in one place. Bifrost, the open-source AI gateway for coding agents built by Maxim AI, is the best choice for enterprises running mission-critical AI workloads that require top-tier performance, scalability, and reliability, and it governs Claude Code alongside every other AI client. This guide compares 9 Claude Code gateway options on identity, cost control, routing, MCP support, and deployment.
What Is a Claude Code Gateway?
A Claude Code gateway is an LLM gateway that Claude Code reaches through the ANTHROPIC_BASE_URL setting, which forwards every model request with a gateway credential instead of a developer's own Anthropic key. Anthropic's LLM gateway documentation states that any gateway exposing a supported API format works, and the gateway compatibility guide lists the endpoints and headers a gateway must forward.

The gateway becomes the single place that holds provider credentials, attributes usage to each developer, enforces budgets, and logs requests. The Claude Code gateway explainer covers routing, governance, and cost control in more depth.
Why Enterprises Put Claude Code Behind a Gateway
Claude Code enterprise rollouts put a gateway in front of the tool to control cost, enforce model policy, and keep an audit trail of agentic coding activity. A single long-running session can call the model many times, so per-developer limits and visibility matter more than they do for chat tools.
The main drivers:
- Credential hygiene: developers hold short-lived or revocable gateway credentials, and offboarding revokes one credential instead of rotating a shared provider key.
- Cost control: budgets and rate limits per developer or team, with usage attributed regardless of which provider served the request; the LLM cost calculator helps size those budgets. The guide to governing token usage per team shows common budget designs.
- Provider choice: switch between the Claude API, Amazon Bedrock, and Google Vertex AI in gateway configuration without touching developer machines.
- Audit: a record of every model request for security review and compliance.
- Central rollout: Claude Code's managed settings can set
allowedProvidersto["customEndpoint"]and pin the gateway's base URL, so sessions cannot point anywhere else (Claude Code v2.1.285 or later, per Anthropic's settings documentation).
The Claude Code resource page collects these patterns with configuration examples for Bifrost.
How to Evaluate a Claude Code Gateway
Evaluate a Claude Code gateway on authentication options, policy controls, protocol fidelity, provider routing, and where it runs. Protocol fidelity is easy to overlook: Claude Code adds capabilities with each release, and a gateway that drops headers or beta fields breaks the matching features. The CLI agents resource page covers the same checks for other coding agents.
| Criterion | What to check | Why it matters |
|---|---|---|
| Authentication | SSO, per-user keys, apiKeyHelper support, subscription pass-through |
Attribution and offboarding |
| Cost controls | Budgets and rate limits per user, team, and model | Agentic sessions consume tokens quickly |
| Protocol fidelity | Anthropic Messages endpoint, header and beta forwarding | Missing fields break Claude Code features |
| Providers | Claude API, Bedrock, Vertex AI, failover between them | Capacity and data residency |
| MCP | Central MCP server access with per-user scoping | Coding agents call tools constantly |
| Observability | Per-request logs, usage by developer, export to existing tools | Security review and chargeback |
| Deployment | Self-hosted, in-VPC, managed | Source code in prompts may not leave the network |
Claude Code Gateways Compared at a Glance
The nine options below include one gateway built for all enterprise AI traffic, Anthropic's own self-hosted gateway, general-purpose AI gateways with Claude Code guides, and a local router. For a narrower view of open-source choices, see the comparison of open-source Claude Code gateways.
| Gateway | SSO for developers | Budgets and limits | Bedrock and Vertex | MCP governance | Deployment |
|---|---|---|---|---|---|
| Bifrost | Yes, Enterprise SSO via Bifrost CLI | Per key, team, customer, model | Yes | Yes | Self-hosted, in-VPC, air-gapped |
| Claude apps gateway | Yes, OIDC | Daily, weekly, monthly spend caps | Yes | Not described | Self-hosted container |
| LiteLLM | Yes, gateway SSO | Per key and user | Yes | Yes | Self-hosted |
| Kong AI Gateway | Via Kong auth plugins | Not described in Claude Code guides | Yes | Yes, MCP plugins | Konnect, hybrid, self-hosted |
| WSO2 API Manager AI Gateway | Via API Manager | Via API policies | Not described for Claude Code | Not described | Self-hosted, cloud |
| Claude Code Router | No | Request and token limits per client key | Not described | Not described | Local |
| Cloudflare AI Gateway | Via Cloudflare Access | Rate limiting | Yes | Not described | Managed |
| OpenRouter | No | Account-level | Routes to providers it hosts | Not described | Managed |
| Vercel AI Gateway | No | Not described | Yes | Not described | Managed |
1. Bifrost: Enterprise Claude Code Gateway
The Bifrost AI gateway serves Claude Code through an Anthropic-compatible /anthropic endpoint and applies the same virtual keys, budgets, rate limits, logging, and MCP tool access it uses for every other AI client. Platform teams configure policy once and then let developers choose the authentication path that fits their environment.
Best for: Bifrost is built for enterprises running mission-critical AI workloads that require top-tier performance, scalability, and reliability. It serves as a centralized AI gateway to route, govern, and secure all AI traffic across models and environments with ultra low latency. Bifrost unifies LLM gateway, MCP gateway, and Agents gateway capabilities into a single platform. Designed for regulated industries and strict enterprise requirements, it supports air-gapped deployments, VPC isolation, and on-prem infrastructure. It provides full control over data, access, and execution, along with strong security, policy enforcement, and governance capabilities.

The Claude Code integration guide documents four setups, shown in Figure 2:
- Bifrost CLI launch:
bifrost claudestarts Claude Code with the gateway URL, credential, and model set for that session, without modifying~/.claude/settings.json. With Enterprise SSO, the token is fetched by anapiKeyHelperand never written to Claude settings. - Static virtual key: set
ANTHROPIC_BASE_URLand ask-bf-*virtual key inANTHROPIC_AUTH_TOKEN, suited to open-source deployments, CI, and personal use. - Claude subscription: keep billing on a Claude Pro, Max, Team, or Enterprise plan by sending the virtual key in
ANTHROPIC_CUSTOM_HEADERS; Bifrost forwards the subscription token to Anthropic and uses the virtual key for governance and logging. - Dynamic credentials: use an
apiKeyHelperscript for rotating or vault-issued credentials, with Bifrost CLI SSO recommended for enterprise rollouts.
The original walkthrough of integrating Claude Code with Bifrost shows the static-key setup end to end:
{
"env": {
"ANTHROPIC_BASE_URL": "https://bifrost.example.com/anthropic",
"ANTHROPIC_AUTH_TOKEN": "sk-bf-your-virtual-key"
}
}
Beyond authentication, Bifrost adds budgets and rate limits per key, team, customer, or model, and session affinity that keeps a Claude Code session on the same provider and key so provider prompt caches stay warm.
MCP servers configured in Bifrost become available to Claude Code through the MCP gateway, as shown in the guide to connecting Claude Code to multiple MCP servers. Bifrost adds about 11 microseconds of overhead per request at 5,000 RPS, so the gateway is not the bottleneck in long coding sessions.
For laptops, AI Gateway + Bifrost Edge extends the same policy to developer machines: the gateway remains the policy engine, and Bifrost Edge routes Claude Code and other desktop AI traffic through it with single sign-on, so no keys sit in local configuration files.
Self-Hosted Claude Code Gateways
Self-hosted Claude Code gateways run inside your network, which matters when prompts contain proprietary source code. They range from Anthropic's purpose-built gateway to general AI gateways and a local router; the trade-off is the operational work of keeping them current as Claude Code evolves.
2. Claude Apps Gateway (Anthropic)
Anthropic's Claude apps gateway, announced in July 2026, is a self-hosted gateway for Claude Code and Claude Desktop. It runs as a single stateless container backed by PostgreSQL, and AWS published deployment guidance for ECS, EKS, or EC2.
- Identity: OpenID Connect sign-in with providers such as Okta, Microsoft Entra ID, and Google Workspace, using short-lived sessions.
- Policy and cost: admin-defined managed settings such as allowed models, and daily, weekly, and monthly spend caps at the organization, group, or user level.
- Routing and telemetry: holds the upstream credential, routes to the Claude API, Amazon Bedrock, or Google Cloud with optional failover, and sends telemetry to an organization-controlled OpenTelemetry collector.
- Scope: covers Claude apps, so organizations using other coding agents or model families still need a broader gateway for that traffic.
3. LiteLLM
LiteLLM is a Python proxy that exposes an Anthropic-compatible /v1/messages endpoint for Claude Code. Teams point ANTHROPIC_BASE_URL at the proxy and issue each developer a virtual key, or send the key in a custom header to keep a Claude subscription's billing.
- Controls: virtual keys with budgets, usage logs in a dashboard backed by PostgreSQL, and MCP servers exposed through the proxy.
- Models: LiteLLM documents a non-Anthropic model path through
/v1/modelsdiscovery in Claude Code's model picker. - Consideration: teams evaluating performance and operations should compare it with Bifrost as a LiteLLM alternative.
4. Kong AI Gateway
Kong AI Gateway supports Claude Code through its AI Proxy plugin with the request format set to Anthropic, and Kong publishes how-to guides for routing Claude Code to Anthropic, AWS Bedrock, Vertex AI, Azure, OpenAI, Gemini, and other providers.
- Strength: reuses Kong's plugin ecosystem for authentication, rate limiting, and logging.
- Consideration: some guides require Kong Gateway Enterprise, and the Bedrock guide strips Claude Code beta fields that Bedrock rejects.
5. WSO2 API Manager AI Gateway
WSO2 API Manager can proxy Anthropic API calls from Claude Code through its AI Gateway, with guardrails that redact PII from prompts before they reach Anthropic. The cloud WSO2 API Platform documents a similar setup through an application LLM proxy authenticated with an API key header.
- Fit: organizations already running WSO2 for API management that want Claude Code traffic in the same catalog.
6. Claude Code Router
Claude Code Router (CCR) is an MIT-licensed local gateway that gives Claude Code, Codex, and other coding agents one local endpoint and forwards requests to providers such as OpenAI, Anthropic, Gemini, OpenRouter, DeepSeek, and Mistral. It supports routing conditions on headers and bodies, retries, ordered fallback models, separate client keys with request and token limits, and request logs with estimated cost.
- Fit: individual developers experimenting with model choice. The project page does not list SSO or budget controls, so it is not a team governance layer. The article on Claude Code Router versus an AI gateway compares the two roles.
Managed Claude Code Gateways
Managed Claude Code gateways remove the operational work of running a proxy, at the cost of sending prompts through a third-party network. They suit teams without data residency constraints that want visibility quickly.
7. Cloudflare AI Gateway
Cloudflare AI Gateway exposes an Anthropic endpoint with the /v1/messages API Claude Code expects, authenticated with a gateway token in the cf-aig-authorization header. It also documents Amazon Bedrock and Google Vertex AI endpoints for Claude Code, and protecting the gateway with Cloudflare Access through an apiKeyHelper that fetches a token with cloudflared.
- Controls: observability, caching, rate limiting, and centrally stored provider keys or unified billing.
8. OpenRouter
OpenRouter exposes an Anthropic-compatible endpoint at https://openrouter.ai/api, so Claude Code connects with three environment variables and no local proxy. OpenRouter states that Claude Code is only guaranteed to work with the Anthropic first-party provider, and that non-Anthropic models are not supported through the native endpoint.
- Fit: individuals and small teams that want consolidated billing and an activity dashboard. Teams comparing it with self-hosted options can review the Bifrost LLM gateway for governance features OpenRouter does not target.
9. Vercel AI Gateway
Vercel AI Gateway provides Anthropic Messages API endpoints and a one-command setup, vercel ai-gateway setup --agent claude-code, that writes Claude Code's settings and enables gateway model discovery in the model picker. It also supports Claude Code Max subscriptions by sending the gateway key in a custom header.
- Consideration: Vercel notes that routing through Bedrock or Vertex AI requires disabling Claude Code's experimental betas.
Claude Code Proxy vs Router vs Gateway
The terms Claude Code proxy, Claude Code router, and Claude Code gateway are often used interchangeably, but they describe different scopes. A proxy forwards requests, a router chooses a model or provider per request, and a gateway adds identity, policy, budgets, and audit on top of both.

| Term | What it does | Typical owner |
|---|---|---|
| Claude Code proxy | Forwards requests to one upstream, often to add logging | Individual or small team |
| Claude Code router | Picks a model or provider per request, sometimes non-Claude models | Individual developer |
| Claude Code gateway | Identity, budgets, routing, audit, and MCP governance for many users | Platform team |
On running Claude Code with other models: Anthropic's documentation states that it does not support routing Claude Code to non-Claude models through any gateway. Bifrost accepts provider-qualified model names, and its documentation warns that a model that works for chat can still be unsuitable for an agentic coding session. Treat walkthroughs such as using Claude Code with OpenAI models as experiments, and keep production sessions on Claude models served by Anthropic, Bedrock, or Vertex AI, as covered in running Claude Code on Bedrock, Vertex, or your own models.
Rolling Out a Claude Code Gateway Across Teams
A rollout follows the same four steps regardless of product: deploy the gateway with provider credentials, issue each developer a gateway credential, distribute the base URL and credential through managed settings, and verify that each machine actually uses the gateway.
With Bifrost, the steps map to concrete features:
- Deploy: run Bifrost in your VPC or on-premises with Kubernetes or a single binary; the enterprise deployment options cover high availability and air-gapped installs.
- Issue credentials: create virtual keys per developer or team, or connect your identity provider for SSO-based attribution through AI governance controls.
- Distribute: use Bifrost CLI for per-session launches, or managed settings that pin
ANTHROPIC_BASE_URLwithallowedProviders. - Verify: run
/statusin Claude Code to confirm the base URL and credential source, then check the request in Bifrost logs.
The Bifrost CLI 1.0 announcement shows the launcher across Claude Code, Codex CLI, Gemini CLI, and OpenCode, and the guide to Claude Code hooks for gateway policy covers client-side controls that complement the gateway. The overview of Claude Code gateway routing and governance is a good reference to share with developers before rollout.
Frequently Asked Questions
How do I use Claude Code with an LLM gateway?
Set ANTHROPIC_BASE_URL to the gateway's Anthropic-compatible endpoint and provide a gateway credential through ANTHROPIC_AUTH_TOKEN, apiKeyHelper, or a custom header. Put both in managed settings for organization-wide rollout. Run /status inside Claude Code to confirm the base URL and credential source, then check that requests appear in the gateway's logs. The Claude Code setup patterns for Bifrost include ready-to-copy settings files.
Can Claude Code use models other than Claude through a gateway?
Some gateways, including Bifrost and LiteLLM, can route Claude Code requests to other providers' models. Anthropic does not support this configuration, and coding agents depend on tool calls, streaming, and reasoning fields that other models may handle differently. For production, keep Claude Code on Claude models from Anthropic, Amazon Bedrock, or Google Vertex AI.
Does a Claude Code gateway work with a Claude subscription?
Yes, if the gateway forwards the subscription token. Bifrost, LiteLLM, and Vercel document setups where Claude Code keeps its claude.ai login and sends the gateway key in a custom header. Subscription usage limits still apply in that mode. When a gateway credential replaces the login, traffic is billed per token to the owner of the provider credential instead.
What is the difference between a Claude Code proxy and a Claude Code gateway?
A Claude Code proxy forwards requests, usually to add logging or switch the upstream URL. A Claude Code gateway adds per-developer identity, budgets, rate limits, provider failover, audit logs, and often MCP tool governance. Platform teams rolling Claude Code out to many developers need gateway features; individual developers can often use a proxy or local router.
How do I track Claude Code usage per developer?
Give each developer a distinct gateway credential, either a per-user virtual key or an SSO identity, so the gateway can attribute every request. Bifrost records usage by key, user, team, model, and provider, which the Bifrost Claude Code guides walk through, and Bifrost CLI shows personal budgets and limits to developers signed in with Enterprise SSO.
Is Anthropic's Claude apps gateway enough for an enterprise?
It covers Claude Code and Claude Desktop with SSO, spend caps, policy, and telemetry, which suits organizations standardized on Claude apps. Enterprises that also run other coding agents, internal AI applications, MCP tools, or agents often prefer one gateway for all AI traffic so policy and logs stay in one place.
Getting Started with a Claude Code Gateway
The right Claude Code gateway gives every developer a governed credential, keeps provider keys and logs inside your network, and applies the same policy to Claude Code that applies to the rest of your AI traffic. Bifrost does this with four authentication paths, budgets, MCP governance, and self-hosted deployment. To plan a Claude Code gateway rollout for your teams, book a demo with the Bifrost team.