Surfil

Consolidate MCP servers

Running several agents usually means several copies of the same MCP servers, each re-sending overlapping context. Consolidation merges them behind the single interception point, cutting token sprawl without changing which tools your agents can call.

What it does

surfil consolidate discovers the MCP endpoints configured across your agents, deduplicates them, and routes them through one endpoint - the same point the pipeline intercepts at. Your agents keep seeing every tool; they just stop each maintaining a private, redundant connection.

Steps

  1. Install and link if you haven't: curl -fsSL https://surfil.com/install.sh | sh, then surfil login.
  2. Run surfil consolidate. It reports how many servers merged.
  3. Use your agents normally - tool calls now route through one endpoint.
$ surfil consolidate
✓ discovered 6 MCP servers across Claude Code, Cursor
✓ merged → 1 endpoint (duplicates collapsed)
✓ Weave bootstrapped

Why it saves tokens

Duplicate servers re-send tool schemas and context on every session. One endpoint sends them once and reuses the prefix cache byte-exact across agents. The savings are measured on your own traffic and signed into a receipt - see Verify a receipt offline.

Consolidation is reversible: surfil uninstallrestores each agent's original MCP config byte-for-byte.