LayerMap — Claude Code MCP server: what it does, install
This MCP server maps code dependencies and traces changes to HTTP routes, jobs, and commands. Use it when an agent needs impact analysis before editing.
claude mcp add layermap -- npx -y layermapWhat LayerMap does
LayerMap gives coding agents read-only MCP tools for exploring a codebase. A single query can show callers leading to HTTP routes, handlers, jobs, and commands, then list callees, declarations, and symbol usages. Its change check connects uncommitted edits with reached routes, jobs, commands, and related tests.
For TypeScript, JavaScript, Go, Python, and Java, links come from each language’s compiler or type checker rather than name matching. That means interface calls, base classes, templates, and decorators can be resolved as well. Caller and callee tracing reaches 8 levels in each direction. The server runs locally and does not edit the project.
What it helps with
- trace a function’s callers to HTTP routes
- inspect the callees of a selected symbol
- find routes affected by an uncommitted change
- connect changed code with related tests
Example prompts for the agent
- Show which HTTP routes are affected by changing
Storage.MarkFeedAsRead. - Trace callers of
internal/storage/entry.goup to their handlers and routes. - Check which tests are related to my uncommitted changes.
How to install LayerMap
Platform CLI
claude mcp add layermap -- npx -y layermapPlatform CLI
codex mcp add layermap -- npx -y layermapConfig file
{
"mcpServers": {
"layermap": {
"command": "npx",
"args": [
"-y",
"layermap"
]
}
}
}Config file
{
"servers": {
"layermap": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"layermap"
]
}
}
}Platform CLI
gemini mcp add layermap npx -y layermapStep by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about LayerMap
How do I install LayerMap in Claude Code?
Run claude mcp add layermap -- npx -y layermap.
What does LayerMap do?
It builds a call map for coding agents, linking functions to callers, callees, HTTP routes, jobs, commands, and related tests. Its MCP tools are read-only.
Which languages does LayerMap support?
It supports TypeScript, JavaScript, Go, Python, and Java. The links are resolved through each language’s compiler or type checker.