Penstock is an open source MCP proxy written in Go for debugging Model Context Protocol tool calls in Claude Desktop, Cursor, and Codex. It captures every MCP tool call, explains why calls fail, and replays captured requests without re-running the whole agent. Features include live watch mode, failure diagnosis, request replay, NDJSON audit logs, deny policies, rate limiting, log redaction, and per-tool latency stats. Single static binary with no runtime dependencies. Works with Claude Desktop, Cursor, Codex, and any MCP client.

v0.1.0  ·  Go  ·  Apache 2.0

Claude says your MCP
tool failed. Find out why.

You can't console.log an MCP server — stdout is the protocol. So when your agent silently fails, calls the wrong tool, or crashes upstream, you have no idea what happened. Penstock captures everything and tells you exactly what broke.

penstock — 80×24
$ penstock watch 11:42:03 filesystem read_file 11ms OK 11:42:08 filesystem read_file 4ms ERR ^C $ penstock explain --last likely cause: The upstream MCP stream emitted malformed JSON-RPC. why: The error text points at invalid JSON or a bad frame. fix: Move server logs to stderr — stdout is reserved for MCP. error: invalid character 'D' looking for beginning of value # fix the server, then replay without re-running the whole agent $ penstock replay --last OK 3ms via filesystem result: {"content":[{"type":"text","text":"hello from /tmp/config.yaml"}]} $

INSTALL

go install github.com/penstockhq/penstock/cmd/penstock@latest

single binary  ·  no runtime dependencies  ·  no Go? download a binary for macOS · Linux · Windows