mcp-debug is a command-line tool for debugging MCP (Model Context Protocol) servers. It helps developers inspect MCP server capabilities, debug tool integrations, and test server notifications.
- Connect to any MCP Server: Works with servers using
streamable-httporssetransports. - Interactive REPL: Explore available tools, resources, and prompts interactively.
- MCP Server Mode: Acts as an MCP server itself, allowing integration with AI assistants like Cursor.
- Verbose Logging: Detailed logging of JSON-RPC messages for in-depth debugging.
- Self-Update: Keep the tool up-to-date with a single command.
- Shell Autocompletion: Generates autocompletion scripts for Bash, Zsh, Fish, and PowerShell.
To build the tool from source, run:
make buildThis will create the mcp-debug binary in the project directory.
For detailed instructions on modes, flags, and examples, please see the full usage guide:
Connect to a server and listen for notifications:
./mcp-debug --endpoint http://localhost:8090/mcpStart the interactive REPL:
./mcp-debug --replRun as an MCP server for AI assistant integration:
./mcp-debug --mcp-serverRefer to the usage guide for more advanced examples.
Contributions are welcome! Please open an issue or submit a pull request.
mcp-debug is licensed under the Apache 2.0 License.