AI Gateway is now available: identity-aware access to any AI provider, eliminate API keys, and tunnel to self-hosted models. Get started

AI GatewayProviders

Anthropic

Connect Anthropic as an AI Gateway provider

An Anthropic provider forwards Messages requests to Anthropic's API. Attach it to an AI Gateway resource when you want Claude Code, Claude Desktop, OpenCode, OpenClaw, or any other Anthropic-compatible client to use your org's Anthropic key.

See AI Providers if you haven't created a provider before. Field options are in Provider Configuration.

Defaults

SettingValue
Upstream URLhttps://api.anthropic.com
Auth typex-api-key
CapabilitiesAnthropic Messages, Anthropic Models

Anthropic Models (GET /v1/models) is answered from this provider's allow and block lists. See Capabilities.

Configure

  1. Sidebar → AI Gateway → Providers → Create.
  2. Set Provider Type to Anthropic. Name, capabilities, upstream URL, and auth type fill in from the defaults above.
  3. Paste your Anthropic API key.
  4. Set Allow and Block lists. * allows every model key; claude-* is a typical narrower pattern.
  5. Save, then attach the provider to an AI Gateway resource.

Leave the upstream URL as the default unless you are pointing at a compatible Anthropic-style base URL.

Clients can send anthropic-version themselves. You can also set it as a custom header on the provider (anthropic-version: 2023-06-01). A header set on the provider is always sent upstream and overrides the same header from the client.

Clients

ClientGuide
Claude CodeSetup guide
Claude DesktopSetup guide
OpenCodeSetup guide
OpenClawSetup guide

Was this page helpful?

⌘I

On this page