Knapcode.SampleMcpServer for VS Code
com.joelverhagen.mcp/knapcode.samplemcpserver
A sample MCP server using the MCP C# SDK. Generates random numbers and random weather.
client:VS Code
transport:stdio
runtime:nuget
Install Knapcode.SampleMcpServer in VS Code
.vscode/mcp.json
{
"inputs": [
{
"type": "promptString",
"id": "weather-choices",
"description": "WEATHER_CHOICES",
"password": true
}
],
"servers": {
"knapcode.samplemcpserver": {
"type": "stdio",
"command": "dnx",
"args": [
"Knapcode.SampleMcpServer",
"--yes"
],
"env": {
"WEATHER_CHOICES": "${input:weather-choices}"
}
}
}
}
VS Code prompts for each input the first time the server starts, so no secret is written to the file. VS Code docs