mcp-dap
MCP server to communicate with DAP servers allowing AI Agents the ability to debug live programs.
claude mcp add --transport stdio go-delve-mcp-dap-server mcp-dap-server
How to use
The MCP DAP Server provides debugging capabilities via the Debug Adapter Protocol (DAP) exposed through the MCP framework. It acts as a bridge between MCP clients and DAP-compatible debuggers, allowing AI assistants and automated agents to start, control, and inspect debugging sessions programmatically. Core features include launching a debugging session in source, binary, or attach modes, managing breakpoints (line and function based), stepping and continuing execution, inspecting threads, stack traces, and variables, evaluating expressions, attaching to running processes, and viewing disassembly. The server communicates over standard input/output, enabling MCP clients to spawn it on demand and communicate through a simple request/response API.
To use it, run the MCP DAP Server as your executable in your MCP client configuration. The client will send commands (such as debug, breakpoint, evaluate, context, etc.) and receive structured context information when a session stops or at requested checkpoints. The server exposes a comprehensive toolset under a single debug tool, providing a unified interface for starting sessions, setting breakpoints, continuing or stepping through code, and querying full program state during debugging.
How to install
Prerequisites:
- Go 1.24.4 or newer
- A DAP-compatible debugger for your target language (e.g., Delve for Go)
Installation steps:
- Install Go from the official site or your package manager.
- Clone the repository and navigate into it: git clone https://github.com/go-delve/mcp-dap-server cd mcp-dap-server
- Build the MCP DAP Server binary: go build -o bin/mcp-dap-server
- Run the server directly or integrate it into your MCP workflow. For example: ./bin/mcp-dap-server
Tip: The server uses standard input/output (stdio) as its transport. In an MCP setup, clients will spawn this binary and communicate via the configured MCP transport channel.
Additional notes
Notes and tips:
- Transport: The server communicates over stdio. Ensure your MCP client is configured to spawn the binary and connect via stdio in the expected manner.
- Debugger prerequisites: You must have a DAP-compatible debugger installed for your target language (for Go, Delve is commonly used).
- Environment configuration: You can extend the server’s behavior via environment variables as needed by your deployment (e.g., to configure paths or integration hooks). The mcp_config entry supports an env object for per-server environment variables.
- Session lifecycle: Use the debug tool to start a session (source, binary, or attach). Use stop to terminate, and restart to reinitialize with new arguments. The context, stack, and variables are returned when the debug session stops.
- Breakpoints: You can set breakpoints by file:line or by function name. Combine with stopOnEntry or run-to-cursor options as needed.
Related MCP Servers
mcpcat-typescript-sdk
MCPcat is an analytics platform for MCP server owners 🐱.
hyperterse
The MCP framework. Connect your data to your agents.
symfony
A Symfony package designed for building secure servers based on the Model Context Protocol, utilizing Server-Sent Events (SSE) and/or StreamableHTTP for real-time communication. It offers a scalable tool system tailored for enterprise-grade applications.
mcp-framework
Rust MCP framework for building AI agents
tempo
An MCP ( Model Context Protocol ) Server for Grafana Tempo
mcp-document-converter
MCP Document Converter - A powerful MCP tool for converting documents between multiple formats, enabling AI agents to easily transform documents.