MCP Gateway: Your tool servers. One gateway key.

An MCP gateway is the single access point between your AI agents and the MCP tool servers you run: agents connect with one gateway key instead of separate credentials per server. nRouter's MCP Gateway keeps your servers under your control and applies access and rate limits at the gateway.

Watch a tool call pass through.

How MCP Gateway works. Register in MCP Hub. Call with your key.

Keep your servers

Connect remote HTTPS MCP servers across your organization.

  • Register Streamable HTTP endpoints in MCP Hub in your dashboard
  • Route to /mcp/{server_name}, or bare /mcp when one server is active
  • Tools Hub aggregates cached tools across your servers in one catalogue
MCP Hub, your organizationgithubremote HTTPS server/mcp/githublinearremote HTTPS server/mcp/lineardocs-searchremote HTTPS server/mcp/docs-searchTools Hubsearch_issues, create_ticket, query_docs, …

Use one gateway key

You supply the server credential. nRouter stores it encrypted and adds it when forwarding.

  • Stores your supplied server credential encrypted at rest
  • Strips your organization gateway key and x-nr-* headers before forwarding
  • Adds your stored server credential to the upstream request
from your agentAuthorization: org gateway keyx-nr-tags: …removed before forwardingstored encryptedyour server credentialto your MCP serverAuthorization: your server credential

Apply access and rate limits

Checks access and limits, and keeps your gateway key out of upstream requests.

  • Enforces your organization key, budget standing, plan and rate limits
  • $0 proxy fee per MCP call and no credits reserved on /mcp routes
  • Pay-as-you-go accounts include 1 registered MCP server
organization keybudget standingplan limitsrequest rateserver$0 proxy fee per MCP callNo credits reserved on /mcp routes.

Take a closer look. How the SDK works.

  1. 01

    Install

    One package for your language. Python and TypeScript shown; every official SDK works the same way.

    pip install nrouter-sdknpm install @nrouter_ai/sdk
  2. 02

    Create a client

    nRouter() reads NROUTER_API_KEY from your environment and sends each call to api.nrouter.ai. Provider keys are ours to manage.

    client = nRouter()
  3. 03

    Call any model

    The OpenAI-compatible calls you already know. nRouter’s options ride on the same request; each topic below shows one.

    client.chat.completions.create(…)

Already on the OpenAI SDK? Point its base URL at https://api.nrouter.ai/v1 and keep your code.

Send MCP JSON-RPC over Streamable HTTP to /mcp/{server_name}. The gateway checks access and limits, then forwards with your stored server credential.

curl -X POST https://api.nrouter.ai/mcp/weather-tool \
-H "Authorization: Bearer $NROUTER_API_KEY" \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"get_weather","arguments":{"city":"SF"}}}'

Read the docs

FAQs

What does the nRouter MCP Gateway do, and does nRouter host my MCP servers?

nRouter MCP Gateway is a stateless HTTP reverse proxy for the Model Context Protocol (MCP). You host and operate your own MCP servers and register their HTTPS endpoints in MCP Hub in your organization’s dashboard. Agents send Streamable HTTP requests to /mcp/{server_id} (or /mcp with a server selector) using your organization’s nRouter virtual key, and the gateway checks access and rate limits before forwarding the request to your server.

How are client keys and upstream server credentials handled?

When you register an MCP server in MCP Hub, you can supply its upstream credential—such as a Bearer token, API key, Basic login, Authorization header, or token—or choose no authentication (OAuth 2.0 and AWS SigV4 are not supported). nRouter stores the supplied credential encrypted at rest. On each proxied call, the gateway strips the caller’s Authorization, x-api-key, and x-nr-* headers so your nRouter key never reaches the upstream server, then adds your stored server credential when forwarding.

Does the MCP Gateway translate OpenAI or Anthropic tool calls into MCP?

No. The /mcp and /mcp/{server_id} routes forward MCP JSON-RPC requests and responses over Streamable HTTP without translating model tool-calling formats. Your agent or MCP client calls /v1/* for model inference and calls /mcp/{server_id} when executing an MCP tool against your registered server.

What transport, network, and server-selection limits apply?

Registered MCP servers must use Streamable HTTP (POST, GET server-sent events, and DELETE) over a public HTTPS URL. Local stdio processes, client-certificate mTLS, and private, loopback, link-local, or cloud metadata IP addresses are not supported. Request bodies are capped at 8 MiB of valid UTF-8 JSON and streamed responses are capped at 32 MiB; response headers strip text/html and image/svg+xml content-type labels and add x-content-type-options: nosniff without inspecting or sanitizing the response body. Bare /mcp does not combine tools across multiple servers—if more than one server is active, each request must select a target server via /mcp/{server_id}, ?server=, or the x-nr-mcp-server header.

How many MCP servers can I register on my account?

Pay-as-you-go accounts include 1 registered MCP server in MCP Hub. Grandfathered subscription accounts support up to 10 registered servers, and Enterprise organizations support up to 1,000 servers.

What does it cost to proxy tool calls through /mcp?

nRouter charges a $0 proxy fee per MCP call and reserves no credits on /mcp routes. Every call still requires an active organization virtual key and must pass your budget standing, plan limits, and request-rate (RPM) limits. Any fees charged by your upstream tool provider, as well as any model inference calls your agent makes on /v1/* routes before or after a tool call, are billed separately.

  1. Each /mcp/{server_name} endpoint routes to one upstream server, while bare /mcp resolves automatically when your organization has a single active server. In the dashboard, Tools Hub aggregates every server’s cached tools into one searchable catalogue.
  2. You supply the upstream credential when registering a server in MCP Hub (or choose no authentication). nRouter stores the supplied credential encrypted at rest, strips your organization’s gateway key and x-nr-* headers before forwarding, and adds the server credential to the upstream request.
  3. Proxied MCP calls carry no proxy charge and reserve no credits while enforcing your organization’s key, budget standing, plan limits, and request-rate limits. Pay-as-you-go accounts include 1 registered MCP server. Any third-party tool-provider charges and model inference requests on /v1/* are billed separately.