The full upstream README, mirrored here for reference. Install config, tool schemas, adoption signals, and an original overview live on the Sourcemap Retrace MCP listing page.
Your app crashed in production. The stack trace is useless. Your AI agent has no idea where the bug is.
MCP server that decodes minified production stack traces back to original TypeScript source files, lines, and columns — using source maps. Before your agent spends 20 minutes guessing at obfuscated code.
Your monitoring tool sends you this:
You ask your agent to debug it. The agent reads main.a3f2c1.js. It's 40,000 characters of minified JavaScript. It has no idea what e.<anonymous> at column 47821 means.
sourcemap-retrace-mcp maps that back to:
Now the agent knows exactly where to look.
retrace_stackDecode a minified stack trace back to original TypeScript source locations. Pass the raw stack trace and the directory containing your .js.map files.
retrieve_code_contextShow the original source lines surrounding a mapped error location — with line numbers and a column pointer.
audit_sourcemap_matchValidate that .map files in your dist directory are present and point to source files that actually exist on disk. Catches stale or missing maps before deployment.
"I have a production error. Here's the stack trace: [paste]. My dist files are in /path/to/dist. Retrace it, show me the code around the error, and tell me what's wrong."
The agent runs retrace_stack, then retrieve_code_context on the mapped location, and can finally read the actual TypeScript that crashed.
Works great alongside:
MIT