vs-mcp-debug

Controls the Visual Studio debugger via MCP to set breakpoints, inspect variables, and step through C# code.

1|Updated Mar 26, 2026
One-click install
npx skills add https://github.com/todevelopers/todevelopers-marketplace --skill vs-mcp-debug-todevelopers
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: vs-mcp-debug
Source: https://github.com/todevelopers/todevelopers-marketplace/tree/main/plugins/vs-mcp-client/skills/vs-mcp-debug
Command: npx skills add https://github.com/todevelopers/todevelopers-marketplace --skill vs-mcp-debug-todevelopers

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Debugging .NET applications requires manually driving the Visual Studio debugger, which interrupts AI-assisted workflows. This Skill lets an AI assistant attach to running processes, set breakpoints, inspect call stacks and locals, and step through C# code directly through the VS MCP Server. ## Core Features & Use Cases - Attach-Based Debugging: Attach the VS debugger to running local, Docker, or WSL processes, then pause, inspect, and detach without restarting the app. - Breakpoint and Exception Management: Set file/line or function breakpoints (pre-validated via Roslyn), configure break-on-exception, and list existing breakpoints. - Runtime Inspection and Modification: Read call stacks, drill into local variable trees with debug_evaluate, and modify values at runtime with immediate_execute. - Use Case: A unit test fails with a NullReferenceException. The AI sets a function breakpoint, asks you to run Debug Test in VS, polls until Break mode, then reads the call stack and locals to pinpoint the null value. ## Quick Start Ask the AI to attach the Visual Studio debugger to your running .NET process and inspect the variables at a breakpoint in your C# code.

Frequently Asked Questions about vs-mcp-debug

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I debug a running .NET process from an AI assistant?

Use debug_list_processes to find the running process, then debug_attach with the process name or PID. Once attached, call debug_break to pause, then debug_get_callstack and debug_get_locals to inspect state.

How do I debug a C# application running in a Docker container?

List processes with the Docker transport, then call debug_attach with transport "Docker (Linux Container)" and the container name as qualifier. The container needs vsdbg installed and a Debug build with PDB files for breakpoints to bind.

Can I launch a unit test in debug mode through the VS MCP Server?

No, tests cannot be launched in debug mode via MCP. Set breakpoints first, then ask the user to right-click the test and choose Debug Test in Visual Studio. The AI can inspect everything once the breakpoint hits.

Why does debug_get_locals return an error after starting a debug session?

Inspection tools only work in Break mode. debug_start and debug_attach return immediately while VS builds and launches in the background, so you must poll debug_get_mode until it reports Break before inspecting variables.

What is the difference between debug_evaluate and immediate_execute?

debug_evaluate is read-only and safe for inspecting expressions like object properties or LINQ queries. immediate_execute can modify program state, such as assigning variable values, so use it carefully when testing hypotheses at runtime.