mcp-csharp-debug

Diagnose C# MCP server tool discovery, protocol errors, and IDE debugging issues.

1|Updated May 21, 2026
One-click install
npx skills add https://github.com/1k-off/umbraco-observability-playground --skill mcp-csharp-debug-1k-off
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: mcp-csharp-debug
Source: https://github.com/1k-off/umbraco-observability-playground/tree/main/.agents/skills/mcp-csharp-debug
Command: npx skills add https://github.com/1k-off/umbraco-observability-playground --skill mcp-csharp-debug-1k-off

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Troubleshooting C# Model Context Protocol (MCP) servers is hard when tools fail to register, the IDE cannot attach, or the MCP protocol breaks due to incorrect stdio logging.

Core Features & Use Cases

  • Local run and transport setup: Run C# MCP servers via stdio or http, with transport detection guidance based on the MCP ASP.NET Core package reference.
  • IDE debugging workflows: Configure VS Code and Visual Studio for debugging, including breakpoints, launch profiles, and attach-to-process options.
  • Protocol-level validation: Test tools with MCP Inspector to confirm schemas, tool registration, and request/response behavior, then validate integration with GitHub Copilot Agent Mode.
  • Logging and troubleshooting guardrails: Prevent MCP JSON-RPC corruption by ensuring stdio servers never write logs to stdout, and diagnose common failure modes like garbled output, missing tool registration, and HTTP endpoint issues.

Quick Start

Run your C# MCP server locally and test its registered tools with MCP Inspector to confirm transport, schemas, and protocol messages are working end-to-end.

Frequently Asked Questions about mcp-csharp-debug

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

FAQPage Schema
Why is my C# MCP server outputting garbled JSON-RPC messages?

Garbled JSON-RPC messages occur when C# MCP servers using stdio transport write logs to stdout. Redirect all logging to stderr to prevent corrupting the protocol stream and breaking tool discovery.

How do I debug a C# MCP server that fails tool registration in GitHub Copilot Agent Mode?

Debug C# MCP server tool registration by running the server locally and using MCP Inspector to validate tool schemas and request behavior before confirming integration with GitHub Copilot Agent Mode.

How do I configure VS Code to attach breakpoints to a locally running C# MCP server?

Configure VS Code debugging for C# MCP servers by setting up launch profiles and using the attach-to-process option to hit breakpoints during local server execution.

How do I detect the correct transport for my C# MCP server?

Detect the correct transport for C# MCP servers by checking the MCP ASP.NET Core package reference to determine whether to configure stdio or HTTP transport in mcp.json.

Can I use MCP Inspector to validate HTTP endpoints for C# MCP servers?

Yes, MCP Inspector validates HTTP endpoint behavior and protocol messages for C# MCP servers, confirming that schemas and request/response cycles work correctly end-to-end.