
A directory listing describing a cancellation-letter and mailing-address service. The configured public GitHub repository returned 404 during source verification.

A sample repository containing a local .NET MCP server exposing example tools, and a client that connects to MCP servers and converts MCP tools into Semantic Kernel functions for use with LLMs.
Local .NET MCP server demo with Semantic Kernel integration is cataloged as an MCP server attributed to liteobject. A sample repository containing a local .NET MCP server exposing example tools, and a client that connects to MCP servers and converts MCP tools into Semantic Kernel functions for use with LLMs. It is categorized under developer tools. See the capability inspector for recorded interfaces and their independent review status; consult upstream documentation for the current interface.
Installation configuration is not reviewed. No executable setup is offered for this entry; inspect the source repository before proceeding.
Catalog license label: Not specified. Check the source repository's current license and terms before using, modifying or distributing this software.
能力定义尚未审核。未核验的采集内容不会作为可信接口展示。
暂无可展示的已审核记录。这不表示上游不支持此能力。
暂无可展示的已审核记录。这不表示上游不支持此能力。
暂无可展示的已审核记录。这不表示上游不支持此能力。
Email delivery is not connected. This page does not collect email addresses or create subscriptions.
Browse the registry for current listings instead.
Reviews for Local .NET MCP server demo with Semantic Kernel integration are not available yet
Review publishing and storage are not connected. This page does not collect or publish ratings or comments, including after sign-in.
No; the demo uses stdio transport for all servers, starting them as subprocesses rather than exposing network endpoints.
The local server includes 23 example MCP tools organized by category.
No; the OpenAI API key is optional and only needed for Semantic Kernel integration.
README.md · 8501d3c85f76 · 采集于 2026-11-13 10:54:13 UTC
保留上游原文,不做 AI 改写。为安全起见过滤脚本、表单和不安全链接。
当前显示最后一次成功采集的文档快照,请以来源页面为准。
This repository demonstrates how to integrate Model Context Protocol (MCP) tools with Microsoft Semantic Kernel, enabling seamless interaction between AI models and external data sources or tools. By following this guide, you'll learn how to connect to an MCP server, convert MCP tools into Semantic Kernel functions, and leverage large language models (LLMs) for function calling—all within a reusable and extensible framework.
Note: Node.js is needed only for external MCP servers (GitHub, Everything) that are published as Node.js packages. The demo works perfectly with just the local .NET MCP server, avoiding Node.js dependencies entirely.
git clone https://github.com/LiteObject/mcp-with-semantic-kernel.git
cd mcp-with-semantic-kernel
dotnet restore
dotnet build
Set up your OpenAI API key for Semantic Kernel integration (this is optional):
dotnet user-secrets set "OpenAI:ApiKey" "your-api-key-here" --project src/Demo.MCP.Client
dotnet run --project src/Demo.MCP.Client
The application will:
For the simplest setup that doesn't require Node.js, the demo is pre-configured to use only the local .NET MCP server. Just run:
# The client (already configured to use local server)
dotnet run --project src/Demo.MCP.Client
The local server includes comprehensive testing tools (see Local MCP Server Tools section).
Once the client is running, try these commands:
> servers # List connected servers
> list local # List tools for local server
> call local Add {"a": 5, "b": 3} # Test calculator tool (note: case-sensitive "Add")
> call local Echo {"name": "World"} # Test echo tool (note: case-sensitive "Echo")
> call local GetDateTime {} # Get current time (no parameters needed)
> exit # Quit the application
Important Notes:
To test with GitHub and Everything servers, edit src/Demo.MCP.Client/appsettings.json to enable them. Important: Only change the "Enabled" property to true for each server you want to activate - do not replace the entire configuration objects.
Example change (see Configuration section for full server settings):
{
"McpServers": {
"github": {
"Enabled": true // Change this from false to true
// Keep all other properties unchanged
},
"everything": {
"Enabled": true // Change this from false to true
// Keep all other properties unchanged
},
"local": { "Enabled": true }
}
}
Then restart the client. This requires Node.js and internet access.
The Model Context Protocol (MCP) is an open-standard protocol designed to standardize how applications provide context to AI models. It acts as a universal connector, allowing LLMs to interact with diverse data sources (e.g., APIs, databases, or services) in a consistent way. Think of MCP as a bridge that enhances AI interoperability, flexibility, and contextual understanding.
In this project, we use MCP to expose tools that Semantic Kernel can consume, enabling AI-driven workflows with real-world applications like automation, data retrieval, or system integration.
Microsoft Semantic Kernel is a powerful SDK that simplifies building AI agents and orchestrating complex workflows. By integrating MCP tools, you can:
This repository provides a practical example of how to combine these technologies, complete with sample code to get you started.
src/
├── Demo.MCP.Client/ # MCP client application
│ ├── Configuration/ # Robust configuration system with validation
│ │ ├── AppConfig.cs # Main configuration class with smart loading
│ │ ├── McpServerConfig.cs # MCP server configuration with transport types
│ │ └── OpenAIConfig.cs # OpenAI/Semantic Kernel configuration
│ ├── Services/ # Business logic and MCP integration
│ │ ├── LoggingService.cs # Structured logging with Serilog
│ │ └── McpClientService.cs # MCP client with retry logic and error handling
│ ├── Program.cs # Main application with interactive demo
│ └── appsettings.json # Configuration for servers, logging, and OpenAI
└── Demo.MCP.Server/ # Local MCP server (.NET implementation)
├── Tools/ # 23 example MCP tools organized by category
│ ├── CalculatorTool.cs # Math operations (Add, Subtract, Multiply, etc.)
│ ├── EchoTool.cs # Simple echo functionality for testing
│ ├── FileSystemTool.cs # File operations (FileExists, ListFiles, etc.)
│ ├── SystemInfoTool.cs # System information and environment tools
│ └── TextProcessingTool.cs # Text manipulation (Base64, regex, etc.)
└── Program.cs # MCP server using stdio transport
This section walks you through the process of integrating MCP tools with Semantic Kernel, as implemented in this repository.
Clone this repository:
git clone https://github.com/LiteObject/mcp-with-semantic-kernel.git
cd mcp-with-semantic-kernel
Restore dependencies:
dotnet restore
Configure your OpenAI API key (optional - see Prerequisites for when this is needed):
dotnet user-secrets set "OpenAI:ApiKey" "your-api-key" --project src/Demo.MCP.Client
dotnet user-secrets set "OpenAI:ChatModelId" "gpt-4o" --project src/Demo.MCP.Client
The project includes code to connect to an MCP server using the ModelContextProtocol package. The MCP client retrieves available tools from the server, which can then be used by Semantic Kernel.
Conceptual example (actual implementation in src/Demo.MCP.Client/Services/McpClientService.cs):
using ModelContextProtocol;
var mcpConfig = new McpServerConfig
{
Id = "everything",
Name = "Everything",
TransportType = TransportType.Stdio,
Command = "npx",
Arguments = ["-y", "@modelcontextprotocol/server-everything"]
};
var mcpClient = await McpClientFactory.CreateAsync(mcpConfig);
var tools = await mcpClient.ListToolsAsync();
This snippet demonstrates the general pattern for establishing a connection to an MCP server (e.g., the "Everything" demo server) and fetching its available tools. The actual implementation includes additional error handling, retry logic, and configuration management.
The application uses a sophisticated configuration system with validation and smart path resolution:
The client automatically starts and manages the local MCP server using relative paths:
{
"McpServers": {
"local": {
"Id": "local",
"Name": "Local Demo Server",
"TransportType": "Stdio",
"Command": "dotnet",
"Arguments": ["run", "--project", "src/Demo.MCP.Server"],
"ConnectionTimeout": "00:00:30",
"MaxRetries": 3,
"Enabled": true
}
}
}
MCP supports different transport mechanisms for client-server communication. Understanding these options helps you choose the right configuration for your use case.
The default and most common transport for local MCP servers.
How it works: The client starts the server as a subprocess and communicates through stdin/stdout pipes.
Configuration example:
{
"TransportType": "Stdio",
"Command": "dotnet",
"Arguments": ["run", "--project", "src/Demo.MCP.Server"]
}
Use cases:
Advantages:
Limitations:
Network-based transport for remote MCP servers.
How it works: Client connects to a server exposed via HTTP endpoint.
Potential configuration:
{
"TransportType": "Http",
"Endpoint": "https://api.example.com/mcp"
}
Use cases:
Advantages:
Limitations:
Real-time bidirectional communication.
Use cases:
Inter-process communication on the same machine.
Use cases:
| Scenario | Recommended Transport | Why |
|---|---|---|
| Local development | Stdio | Simple, no configuration needed |
| Production server | HTTP/HTTPS | Scalable, standard infrastructure |
| Real-time features | WebSocket | Bidirectional communication |
| Windows service | Named Pipes | Native Windows IPC |
This demo uses Stdio transport for all servers:
dotnet runnpx commandnpx commandThe Stdio transport was chosen for simplicity and security, as it doesn't expose any network endpoints and works consistently across platforms.
Claim this server with your GitHub account to request manual ownership verification.
Link to the catalog listing for Local .NET MCP server demo with Semantic Kernel integration from your README. This badge does not certify ownership, compatibility or security.
[](https://awesome-mcp.com/servers/mcp-with-semantic-kernel)Public repository statistics could not be verified. Check the configured source address; unavailable counts are not zero.
来源、范围和时段分别列出;不相加,不代表安装人数、活跃用户或安全审核。
尚无已审核的包 / 镜像标识,暂不展示下载统计。
Alternative and complementary servers in the same category

A directory listing describing a cancellation-letter and mailing-address service. The configured public GitHub repository returned 404 during source verification.

A hosted MCP service for browsing and searching through Singapore mobile-network proxies.

A directory listing describing a Markdown-to-PDF service. The configured public GitHub repository returned 404 during source verification.