Beta: The LLM Gateway is in beta.
What the gateway provides
- One key, multiple providers: Developers authenticate with a LangSmith API key instead of storing provider keys locally.
- One request format, multiple models: Use Chat Completions, Messages, or Responses with models across configured providers.
- Built-in observability: Every gateway call appears as a LangSmith trace.
- Central governance: Apply spend limits, rate limits, and data policies.
See what a request looks like
Once an administrator has completed the setup, a gateway call is a standard Chat Completions request authenticated with a workspace-scoped LangSmith API key. This example calls the US gateway on LangSmith Cloud and assumes the workspace has an Anthropic provider secret:200 response confirms that the gateway, your LangSmith API key, permissions, and the selected provider secret are configured correctly. To make this request yourself in cURL, Python, TypeScript, or Deep Agents, follow the quickstart.
Use the standard API
Choose the request format already used by your application. The format does not limit which configured provider you can call.
Set
model to a provider-prefixed bring-your-own-key ID such as openai/gpt-5.4-mini, anthropic/claude-opus-5, or azure/<deployment-name>, or use a Gateway Credits model slug such as moonshotai/kimi-k3.
To call a saved model configuration, such as one that points to a custom OpenAI-compatible endpoint, use custom/<name>. The model ID determines the upstream route. When the selected provider uses a different native format, the gateway translates the request and response.
The gateway runs on LangSmith Cloud in every region, on BYOC, and on self-hosted LangSmith. On BYOC and self-hosted, the same paths sit behind the /gateway prefix, such as POST /gateway/v1/chat/completions. For the hostname to use in each case, see Check availability. Self-hosted installations also need an administrator to enable the gateway in the Helm chart.
For base URLs, examples, and translation behavior, see API formats.
Choose how credentials are managed
Go further
Quickstart
Make a request with cURL, Python, or TypeScript, then view its trace.
Administrator setup
Enable the gateway, add provider credentials, and grant developer access.
Connect these docs to your agent of choice via MCP for real-time answers.

