Skip to content

MCP

Quick facts

Enablemcp: true on any route()
Endpoint{mount}/mcp (default; override mcpPath on mountSpec)
BehaviorSame resolvers as HTTP RPC — same auth, validation, error codes
Agent hintsmeta.mcpInstructions (MCP server instructions; docs UI connect panel shows authHint instead)
ExportOnly scope: 'public' routes appear in tools/list

Set mcp: true on any route. When any route opts in, mountSpec mounts MCP automatically.

Set meta.mcpInstructions for the MCP server instructions field. Use meta.authHint for Bearer guidance in the docs UI connect panel on the home page.

This is API-tool MCP (live tools/call on your server). Fern’s MCP is different — docs Q&A on a Fern-hosted site (Ask Fern), not a substitute for calling your API. You can run both.

See also: mountSpec options · Docs UI