/install-mcp
April 3, 2026 ยท View on GitHub
A template Claude Code slash command that intelligently routes MCP server installations across multiple MetaMCP instances based on a tiered preference system.
What This Does
When you tell Claude "I want to install this MCP," this slash command instructs it to:
- Evaluate whether the MCP needs local desktop resources (filesystem, hardware, local binaries)
- Prefer remote deployment to a networked MetaMCP instance (always-on, shared across machines)
- Fall back to local only when the MCP genuinely can't work over the network
- Route to the correct namespace (personal vs. work) based on the MCP's purpose or your instruction
The Setup This Models
This template assumes a two-instance MetaMCP architecture:
graph TB
Desktop["๐ฅ๏ธ Desktop Client<br/>(Claude Code / AI Tool)"]
subgraph local["Localhost โ MetaMCP Instance 1"]
direction TB
LP["personal-desktop<br/>namespace"]
LW["work-desktop<br/>namespace"]
end
subgraph remote["LAN Server โ MetaMCP Instance 2"]
direction TB
RP["personal-remote<br/>namespace"]
RW["work-remote<br/>namespace"]
end
Desktop -- "SSE (fallback โ local<br/>resources needed)" --> local
Desktop -- "SSE (preferred โ<br/>always-on)" --> remote
subgraph local_mcps["Local MCP Servers"]
LM1["Audio Transcription<br/>(local file input)"]
LM2["Screenshot Capture<br/>(display access)"]
LM3["Filesystem MCP<br/>(local paths)"]
end
subgraph remote_mcps["Remote MCP Servers"]
RM1["Gmail / Calendar<br/>(cloud API)"]
RM2["GitHub / Slack<br/>(cloud API)"]
RM3["Image Gen / AI<br/>(returns URLs)"]
end
local --> local_mcps
remote --> remote_mcps
style local fill:#fff3cd,stroke:#ffc107
style remote fill:#d1ecf1,stroke:#17a2b8
style local_mcps fill:#f8d7da,stroke:#dc3545
style remote_mcps fill:#d4edda,stroke:#28a745
Key principle: The remote server is always preferred. The local instance is only used when an MCP genuinely needs access to the desktop's filesystem, hardware, or local binaries.
How to Use This Template
1. Fork or copy this repo
2. Edit install-mcp.md
Replace the placeholder values with your actual setup:
| Placeholder | Replace With |
|---|---|
mcp.example.com | Your remote MetaMCP host |
10.0.0.4 | Your remote server's LAN IP |
desktop-mcp.example.com | Your local MetaMCP tunnel domain |
localhost:12008 | Your local MetaMCP port |
personal-remote / work-remote | Your remote namespace names |
personal-desktop / work-desktop | Your local namespace names |
3. Install the slash command
Copy install-mcp.md to your Claude Code commands directory:
# User-level (available in all projects)
cp install-mcp.md ~/.claude/commands/install-mcp.md
# Or project-level
cp install-mcp.md .claude/commands/install-mcp.md
4. Use it
In Claude Code, type:
/install-mcp
Then tell Claude which MCP you want to install. It will handle the rest.
Adapting to Your Setup
Single MetaMCP instance? Remove the remote/local decision tree and just keep the personal/work namespace routing.
More than two namespaces? Add additional namespaces to the flowchart (e.g., dev, staging, shared-team).
No personal/work split? Simplify to just the location decision (remote vs. local).
Different fallback criteria? Edit the "Deploy here ONLY when" section in install-mcp.md to match your constraints.
Why MetaMCP?
MetaMCP aggregates multiple MCP servers behind a single SSE endpoint, with namespace-based routing. This means your AI tools connect to one URL per namespace rather than managing dozens of individual MCP connections. It's transport-agnostic โ stdio MCPs get wrapped behind SSE automatically.
License
MIT