Reverse engineering Claude Code • Kir Shatrov
I’ve been curious about what happens inside Claude Code so I’ve spent a couple hours digging through prompts that it sends back to Anthropic.
As I’ve been going through that, I’ve gathered some insights why Claude Code is often slower and more expensive than other tools like Cursor.
Capturing prompts
It turned out a lot easier than I thought, thanks to mitmproxy:
$ brew install mitmproxy
$ mitmweb --mode reverse:https://api.anthropic.com --listen-port 8000
$ ANTHROPIC_BASE_URL=http://localhost:8...
Read more at kirshatrov.com