toolmark-monorepo / @toolmark/mcp / toMcpTool
Function: toMcpTool()
toMcpTool(
t):McpTool
Defined in: packages/mcp/src/server/tool-mapping.ts:158
Maps a full manifest entry to an MCP tool (spec §11.3, §23 "MCP tool mapping"): name is the llmName, annotations are always explicit, and untrustedContent tools say so in their description and _meta. The description is capped at MAX_DESCRIPTION_LENGTH (before the untrusted suffix), the title at MAX_TITLE_LENGTH, and the input schema by MAX_INPUT_SCHEMA_BYTES / MAX_INPUT_SCHEMA_DEPTH.
Parameters
t
A full manifest entry (as returned by describe).
Returns
The MCP Tool for tools/list.