my-first-mcp-server

luzemin/my-first-mcp-server

3.1

If you are the rightful owner of my-first-mcp-server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

C# .NET 9.0 Console Application for local MCP Server

项目介绍

C# .NET 9.0 Console Application for local MCP Server

项目修改

使用VS 或者 Rider 打开项目

发布(包含运行时的exe文件)

dotnet publish /p:PublishSingleFile=true -c Release -r win-x64 --self-contained true

Docker 部署

cd C:\workspace\git\cbi.cmt.mcp
docker build -t local-mcp-server .

docker run -itd -p 8092:8080 --name mcp-server local-mcp-server

C# SDK

https://github.com/modelcontextprotocol/csharp-sdk

配置(以CherryStudio为例)

1. 下载客户端

https://www.cherry-ai.com/download

2. 配置LLM(申请密钥)

配置LLM

3. 配置MCP

配置MCP 配置MCP

3.1 配置开发中的项目

配置MCP

3.2 配置发布后的exe

配置MCP

3.3 配置http sse

配置MCP

3.3 Token

  1. Jenkins不需要token
  2. Gitlab Token 申请: http://gitlab.chinacbi.com.cn/profile/personal_access_tokens
  3. Jira、Confluence Token:Base64(用户名:密码)

使用

示例

配置MCP

敏感操作

对于一些带有副作用的操作,比如Jenkins的部署,因为模型的能力差异或者模型温度的设置,有的模型会对用户的输入进行自动修正和重试执行。

请在MCP配置中将“自动批准”设置为“否” 配置MCP