Drkilla/legacy-map
Automatic PHP/Symfony execution flow mapping via XDebug + MCP
Platform-specific configuration:
{
"mcpServers": {
"legacy-map": {
"command": "npx",
"args": [
"-y",
"legacy-map"
]
}
}
}Add the config above to .claude/settings.json under the mcpServers key.
Automatic execution flow mapping for PHP/Symfony via XDebug + AI.
> You click in your app. You ask Claude: "What just happened?" He tells you.
On a PHP/Symfony codebase — especially legacy:
You trigger a request in your app
│
XDebug captures the full execution trace
│
legacy-map filters the noise (99.97% of framework calls eliminated)
│
You ask Claude → he explains the flow, generates docs, diagramsWorks without AI too — parse and watch output JSON directly, no LLM required.
| Endpoint | Raw calls | After filtering | Reduction | |----------|-----------|-----------------|-----------| | POST /api/admin/clients | 133,000 | 43 | 99.97% | | POST /api/auth/login | 102,272 | 29 | 99.97% | | GET /api/admin/cases | 133,000 | 43 | 99.97% | | POST /api/chat | 7,432 | 16 | 99.78% |
go install github.com/drkilla/legacy-map@latestcd /your/symfony/project
legacy-map init
# Follow the displayed instructionsinit detects your environment (Docker or local), checks if XDebug is installed, generates the config, and guides you step by step.
legacy-map setup-mcp ./xdebug-tracesRestart Claude Code, then:
> "Trace the flow of POST /api/clients"Claude triggers the request, captures the XDebug trace, and explains the full execution flow. No browser, no curl.
No need to leave Claude Code. Just ask:
> "What happens when I POST to /api/auth/login?"
> "Trace the GET /api/cases flow with this token: Bearer xxx"
> "Compare the flows of /login and /clients"Claude uses the trigger_trace
Loading reviews...