The MCP C# SDK consists of three main NuGet packages, each designed for specific use cases. Choose the package that best fits your project’s requirements.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/modelcontextprotocol/csharp-sdk/llms.txt
Use this file to discover all available pages before exploring further.
Available Packages
ModelContextProtocol.Core
Core client and low-level server APIs with minimal dependencies
ModelContextProtocol
Main package with hosting and dependency injection extensions
ModelContextProtocol.AspNetCore
HTTP-based MCP server capabilities for ASP.NET Core
Package Details
ModelContextProtocol.Core
- MCP client implementation
- Low-level server APIs
- Core protocol types and utilities
- Minimal dependency footprint
ModelContextProtocol
- All features from
ModelContextProtocol.Core - Hosting extensions
- Dependency injection support
- Server builder APIs
This is the recommended package for most server implementations using stdio or other non-HTTP transports.
ModelContextProtocol.AspNetCore
- All features from
ModelContextProtocol - ASP.NET Core integration
- HTTP transport support
- SSE (Server-Sent Events) capabilities
Package Selection Guide
Use this decision tree to select the right package:I'm building an MCP client
I'm building an MCP client
Use ModelContextProtocol.Core for the minimal dependency footprint, or ModelContextProtocol if you need hosting and dependency injection features.
I'm building an MCP server with stdio transport
I'm building an MCP server with stdio transport
Use ModelContextProtocol for hosting and dependency injection support.
I'm building an HTTP-based MCP server
I'm building an HTTP-based MCP server
Use ModelContextProtocol.AspNetCore for full ASP.NET Core integration.
I need low-level APIs with minimal dependencies
I need low-level APIs with minimal dependencies
Use ModelContextProtocol.Core for the smallest footprint.
Version Compatibility
All three packages follow the same versioning scheme and are released together. When using multiple packages, ensure they are all on the same version to avoid compatibility issues.Next Steps
- Review the versioning policy to understand SDK updates
- Check the roadmap for upcoming features
- Read the contributing guide to contribute to the SDK