What a gateway does
The Model Context Protocol lets a client such as Claude Code or Cursor start or connect to servers that expose tools. Without a gateway, every client config names every server, and every server keeps its own credentials. A gateway puts one process in the middle. Its usual jobs:
- Routing. Clients see one endpoint. The gateway forwards each
tools/callto the right server and can merge several servers’ tool lists into one. - Access rules. Which person, agent or team may call which tool, usually decided by tool name and identity, sometimes by the arguments too.
- Credentials. The gateway, or the platform behind it, holds each server’s secrets, so they stay out of client config files that get copied around.
- Isolation. Docker’s MCP Gateway, for example, runs each server in an isolated container with restricted privileges, injects credentials, and logs and traces calls.2
- Logs. Who called which tool, with which arguments, and what came back.
There are a lot of them: one public list names more than 40 MCP gateway products.3
Gateway, API gateway, MCP server
An API gateway fronts HTTP APIs for any kind of client and deals in routes, keys and rate limits. An MCP gateway speaks the Model Context Protocol, so it sees tool names and the arguments a model chose, which is what a rule about agents needs to read. An MCP server is the process behind both: it holds a credential and does the work.
A gateway doesn’t shrink the server’s credential. A Postgres server that connects as the table owner can still do anything the owner can, whatever the gateway logged on the way in. The credential is the agent’s real permission set; see blast radius.
What a gateway can’t see
A gateway sits on the wire. It sees the request and the reply the server sends back, and nothing after that. If an UPDATE … WHERE id = 42 fires a trigger that changes 300 other rows, the server reports one row, the gateway logs one row, and the database holds 301 changed rows. Reading the system of record afterwards is a separate step.
The MCP specification also says clients must treat tool annotations, such as a hint that a tool only reads, as untrusted unless they come from trusted servers.1 A gateway rule that relies on a server’s own “read-only” label inherits that weakness.
Questions to ask of any gateway
- Does it decide per call, with the arguments, or only per tool name?
- When a rule can’t be evaluated, does the call run or stop?
- Can a person approve one call, and is that approval recorded?
- Are its logs stored where the agent’s credentials can’t edit them?
- Does anything compare the result with the system of record?