Aspire.MCP.Sample MCP Server

Sample MCP Server and MCP client with Aspire

Local serverstdio

What is the Aspire.MCP.Sample MCP server?

Connect Aspire.MCP.Sample to Claude, Cursor or any other MCP client and it stops being a tab you switch to. Sample MCP Server and MCP client with Aspire. The aspire.mcp.sample mcp server is what makes that connection.

What the server does

This sample demonstrates a Model Context Protocol (MCP) Server and client setup using Aspire. It showcases how to establish and manage MCP communication, using C# in a structured Aspire environment.

  • Aspire Integration: — Uses Aspire for containerized orchestration and service management
  • MCP Server: — Implements an MCP server to manage client communication
  • MCP Client: — Sample Blazor Chat client demonstrating how to connect and communicate with the MCP server
  • Model Selection: — The Chat Client can use LLMs from Azure AI Foundry, Ollama or GitHub models. The selected model must support function calling to be able to call the MCP server functions
  • Function Calling: — Demonstrates how to call functions from the MCP server using the selected model
  • Tool Result: — Displays the result of the function call in the chat interface

Available tools

The toolset is worth reading before you wire it up, because it tells you what the integration is really for:

  • Prerequisites — The Prerequisites tool exposed by this server

Installation

Setup follows the usual MCP pattern — install or clone the server, register it in your client's configuration file, restart the client.

Credentials and setup notes

  • .NET SDK 9.0 or later - Visual Studio 2022 or Visual Studio code - LLM or SLM that supports function calling. - Azure AI Foundry to run models in the cloud. IE: gpt-4o-mini - GitHub Models to run models in the cloud. IE: gpt-4o-mini - Ollama for running local models. Suggested: phi4-mini, llama3.2 or Qwq

Where it fits

Among the cloud and infrastructure options, the useful question is rarely "what can it do" but "what does it cost you to run" — permissions, credentials, and how much of your context its toolset consumes. Aspire.MCP.Sample's toolset — Prerequisites — is a fair guide to whether it matches your workflow. It is maintained by elbruno; worth a glance at recent repository activity before you build anything load-bearing on it.

SyncDev reviews every entry in this directory against the project's own documentation before publishing, and revisits them as servers change.

Worth knowing first

  • It runs with your machine's permissions. That is convenient and also the reason to think about what you point it at before you approve a tool call.
  • Keep per-call confirmation enabled while you learn its behaviour; it is the cheapest safeguard you have.

Available tools

ToolWhat it does
PrerequisitesThe Prerequisites tool exposed by this server.

Configuration

  • .NET SDK 9.0 or later - Visual Studio 2022 or Visual Studio code - LLM or SLM that supports function calling. - Azure AI Foundry to run models in the cloud. IE: gpt-4o-mini - GitHub Models to run models in the cloud. IE: gpt-4o-mini - Ollama for running local models. Suggested: phi4-mini, llama3.2 or Qwq

Example prompts to try

  • Use Aspire.MCP.Sample to Prerequisites.

Frequently asked questions

You need .NET SDK 9.0 or later, Visual Studio 2022 or Visual Studio Code, and an LLM/SLM that supports function calling (Azure AI Foundry, GitHub Models, or Ollama).