# Connect an MCP server once, use it from every agent

> Source: <https://depot.dev/blog/mcp-in-managed-agents>
> Published: 2026-11-17 00:00:00+00:00

**Key takeaway:** Depot's MCP proxy keeps upstream credentials out of the sandbox by having each run call it with a short-lived identity, and it automatically wraps large MCP tool lists behind one search and one call tool for Amp, Codex, Devin, and depot-mcp.

## Stay in the loop

# Connect an MCP server once, use it from every agent

Depot Managed Agents now supports MCP servers, so your agents can use shared tools without repeating the setup for every run.

Teams rarely use just one coding agent. One agent handles code review, another takes long refactors, and someone is always trying the new one that shipped last week. Each agent has its own MCP config format, its own OAuth flow, and its own place to keep tokens, and every teammate repeats that setup on every machine they work from.

With Managed Agents, you add an MCP server to a provider connection once and sign in once. After that, agents in every run on that connection can call the server's tools. MCP support is available for Amp, Claude Code, Claude Managed Agents, Devin, and OpenAI connections.

## Set it up once, not once per agent

Without a shared place for MCP config, the setup work multiplies: agents × teammates × servers. A few agents, a team of engineers, and a handful of servers add up to a lot of config files, OAuth prompts, and expired tokens, and they drift out of sync.

Managed Agents removes that multiplication. You set up each server once, on the connection. Everyone who starts runs on that connection gets the same tools, with nothing to configure locally. Organization-level MCP servers are shared across provider connections. Servers added to one connection are available only to runs on that connection.

## What you get

- **Tokens never enter the sandbox.** The sandbox calls Depot's MCP proxy using its own short-lived identity. Depot works out which run is calling and makes the upstream request with the stored credential. The token or header never reaches the agent's machine, so a prompt-injected agent has nothing to read out.
- **Secrets only go where they belong.** Token headers can reference a run secret as`${secrets.NAME}` . That secret must be bound to the server's host, or the call fails. Depot only connects to public https servers: no private addresses and no redirects.
- **Native tools where the agent supports them.** Amp, Claude Code, and Codex see your servers as ordinary MCP tools from a server named`depot` . Every agent can also use the`depot-mcp` command inside the sandbox.
- **Big servers, small context.** Some servers expose dozens of tools. For Amp, Codex, Devin, and the`depot-mcp` command, Depot automatically puts large tool lists behind two tools, one to search and one to call. Smaller tool lists stay directly available, while larger lists don't fill the context window.

## How we use it

Our own agents call MCP servers through the same proxy. Here's what we've connected and how we use it:

- **PlanetScale** : An agent investigating a slow page used our database's query insights to find a query that fetched full webhook payloads the page never displayed. It proposed a one-column change that reduced the data fetched to a small fraction of the original amount. The investigation used only read queries.
- **Linear** : Agents file issues and link related reports as they work. One traced an incorrect “needs changes” review to a diff against the wrong base branch. It filed the bug and linked it to an earlier report.
- **Statsig** : An agent checks GitHub's status page every few minutes and turns our GitHub-outage banner on or off. It only turns off a banner it turned on itself, so it leaves banners enabled by a person alone.
- **Plain** : Before replying to a support thread, an agent reads the full history. Its summary reflects what we actually told the customer rather than assumptions.

When an agent needs to write, as with the Statsig banner, we give it one narrow job and a rule for when to stop.

## Get started

You need an existing provider connection in Depot. If you haven't connected a provider yet, follow the [setup instructions for your provider](https://depot.dev/docs/managed-agents/overview#supported-providers) first.

1. Open [**Settings → Managed Runs**](https://depot.dev/orgs/_/settings/agent-runs) , pick a connection, and open its run settings.
2. Under **MCP servers** , add a server: a short name and its https URL.
3. Click **Log in** to sign in with OAuth, or add a token header.

The remaining setup depends on your connection's provider:

- **Amp and Claude Code connections** need no additional MCP setup.
- **Claude Managed Agents** runs its agent loop outside the sandbox, so describe the`depot-mcp` command in the agent's system prompt.
- **Devin** needs a one-time entry in Devin's own MCP settings that points at the sandbox's local Depot server.
- **OpenAI sessions** need`capability_directories: ["/opt/depot/capabilities/depot"]` in their environment configuration.

Only remote (https) MCP servers are supported. Local `stdio` servers aren't. For the full details, see [Use MCP servers in runs](https://depot.dev/docs/managed-agents/overview#use-mcp-servers-in-runs).

## What's next

Need help connecting an MCP server? [Contact support](https://depot.dev/help) or join us in [Discord](https://discord.gg/depot).
