MCP servers API: register and manage your org's servers

Register a Streamable HTTP MCP server once, keep its headers sealed, pick the tools it offers on /mcp/org, and read recent tool calls, with an admin key.

Checked 2026-11-22

·API reference·Models

The gateway can put your own MCP servers behind one endpoint, https://api.uplinkswitch.com/mcp/org, and six routes under https://api.uplinkswitch.com/v1/mcp-servers decide which servers it fronts. Each server is a Streamable HTTP MCP endpoint on a public https address. Its tools appear on /mcp/org as name__tool, so a server registered as crm that has a lookup tool is offered to clients as crm__lookup.

The six management routes take an admin key, which you create in the console, or a signed-in console session. /mcp/org works the other way round: it accepts only a regular API key and refuses admin keys, so the key that registers servers is never the key that calls their tools.

The six routes

Method and pathWhat it does
GET /v1/mcp-serversReturns the registered servers in data.
POST /v1/mcp-serversRegisters a server and answers 201 with the stored record.
GET /v1/mcp-servers/{server_id}Reads a single server.
PATCH /v1/mcp-servers/{server_id}Updates any subset of its fields.
DELETE /v1/mcp-servers/{server_id}Deletes the server.
GET /v1/mcp-servers/callsTool calls made through /mcp/org, newest first.

A server id is mcp_ plus 24 hex characters, and one organization can register up to 20 servers.

Fields for POST

FieldTypeNotes
namestring, requiredLowercase letters, digits, _ and -, starting with a letter or digit, at most 32 characters. Two underscores in a row and a final underscore are both rejected, because __ is what separates server from tool.
urlstring, requiredPublic https only. Private, loopback, link-local and reserved targets fail, the target is checked again ahead of each call, and redirects are never followed.
headersobject or nullAt most 20 headers, sent with each call to this server (an Authorization value, say). Sealed at rest; reads expose only header_names.
tool_allowlistarray or nullThe server's own tool names to publish; null publishes them all.
enabledbooleanTurns the server off or on without deleting it.

The record that comes back holds id, name, url, header_names, tool_allowlist, enabled, prefix (the name followed by __), created_at and updated_at, both timestamps in Unix milliseconds. On PATCH, a headers object replaces the whole stored set, null wipes every header, and any field you omit stays as it was.

The call log

GET /v1/mcp-servers/calls answers with data, one entry per tool call with ts, key_id, server, tool, status, http_status, error, latency_ms and arguments. The status is ok, tool_error, failed, denied (the tool sits outside that server's allowlist) or blocked (the calling key's tool policy forbids it). arguments is filled in only when the calling key keeps request bodies and is null for every other key. Pass limit from 1 to 200 (50 when absent) and server_id to see one server alone.

Status codes

  • 201 (POST): the server was registered.
  • 400 invalid_url when the address is not public https, or invalid_request for any other malformed field.
  • 401 invalid_api_key: the request brought neither an accepted key nor a console session.
  • 404 not_found: your organization has no server with that id.
  • 409 (POST) name_taken when another server already uses the name, or limit_reached once 20 exist.

Example

bash
curl https://api.uplinkswitch.com/v1/mcp-servers \
  -H "Authorization: Bearer sk-uplink-live-..." \
  -H "Content-Type: application/json" \
  -d '{"name": "crm", "url": "https://tools.example.com/mcp", "headers": {"Authorization": "Bearer ..."}, "tool_allowlist": ["lookup"], "enabled": true}'

Send that with an admin key. Then give an MCP client https://api.uplinkswitch.com/mcp/org and a regular API key, and its tools/list shows crm__lookup. The MCP gateway feature page covers the endpoint from the client's side.

Questions and answers

No. Reads say which names are stored, through header_names, and never print a value. To rotate one secret, PATCH the complete headers object again, since that call swaps out the entire set.

Only public https. Private, loopback, link-local and reserved targets are refused when you register and again before each call, and redirects are not followed, so the rule holds on every call and not only on the day you register.

Put the tools to publish in tool_allowlist; leave it null to publish every tool the server advertises. A call to an unlisted tool is not forwarded, and it shows in the call log with the denied status.
Join on Telegram
Help