Skip to main content
POST
Core - Create MCP gateway
Related guide: MCP gateways guide. See the MCP gateways guide for a walkthrough with examples.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
key
string
required

Lowercase slug of letters, digits, hyphens and underscores, max 64 characters, unique per workspace; backs the gateway's public MCP URL.

display_name
string
required

Human readable name shown in the workspace.

Example:

"Production Gateway"

description
string

Free-form note about what this gateway is for.

Upstream servers this gateway aggregates.

tool_naming
enum<string>

How upstream tool names are namespaced before they are exposed. Defaults to PREFIX_ON_COLLISION.

Available options:
MCP_TOOL_NAMING_PREFIX_WITH_SERVER_KEY,
MCP_TOOL_NAMING_PREFIX_ON_COLLISION
mode
enum<string>

Shape of the tool surface presented to MCP clients: CODE or DIRECT. Defaults to CODE.

Available options:
MCP_GATEWAY_MODE_CODE,
MCP_GATEWAY_MODE_DIRECT
sharing
object

Which projects in the workspace may use this gateway. Defaults to every project.

plugins
object[]

Plugins run on every tool call this gateway serves.

skill_ids
string[]

Workspace skills this gateway serves to MCP clients through the MCP Skills extension.

icons
object[]

Icons advertised to MCP clients; defaults to Toqan Router branding when empty.

website_url
string

Website advertised to MCP clients; defaults to Toqan Router documentation when empty.

guardrails
object[]

Guardrails run on the arguments and result of every tool call this gateway serves.

Response

OK

mcp_gateway
object