Back to Home
nisalgunawardhana icon

How-To-Create-MCP-Server

Verified Safe

by nisalgunawardhana

Overview

This project demonstrates how to set up a basic Model Context Protocol (MCP) server in .NET for interaction with AI tools like Copilot Chat.

Installation

Run Command
dotnet run --project ${workspaceFolder}/HelloSriLankaServer/HelloSriLankaServer.csproj

Security Notes

The provided code for the MCP server is minimal and does not contain obvious security vulnerabilities like 'eval', obfuscation, or hardcoded secrets. It utilizes standard .NET hosting and Model Context Protocol libraries. The `WithToolsFromAssembly()` method allows loading tools dynamically from the assembly, meaning any custom, user-added tools could introduce risks if not carefully developed. The server primarily uses stdio transport, reducing direct network exposure for the sample.

Similar Servers

Stats

Interest Score44
Security Score9
Cost ClassLow
Stars38
Forks76
Last Update2026-01-11

Tags

.NETMCPAI ToolingServerCopilot Chat