A beginner-friendly Model Context Protocol (MCP) server built in C# that exposes calculator tools (add, multiply) and integrates seamlessly with Cline (VS Code) for AI tool invocation and debugging.
{
"mcpServers": {
"calculatormcpserver": {
"command": "<see-readme>",
"args": []
}
}
}No install config available. Check the server's README for setup instructions.
Are you the author?
Add this badge to your README to show your security score and help users find safe servers.
A beginner-friendly Model Context Protocol (MCP) server built in C# that exposes calculator tools (add, multiply) and integrates seamlessly with Cline (VS Code) for AI tool invocation and debugging.
Is it safe?
No package registry to scan.
No authentication — any process on your machine can connect.
MIT. View license →
Is it maintained?
Last commit 112 days ago.
Will it work with my client?
Transport: stdio. Works with Claude Desktop, Cursor, Claude Code, and most MCP clients.
No automated test available for this server. Check the GitHub README for setup instructions.
No known vulnerabilities.
This server is missing a description. Tools and install config are also missing.If you've used it, help the community.
Add informationHave you used this server?
Share your experience — it helps other developers decide.
Sign in to write a review.
Dynamic problem-solving through sequential thought chains
A Model Context Protocol server for searching and analyzing arXiv papers
An open-source AI agent that brings the power of Gemini directly into your terminal.
The official Python SDK for Model Context Protocol servers and clients
MCP Security Weekly
Get CVE alerts and security updates for CalculatorMcpServer and similar servers.
Start a conversation
Ask a question, share a tip, or report an issue.
Sign in to join the discussion.
A simple Model Context Protocol (MCP) server written in C# (.NET) that exposes calculator tools (add, multiply) and integrates with Cline (VS Code) for AI-driven tool execution.
This project demonstrates how AI models can securely invoke local C# tools using MCP.
add – Adds two numbersmultiply – Multiplies two numbersCline (VS Code)
|
| MCP Request
|
MCP Protocol
|
Calculator MCP Server (C#)
|
CalculatorTools.Add / Multiply
|
Result returned to AI


Adds two numbers together.
Parameters
a – First numberb – Second numberMultiplies two numbers.
Parameters
a – First numberb – Second numberCalculatorMcpServer/
├── CalculatorMcpServer/
│ ├── CalculatorMcpServer.csproj
│ ├── Program.cs
│ ├── CalculatorTools.cs
│ └── ...
├── README.md
├── Chat.png
└── my-csharp-server.png
Create the following file:
C:\Users\<your-user>\.cline\mcp.json
{
"mcpServers": {
"my-csharp-server": {
"command": "dotnet",
"args": [
"run",
"--project",
"C:/Users/Sandeep/source/repos/CalculatorMcpServer/CalculatorMcpServer/CalculatorMcpServer.csproj",
"--verbosity",
"quiet"
],
"timeout": 1800
}
}
}
📌 Notes:
/) for Windows paths/mcp in Clinedotnet run --project CalculatorMcpServer.csproj
Use the add tool with a=12 and b=30
Use the multiply tool with a=10 and b=20
[McpServerToolType]
public class CalculatorTools
{
[McpServerTool]
public static double Add(double a, double b)
{
Console.WriteLine($"Add called with a={a}, b={b}");
return a + b;
}
[McpServerTool]
public static double Multiply(double a, double b)
{
Console.WriteLine($"Multiply called with a={a}, b={b}");
return a * b;
}
}
MIT License