MCP Gateway

Agentic tools. Enterprise governance.

Universal Model Context Protocol (MCP) gateway for autonomous AI agents. Proxy enterprise MCP servers via /mcp and /mcp/{server_id} with strict credential sanitization, zero header leaks, sub-millisecond dispatch, and end-to-end request-ID audit tracing.

mcp · tool execution

Agent Tool Orchestration

Active MCP Serverpostgres-mcp-prod (/mcp/srv-01)
Connected AgentLangGraph · Financial Analyst Loop
Tool Invokedexecute_sql_query (Read-Only Replica)
Credential HygieneStripped Authorization & Bearer Headers
Proxy Dispatch Latency18.4 ms (Zero-Copy Rust Pipe)
Header Leak StatusZero Leaks (Strict Allowlist Enforced)
Zero Header LeaksCredential StrippingRequest-ID Traced
Tool execution dispatch
< 1 ms

High-speed asynchronous Rust proxy

Protocol standard
MCP 1.0

Universal JSON-RPC context protocol

Credential leakage risk
Zero

Strict header sanitization & upstream token injection

Model compatibility
434+

Automatic schema and format translation

Execution Pipeline

Secure tool proxying for autonomous agent workflows

Agents dispatch tool requests via standard MCP endpoints. nRouter validates authorization, injects enterprise secrets securely, executes the tool, and streams telemetry back to your observability pipeline.

Model Context Protocol Execution Lifecycle

  1. Agent Instruction

    Tool Call Request

    Autonomous agent initiates an MCP tool call (database query, API fetch, or document index).

  2. MCP Gateway Proxy

    Protocol Validation

    nRouter validates JSON-RPC schema, verifies virtual key permissions, and checks tool authorization.

  3. Credential Hygiene

    Zero Header Leaks

    Strict header allowlists strip sensitive client Authorization tokens while attaching tool credentials.

  4. Sandboxed Execution

    Telemetry & Settle

    Tool call is logged with execution latency, payload size, and return code under the parent x-nr-request-id.

Agent Architecture

Decouple tools from models with centralized governance

Tool Security

Eliminate credential leaks and uncontrolled agent tool loops

Autonomous agent loops require access to external databases, microservices, and internal APIs. nRouter MCP Gateway proxies all tool calls through /mcp and /mcp/{server_id}, stripping sensitive authentication headers and preventing credential exfiltration. See our security posture and press announcements on enterprise agent safety.

  • Zero header leaks: client Authorization and virtual-key secrets stripped before tool proxying
  • Server-side credential injection attaches tool-specific secrets securely inside the proxy
  • Strict parameter schema validation blocks malformed SQL queries or command injection
  • Timeout circuit breakers abort runaway agent loops before database starvation
  • Unified tracing links every tool execution directly to the parent x-nr-request-id
governance · tool fleet

Connected Enterprise MCP Tools

mcp-analytics-dbRead-Only (500ms Timeout)
mcp-github-pr-botScoped to repo:core-app
mcp-slack-notifierApproval Required on #general
mcp-bash-runnerBlocked by Org Policy
Scoped PermissionsCircuit BreakersAudit Logged
Full MCP gateway technical specification — schemas, security & transport
Standardized Model Context Protocol (MCP)
Native support for the open standard for AI tools and context servers. Connect your AI agents to Postgres, GitHub, Slack, filesystem, and custom internal APIs without custom glue code.
Zero header leaks & credential isolation
Agents never receive or leak raw database passwords, internal API tokens, or secrets. nRouter MCP Gateway enforces strict header allowlists, strips client virtual keys, and injects authentication tokens server-side.
Cross-model protocol translation
Seamlessly translate tool calls between OpenAI function calling format, Anthropic tool use schemas, and native MCP JSON-RPC, allowing you to swap model backends without rewriting agent tools.
Tool call observability
Every tool invocation is tracked with execution latency, payload size, return code, and error messages, bound directly to the parent LLM request via unified x-nr-request-id.
Fine-grained tool permissions per virtual key
Restrict which tools an agent or user can invoke. Define read-only vs mutating tool scopes, disallow dangerous shell execution, and enforce approval gates on sensitive actions.
High-concurrency Rust proxy core
Built inside the nRouter high-performance Rust proxy engine. Dispatches thousands of concurrent tool calls with negligible latency overhead (<1ms proxy routing).
Common questions

Frequently asked questions about the MCP gateway

What is the Model Context Protocol (MCP)?

Model Context Protocol (MCP) is an open industry standard that enables AI models and autonomous agents to securely connect to external tools, databases, repositories, and context sources with a standardized protocol.

How does nRouter prevent header leaks during MCP tool proxying?

The Rust gateway enforces a strict HTTP header allowlist on all MCP proxy routes (/mcp and /mcp/{server_id}). Client authorization tokens (such as sk-nrouter-* keys) and sensitive request headers are scrubbed before reaching the MCP tool server. Upstream tool credentials stored in enterprise key vaults are injected server-side. Tool response headers are similarly filtered to ensure no downstream server secrets are leaked back to the client agent.

Can I use MCP with models that do not natively support it?

Yes. The nRouter Gateway automatically bridges and translates standard OpenAI tool-calling and Anthropic tool-use formats into standardized MCP JSON-RPC messages, enabling tool usage across the live model catalog.

Which agent frameworks are supported?

nRouter MCP Gateway works out of the box with LangChain, LlamaIndex, CrewAI, AutoGen, Microsoft Semantic Kernel, and native Python / TypeScript MCP client libraries.

Does tool execution incur token charges?

Tool execution through the MCP Gateway does not incur additional per-token markup. You only pay for standard LLM inference tokens consumed by the model before and after the tool invocation.

Where can I host my MCP servers?

You can host MCP servers in your own private VPC (AWS, Azure, GCP), behind Cloudflare Tunnels, or connect to publicly available enterprise MCP servers via mTLS and Bearer authentication.

Empower Your Agents

Supercharge autonomous AI agents with the MCP Gateway

Connect your AI agents to enterprise data and tools with standardized security, credential isolation, and comprehensive observability.