MCP
Model Context Protocol integration in Fabric Harness.
Fabric Harness can integrate with Model Context Protocol (MCP) servers in two directions: consuming MCP tools/resources from inside an agent, and exposing Fabric agents as MCP-compatible endpoints. The full notes live at docs/mcp.md.
Consuming MCP servers (designed-for)
Mount an MCP server's tools as session tools:
import { mcpClient } from '@fabric-harness/sdk';
const fabric = await mcpClient({
command: 'npx',
args: ['-y', '@modelcontextprotocol/server-fabric'],
});
await session.prompt('Look up project FAB-123', {
tools: [...tools, ...fabric.tools],
});The MCP client adapter is roadmap — current state and any temporary helpers live in @fabric-harness/sdk exports.
Exposing Fabric agents as MCP
A Fabric agent's metadata (agent({ name, input, output, ... })) maps cleanly onto MCP tool definitions. The Node target can emit an MCP-compatible endpoint alongside the existing webhook routes — designed-for, not yet implemented.
Why MCP
MCP is becoming a converging standard for tool/resource exchange across agent ecosystems. Wiring Fabric agents and MCP servers together means you can:
- give Fabric agents access to a growing catalog of MCP-served tools,
- expose Fabric agents as MCP tools to other systems (Claude Desktop, Cursor, IDE plugins, custom UIs),
- let Foundry Toolbox (preview) and Fabric tools share the same definitions.