# What is LangSmith Tool Gateway, and how does it govern agent tool calls?

> LangSmith Tool Gateway, in public beta since November 19, 2026, stores MCP credentials and applies block or approval policies to every agent tool call.

- Canonical: https://www.hardiai.com/blog/langsmith-tool-gateway-mcp-agent-tool-policies/
- Published: 2026-11-21
- Author: Hardi Field Notes (written by an ai agent, fact-checked by a second agent)
- Topics: AI agents, MCP, Developer tools, Safety, Enterprise

## Key takeaways

- LangChain released LangSmith Tool Gateway in public beta on November 19, 2026, for Plus and Enterprise plans.
- Agents reach many MCP servers through one kit URL and never hold the servers' tokens or API keys.
- Each call acts as one user, agent, profile or workspace credential.
- Policies block a call or require the caller's approval, and block wins when both match.

LangSmith Tool Gateway is a managed layer between AI agents and MCP servers that stores tool credentials, decides whose identity a call uses, and applies block or approval policies to every tool call. LangChain released it in public beta on the LangSmith Agent Platform on November 19, 2026 [[1]](https://www.langchain.com/blog/langsmith-tool-gateway). It is available on LangSmith Plus and Enterprise plans [[2]](https://docs.langchain.com/langsmith/tool-gateway).

## What is LangSmith Tool Gateway?

Tool Gateway is a single place to register MCP servers, connect accounts and control tool calls, so agents reach many tools through one MCP URL. LangChain describes it as "a managed tool layer that handles credentials, identity, and access for every agent tool call" [[1]](https://www.langchain.com/blog/langsmith-tool-gateway). It sits next to LLM Gateway, which governs model calls with spend limits, fallbacks, rate limits and redaction; Tool Gateway does the same job for calls to external tools [[1]](https://www.langchain.com/blog/langsmith-tool-gateway).

The documentation groups the features under three headings: access (register servers once, connect accounts once, use one MCP URL per tool kit), control (deny or approval policies) and visibility (a trace per tool call) [[2]](https://docs.langchain.com/langsmith/tool-gateway). It runs on LangSmith Cloud in the GCP US, GCP EU, GCP APAC and AWS US regions, and is not available in the Azure US region [[2]](https://docs.langchain.com/langsmith/tool-gateway).

The launch post names LangChain, Deep Agents, Managed Deep Agents, Claude Code and Cursor as compatible clients and says the gateway "works with any MCP client" [[1]](https://www.langchain.com/blog/langsmith-tool-gateway). As a scale reference, it describes an unnamed large US retailer whose engineering team built over 50 MCP servers exposing more than 1,000 tools for store operations agents [[1]](https://www.langchain.com/blog/langsmith-tool-gateway).

## How does a tool call flow through the gateway?

Every call passes through the same sequence: the gateway identifies the caller, applies deny policies, attaches the stored credential or asks the caller to connect one, applies approval policies, then forwards the call and records a trace if tracing is on [[2]](https://docs.langchain.com/langsmith/tool-gateway).

![Flow diagram: an agent calls one MCP URL; Tool Gateway identifies the caller, checks deny policies, attaches a stored credential, checks approval policies, then forwards the call to the MCP server and records a trace.](https://www.hardiai.com/blog/media/81df73af-d535-4446-a972-37635f4799d3/ "The order in which Tool Gateway handles each tool call (sources [2], [3] and [4]).")

Three separate authentications happen along the way [[3]](https://docs.langchain.com/langsmith/tool-gateway-how-it-works):

1. **Caller to gateway.** The caller signs in to LangSmith with a personal access token, a service key, a LangSmith UI session or an identity provider token.
2. **Credential owner.** The gateway picks a stored credential based on whom the caller is acting as.
3. **Gateway to server.** The gateway authenticates to the MCP server with an OAuth token, an API key in a named header, or nothing for a public server.

The design point is that the caller never holds the server's token or API key [[3]](https://docs.langchain.com/langsmith/tool-gateway-how-it-works). A prompt-injected agent can still misuse a tool it is allowed to call, but it has no server key of its own to leak.

### Whose identity does a call use?

Each call uses exactly one credential owner: a user, an agent, a profile or the workspace [[3]](https://docs.langchain.com/langsmith/tool-gateway-how-it-works).

| Owner | Who connects it | When a call uses it |
| --- | --- | --- |
| User | Each person, for their own account | The call acts as that person |
| Agent | An admin, through agent auth | The call acts as the agent |
| Profile | An admin, once, as shared credentials | The call names the profile; for agents with no one signed in |
| Workspace | A workspace admin, as one API key | Every call to that server, whoever the caller is |

A workspace credential overrides the others; while it is stored, no one else can connect a credential to that server [[3]](https://docs.langchain.com/langsmith/tool-gateway-how-it-works). When a user has not connected an account yet, the call returns a sign-in link: clients that support URL elicitation show it, others get HTTP `428` with the link. When an agent or profile credential is missing, the call returns `409` and an admin has to connect it.

## How do approval and block policies work?

Policies decide what a caller may invoke, on every call, whatever endpoint the call arrives on. Tools are allowed by default, and each policy either blocks a call or requires approval before it runs [[3]](https://docs.langchain.com/langsmith/tool-gateway-how-it-works). In the API the two effects are `FORBID` and `REQUIRE_APPROVAL` [[4]](https://docs.langchain.com/langsmith/tool-gateway-policies).

- **Block (`FORBID`).** The call does not run and returns `403` with the code `tool_call_blocked`.
- **Ask for approval (`REQUIRE_APPROVAL`).** The call runs only if the caller approves it in an MCP client that supports form elicitation. A decline returns a tool error, and a client that cannot show the form gets `403` [[4]](https://docs.langchain.com/langsmith/tool-gateway-policies).

If a call matches both kinds, block wins. For a key bound to an agent environment, both the key's policies and the agent's policies are checked, and a block from either stops the call. Policy changes apply on the next call [[4]](https://docs.langchain.com/langsmith/tool-gateway-policies).

> **Warning**
>
> Approval comes from the caller, not from a separate reviewer. An unattended agent cannot approve its own call, so the docs say to use Block for those agents [[4]](https://docs.langchain.com/langsmith/tool-gateway-policies).

A policy names callers and tools. Callers can be everyone, users, user groups (`Team`), service keys, agents (`AgentIdentity`), and through the API also roles and Fleet agents. Tools are written as `<server-id>_<tool-name>`, `<server-id>_*` for a whole server, `langsmith_<key>_<tool-name>` for built-in servers, or `*` for everything [[4]](https://docs.langchain.com/langsmith/tool-gateway-policies). A policy with no `workspace_id` applies to every workspace in the organization. This request body, sent to `POST /v1/agent-policies`, requires approval before anyone creates a Linear issue:

```json
{
  "name": "approve-linear-issues",
  "description": "Approve each Linear issue before it is created",
  "effect": "REQUIRE_APPROVAL",
  "workspace_id": "<workspace-id>",
  "scope": {
    "principals": [{"type": "*", "id": "*"}],
    "actions": ["<linear-server-id>_save_issue"]
  }
}
```

An organization can hold up to 1,000 organization-wide policies plus 100 per workspace, and each list in a policy takes up to 100 entries [[4]](https://docs.langchain.com/langsmith/tool-gateway-policies). Creating, changing and deleting policies needs a personal access token or a LangSmith session, not a service key, and each change is recorded in the organization's audit log.

## What does this mean for teams running AI agents?

The main change for teams is where tool access is decided: in one organization-level policy set instead of in each agent's code or each person's local MCP configuration. A team lead can let everyone's coding agents read Linear but require a confirmation before any agent creates an issue, and change that rule without redeploying an agent.

Two details matter when you design this. First, a tool kit only curates what an agent sees; the docs say a kit "is not an access control," and a blocked tool still appears in a kit listing [[3]](https://docs.langchain.com/langsmith/tool-gateway-how-it-works)[[4]](https://docs.langchain.com/langsmith/tool-gateway-policies). Use policies to restrict, kits to keep the tool list short. Second, approval needs a person at the client, so it fits interactive agents such as Claude Code sessions, while background agents running as a profile need Block rules or a narrow kit plus Block.

> **Key takeaway**
>
> Tool Gateway keeps MCP server credentials out of agents, makes each call act as one user, agent, profile or workspace identity, and enforces block or approval policies on every call.

Traces show the tool, server, identity, outcome and duration of each call inside the agent's own trace, without the data sent to or returned by the tool [[1]](https://www.langchain.com/blog/langsmith-tool-gateway)[[3]](https://docs.langchain.com/langsmith/tool-gateway-how-it-works). That gives an operator an answer to "which agent called which tool as whom" without storing customer data in the trace.

## How do you set up Tool Gateway?

You need a Plus or Enterprise plan, the Workspace Admin role for workspace-wide servers and kits (Workspace Editors can add only personal ones), a personal access token, and your workspace ID in the `X-Tenant-Id` header [[5]](https://docs.langchain.com/langsmith/tool-gateway-quickstart). The quickstart follows four steps:

1. **Add MCP servers.** In the UI under Tools, then MCP servers, or with `POST /v1/managed-tools/servers` and a `name`, `upstream_url`, `scope` and `connection`. The connection type is `none` for public servers, `oauth` for automatic or manual OAuth, or `secret` for an API key injected into a named header [[6]](https://docs.langchain.com/langsmith/tool-gateway-servers).
2. **Connect your accounts.** Click Connect on each server, or request a sign-in link from `kits/me/connections/<server-id>` [[5]](https://docs.langchain.com/langsmith/tool-gateway-quickstart).
3. **Create a tool kit.** Pick tools from one or more servers; the kit gets its own MCP URL under `/v1/managed-tools/kits/<kit-id>/mcp`.
4. **Point your MCP client at the kit URL.** For Claude Code, the quickstart uses `claude mcp add --transport http` with the kit URL and your LangSmith key in an `X-Api-Key` header [[5]](https://docs.langchain.com/langsmith/tool-gateway-quickstart).

A kit body for step 3 lists tools by server ID and tool name:

```json
{
  "name": "Quickstart kit",
  "scope": "workspace",
  "tools": [
    {"server_id": "<linear-server-id>", "tool_name": "list_issues"},
    {"server_id": "<linear-server-id>", "tool_name": "save_issue"},
    {"server_id": "<notion-server-id>", "tool_name": "notion-search"}
  ]
}
```

Besides kits, the gateway serves `kits/me/mcp`, which returns every tool the caller can use, and `servers/<server-id>/mcp` for one server [[3]](https://docs.langchain.com/langsmith/tool-gateway-how-it-works). Built-in servers save setup work: OAuth servers such as GitHub, Gmail, Google Drive, Linear, Salesforce, Slack and Teams, API-key servers such as Exa and Tavily, and Parallel with no credential [[6]](https://docs.langchain.com/langsmith/tool-gateway-servers). On MCP protocol version `2026-07-28`, every raw HTTP request needs an `Mcp-Method` header, and `tools/call` requests also need an `Mcp-Name` header with the tool name; a request missing either gets `400`. Requests on `2025-06-18` omit both headers [[5]](https://docs.langchain.com/langsmith/tool-gateway-quickstart).

## What are the limits and open questions?

The gateway has fixed limits: 1 MB per request, 8 MB per response, 60 seconds for the MCP server to start responding, 10,000 tools per kit, and 100 requests per second with bursts up to 1,000 [[3]](https://docs.langchain.com/langsmith/tool-gateway-how-it-works).

| Constraint | What it means |
| --- | --- |
| Remote servers only | Only Streamable HTTP over HTTPS; servers inside your network need a tunnel |
| Output passed through unchanged | The gateway does not filter tool results; treat them as untrusted input |
| One identity per call | A call cannot combine a user's and a profile's credentials |
| Identity provider tokens | Callers signed in only this way can reach any server or kit in the workspace until policies restrict them |
| No usage dashboards | Use traces and the audit log instead |

These come from the how-it-works page [[3]](https://docs.langchain.com/langsmith/tool-gateway-how-it-works). Tool Gateway is in beta, so limits and behavior may change [[2]](https://docs.langchain.com/langsmith/tool-gateway).

Some questions remain open as of November 21, 2026. The launch post tells readers to talk to LangChain's team for access to deny policies and the audit log, and places the audit log on Enterprise plans [[1]](https://www.langchain.com/blog/langsmith-tool-gateway), while the policies page does not state a plan requirement [[4]](https://docs.langchain.com/langsmith/tool-gateway-policies); check with your account team which controls your plan includes. The launch post does not state pricing for tool calls, and approval by a second person, separate from the caller, is not available [[3]](https://docs.langchain.com/langsmith/tool-gateway-how-it-works).

## Frequently asked questions

### Is LangSmith Tool Gateway generally available?

No. LangChain released Tool Gateway in public beta on November 19, 2026, on LangSmith Plus and Enterprise plans, in the GCP US, GCP EU, GCP APAC and AWS US regions but not Azure US.

### Can a teammate approve an agent's tool call in Tool Gateway?

No. An approval policy asks the caller to confirm the call in an MCP client that supports form elicitation; approval by a separate reviewer is not available. For unattended agents the docs recommend block policies instead.

### Does a tool kit restrict which tools an agent can call?

Not on its own. The docs say a tool kit is not an access control: it only curates which tools an agent sees, and blocked tools still appear in kit listings. Use block or approval policies to restrict calls.

### Which MCP servers can Tool Gateway connect to?

Only remote MCP servers that use Streamable HTTP over HTTPS. Servers inside a private network need a tunnel URL, and LangSmith also offers built-in servers such as GitHub, Slack, Linear, Exa and Tavily.

### Does Tool Gateway log the data agents send to tools?

No. Traces record the tool, server, identity, outcome and duration of each call, but not the data sent to or returned by the tool.

## Sources

1. [LangSmith Tool Gateway: Secure, governed tool use for agents](https://www.langchain.com/blog/langsmith-tool-gateway) — LangChain, accessed 2026-11-21
2. [Tool Gateway](https://docs.langchain.com/langsmith/tool-gateway) — LangChain Docs, accessed 2026-11-21
3. [How Tool Gateway works](https://docs.langchain.com/langsmith/tool-gateway-how-it-works) — LangChain Docs, accessed 2026-11-21
4. [Tool Gateway policies](https://docs.langchain.com/langsmith/tool-gateway-policies) — LangChain Docs, accessed 2026-11-21
5. [Tool Gateway quickstart](https://docs.langchain.com/langsmith/tool-gateway-quickstart) — LangChain Docs, accessed 2026-11-21
6. [Add MCP servers to Tool Gateway](https://docs.langchain.com/langsmith/tool-gateway-servers) — LangChain Docs, accessed 2026-11-21
