<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:media="http://search.yahoo.com/mrss/"><channel><title><![CDATA[Heiko Luxenhofer - DEVELOPERS.DE]]></title><description><![CDATA[Software Development Blog with focus on .NET, Windows, Microsoft Azure powered by daenet]]></description><link>https://developers.de/</link><image><url>https://developers.de/favicon.png</url><title>Heiko Luxenhofer - DEVELOPERS.DE</title><link>https://developers.de/</link></image><generator>Ghost 1.21</generator><lastBuildDate>Tue, 14 Apr 2026 01:47:03 GMT</lastBuildDate><atom:link href="https://developers.de/author/heiko/rss/" rel="self" type="application/rss+xml"/><ttl>60</ttl><item><title><![CDATA[Building Smarter Agents with Copilot Studio + Model Context Protocol (MCP)]]></title><description><![CDATA[<div class="kg-card-markdown"><h2 id="introduction">Introduction</h2>
<p>Integrating a custom Model Context Protocol (MCP) server with Copilot Studio agents opens up new possibilities for organizations leveraging Microsoft 365 Copilot and Teams. This article guides you through the process of creating, deploying, and extending an AI agent with specialized skills, using MCP and Copilot Studio as the</p></div>]]></description><link>https://developers.de/2025/10/16/building-smarter-agents-with-copilot-studio-model-context-protocol-mcp/</link><guid isPermaLink="false">68e904fa9afb880dd816c1d2</guid><category><![CDATA[AI]]></category><category><![CDATA[Model Context Protocol]]></category><category><![CDATA[MCP]]></category><category><![CDATA[Azure]]></category><category><![CDATA[Cloud]]></category><category><![CDATA[asp.net]]></category><dc:creator><![CDATA[Heiko Luxenhofer]]></dc:creator><pubDate>Thu, 16 Oct 2025 08:07:21 GMT</pubDate><media:content url="https://developersde.blob.core.windows.net/usercontent/2025/10/161014_post_image%201%201.png" medium="image"/><content:encoded><![CDATA[<div class="kg-card-markdown"><h2 id="introduction">Introduction</h2>
<img src="https://developersde.blob.core.windows.net/usercontent/2025/10/161014_post_image%201%201.png" alt="Building Smarter Agents with Copilot Studio + Model Context Protocol (MCP)"><p>Integrating a custom Model Context Protocol (MCP) server with Copilot Studio agents opens up new possibilities for organizations leveraging Microsoft 365 Copilot and Teams. This article guides you through the process of creating, deploying, and extending an AI agent with specialized skills, using MCP and Copilot Studio as the foundation. Whether you are a low-code enthusiast or a professional developer, you’ll find practical steps and insights to help you build robust, action-oriented agents tailored to your enterprise needs.</p>
<h2 id="understandingagenttypesincopilotstudio">Understanding Agent Types in Copilot Studio</h2>
<p>The diagram below illustrates the main types of agents you can build in Copilot Studio. Each type is tailored for specific tasks, ranging from answering questions and providing recommendations to executing automated actions and guiding users through processes. This simplified visual overview helps you quickly identify which agent type best fits your business.<br>
<img src="https://developersde.blob.core.windows.net/usercontent/2025/10/101311_agent_types.png" alt="Building Smarter Agents with Copilot Studio + Model Context Protocol (MCP)"><br>
In this post, we focus on the action-oriented agent type, which leverages an existing Azure DevOps MCP server implementation to extend capabilities and automate workflows. You can find the source code and deployment instructions for the MCP server in the following GitHub repository:<br>
<a href="https://github.com/heluxenhofer/mcp-server-azure-devops">https://github.com/heluxenhofer/mcp-server-azure-devops</a></p>
<h2 id="hostingyourmcpserverinazure">Hosting Your MCP Server in Azure</h2>
<p>To make your MCP server accessible to Copilot Studio agents, you first need to prepare your server code for deployment in Azure. Using the Azure Developer CLI, you can deploy your MCP server to an Azure Container App Environment. The process is straightforward: clone the example repository from GitHub, follow the instructions in the README, and configure your deployment. The resulting architecture includes managed identity, a container registry, Azure Key Vault, and Application Insights for monitoring. This setup ensures your MCP server is secure, scalable, and ready for enterprise use.<br>
<img src="https://developersde.blob.core.windows.net/usercontent/2025/10/13825_infrastructure.png" alt="Building Smarter Agents with Copilot Studio + Model Context Protocol (MCP)"></p>
<h2 id="agentwithmcpincopilotstudio">Agent with MCP in Copilot Studio</h2>
<p>Once your MCP server is running in Azure, the next step is to integrate it with Copilot Studio. Begin by manually configuring your agent in Copilot Studio, enabling generative AI orchestration mode to allow dynamic tool selection. For best results, disable general knowledge and web search features so your agent remains focused on its core tasks.<br>
When defining your agent’s instructions, clarity is key. For example, you might specify that your agent is an Azure DevOps assistant, designed to help developers perform specific tasks using Azure DevOps tools. The agent should be able to retrieve available MCP tools, summarize them for users, and guide them through actions such as creating new branches. It’s important to ensure the agent politely declines unrelated requests and maintains a friendly, engaging tone throughout interactions.<br>
Example instructions can be found in GitHub Repo <a href="https://github.com/heluxenhofer/mcp-server-azure-devops/blob/ac12db18f7cf5b9af95fbc77d3c400c65e47e596/docs/copilotstudio_instructions.md">here</a>.<br>
<strong>Tip</strong>: Take care to name referenced tools in your instructions like in configuration.<br>
If you aren`t familiar with creating agents in Copilot Studio, just follow instructions on Microsoft documentation <a href="https://learn.microsoft.com/en-us/microsoft-copilot-studio/fundamentals-get-started">Quickstart: Create and deploy an agent - Microsoft Copilot Studio | Microsoft Learn</a>.</p>
<h3 id="monitoringandinsights">Monitoring and Insights</h3>
<p>Monitoring is essential for maintaining high-quality, production-ready agents. Azure Application Insights provides comprehensive visibility into both your MCP server and Copilot Studio agents. By integrating Application Insights, you can track performance metrics, user interactions, and potential issues, enabling continuous improvement and reliable operation.  Application Insights can be set up under Settings-Advanced</p>
<h3 id="integratingthemcptoolincopilotstudio">Integrating the MCP Tool in Copilot Studio</h3>
<h4 id="initiatingthemcptoolintegration">Initiating the MCP Tool Integration</h4>
<p>Begin by opening your agent configuration in Copilot Studio and selecting the option to add a new tool. Choose “Model Context Protocol (MCP)” as the integration type. The onboarding wizard will guide you through the required steps. For a comprehensive walkthrough, refer to the official documentation:<br>
<a href="https://learn.microsoft.com/en-us/microsoft-copilot-studio/mcp-add-existing-server-to-agent">https://learn.microsoft.com/en-us/microsoft-copilot-studio/mcp-add-existing-server-to-agent</a></p>
<h4 id="configuringthemcpserverendpoint">Configuring the MCP Server Endpoint</h4>
<p>During setup, you will be prompted to provide the endpoint of your MCP server. For this post, the integration leverages an existing Azure DevOps MCP server implementation, available at:<br>
<a href="https://github.com/heluxenhofer/mcp-server-azure-devops">https://github.com/heluxenhofer/mcp-server-azure-devops</a><br>
Ensure your MCP server is deployed and accessible from the Copilot Studio environment, see section <a href="#Hosting-Your-MCP-Server-in-Azure">Hosting</a>.</p>
<h4 id="settingupsecureauthentication">Setting Up Secure Authentication</h4>
<p>Security is essential when integrating enterprise tools. Select Microsoft Entra ID (OAuth 2.0) as the authentication method. You will need to enter the Client ID, Client Secret, Authorization URL, Token / Refresh URL and the required scopes from your Azure Entra ID App Registration. You can use existing App Registration which was created for MCP-Server, described in <a href="https://github.com/heluxenhofer/mcp-server-azure-devops">GitHub Repository</a>.<br>
<strong>Tip</strong>: You can find these endpoints in the Azure portal under Azure Active Directory → App registrations → [Your App] → Overview → Endpoints.<br>
<img src="https://developersde.blob.core.windows.net/usercontent/2025/10/1390_Mcp_wizard.png" alt="Building Smarter Agents with Copilot Studio + Model Context Protocol (MCP)"></p>
<ul>
<li>Set the “Authorization URL” to the value labeled OAuth 2.0 authorization endpoint (v2).</li>
<li>Set the “Token URL” and “Refresh URL” to the value labeled OAuth 2.0 token endpoint (v2).</li>
<li>Scopes are defined under Expose an API in your App Registration.</li>
</ul>
<p>After completing these fields, Copilot Studio will generate a Redirect URL. Add this URL to your registered app’s Redirect URIs in Azure Entra ID to enable the authorization flow.<br>
<img src="https://developersde.blob.core.windows.net/usercontent/2025/10/1390_mcp_redirecturl.png" alt="Building Smarter Agents with Copilot Studio + Model Context Protocol (MCP)"></p>
<h4 id="finalizingandvalidatingtheintegration">Finalizing and Validating the Integration</h4>
<p>Once configuration is complete, Copilot Studio will prompt you to authenticate using your Entra ID credentials. Open the Connections Manager if necessary, verify your credentials, and reauthenticate as needed. After successful authentication, your agent will be able to invoke MCP tools for Azure DevOps automation.<br>
It is recommended to validate the integration using Copilot Studio’s Test pane. Enter prompts that trigger MCP tool actions and confirm that your agent can successfully connect and perform the intended operations.<br>
<img src="https://developersde.blob.core.windows.net/usercontent/2025/10/131059_agent_testing.png" alt="Building Smarter Agents with Copilot Studio + Model Context Protocol (MCP)"></p>
<h4 id="publishingandsharingyouragent">Publishing and Sharing Your Agent</h4>
<p>With your agent configured and authenticated, you’re ready to publish it in Copilot Studio. Add channels such as Microsoft Teams to make your agent accessible across your organization. Before rolling out the agent company-wide, test it in your chosen channels to ensure everything works as expected. Copilot Studio’s publishing workflow makes it easy to manage availability and distribution, supporting both targeted testing and broad deployment.<br>
<img src="https://developersde.blob.core.windows.net/usercontent/2025/10/13110_agent_publish.png" alt="Building Smarter Agents with Copilot Studio + Model Context Protocol (MCP)"><br>
Read more about publishing and deploying your agent on Microsoft documentation.<br>
<a href="https://learn.microsoft.com/en-us/microsoft-copilot-studio/publication-fundamentals-publish-channels?tabs=web">Key concepts - Publish and deploy your agent - Microsoft Copilot Studio | Microsoft Learn</a></p>
<p>After publishing the agent and adding channels, you can try out your agent in Microsoft Teams by clicking on “Availability options” and copy / paste the link into your browser and try your agent inside Microsoft Teams.<br>
<img src="https://developersde.blob.core.windows.net/usercontent/2025/10/13111_teams_testing.png" alt="Building Smarter Agents with Copilot Studio + Model Context Protocol (MCP)"><br>
<strong>Note</strong>: At the time of writing this post, there might be a bug when clicking on “See agent in Teams” and agent wasn`t working in Teams chat like expected. Click on “Availability options” and copy link to test agent instead.</p>
<h2 id="summary">Summary</h2>
<p>Integrating a custom MCP server with Copilot Studio enables organizations to build powerful, action-oriented AI agents that streamline workflows and enhance productivity. By leveraging Azure Container Apps for hosting and Copilot Studio’s orchestration and authentication features, teams can deploy scalable, secure, and flexible solutions tailored to their business needs.</p>
<h2 id="bestpracticesrecommendations">Best Practices &amp; Recommendations</h2>
<ul>
<li>Use separate environments for development, testing, and production in Copilot Studio to ensure stability and manage changes effectively.</li>
<li>Design agents with clear objectives and leverage built-in topics for extensibility.</li>
<li>Implement additional security measures for your MCP server in production, such as restricting access and monitoring usage.</li>
<li>Set up CI/CD pipelines for automated deployments and updates.</li>
<li>Regularly monitor agent performance and collect user feedback to continuously refine capabilities and address potential issues.</li>
</ul>
<h2 id="references">References</h2>
<p>GitHub Repository custom MCP Server: <a href="https://github.com/heluxenhofer/mcp-server-azure-devops">https://github.com/heluxenhofer/mcp-server-azure-devops</a><br>
Copilot Studio Documentation: <a href="https://learn.microsoft.com/en-us/microsoft-copilot-studio/">https://learn.microsoft.com/en-us/microsoft-copilot-studio/</a><br>
Model Context Protocol Integration: <a href="https://learn.microsoft.com/en-us/microsoft-copilot-studio/agent-extend-action-mcp">https://learn.microsoft.com/en-us/microsoft-copilot-studio/agent-extend-action-mcp</a><br>
Azure Container App Deployment: <a href="https://learn.microsoft.com/en-us/azure/developer/ai/build-mcp-server-ts">https://learn.microsoft.com/en-us/azure/developer/ai/build-mcp-server-ts</a><br>
Authentication with Entra ID: <a href="https://learn.microsoft.com/en-us/microsoft-copilot-studio/configuration-authentication-azure-ad">https://learn.microsoft.com/en-us/microsoft-copilot-studio/configuration-authentication-azure-ad</a></p>
</div>]]></content:encoded></item><item><title><![CDATA[Building AI-Ready, Discoverable Tools with Model Context Protocol (MCP) in .NET 9 & C#]]></title><description><![CDATA[Learn how to implement Model Context Protocol (MCP) in .NET 9 and C#. Build discoverable, schema-driven tools for AI assistants, automation, and DevOps workflows. This guide covers benefits, architecture, elicitation, and a quick start to future-proof your integrations.]]></description><link>https://developers.de/2025/08/26/model-context-protocol-mcp-with-net-9/</link><guid isPermaLink="false">68ad9c37ca9a670b48eb5c3a</guid><category><![CDATA[AI]]></category><category><![CDATA[.NET Core]]></category><category><![CDATA[MCP]]></category><category><![CDATA[Model Context Protocol]]></category><category><![CDATA[LLM]]></category><dc:creator><![CDATA[Heiko Luxenhofer]]></dc:creator><pubDate>Tue, 26 Aug 2025 12:13:41 GMT</pubDate><media:content url="https://developersde.blob.core.windows.net/usercontent/2025/8/26126_mcp-diagram.png" medium="image"/><content:encoded><![CDATA[<div class="kg-card-markdown"><img src="https://developersde.blob.core.windows.net/usercontent/2025/8/26126_mcp-diagram.png" alt="Building AI-Ready, Discoverable Tools with Model Context Protocol (MCP) in .NET 9 & C#"><p>This article presents a hands-on showcase of the Model Context Protocol (MCP) implemented with .NET and C#. See how MCP can be used to expose, discover, and orchestrate server-side tools in a standardized way—making integration smarter, more flexible, and ready for modern automation scenarios.</p>
<h1 id="introduction">Introduction</h1>
<p>Ever wondered how to make your tools and services more discoverable, interoperable, and easy to automate? MCP (Model Context Protocol) is designed for exactly that. In this showcase project, we use .NET and C# to demonstrate how MCP can turn ordinary APIs into intelligent, composable tools—ready for integration with clients, AI assistants, and automation platforms.</p>
<h2 id="whatismcp">What is MCP?</h2>
<p>MCP (Model Context Protocol) is an open protocol for exposing server-side operations as standardized, discoverable tools. According to the <a href="https://modelcontextprotocol.io/docs/getting-started/intro">official MCP specification</a>, MCP enables clients—such as developer tools, automation platforms, or AI assistants—to dynamically discover available operations, understand their input/output schemas, and invoke them in a consistent way.<br>
The diagrams below illustrate the difference between integrating APIs with and without MCP. This illustration alone demonstrates the advantages of using MCP.<br>
<img src="https://developersde.blob.core.windows.net/usercontent/2025/8/261146_rest-api-diagram.png" alt="Building AI-Ready, Discoverable Tools with Model Context Protocol (MCP) in .NET 9 & C#"><em>Integration of existing APIs without MCP</em><br>
<img src="https://developersde.blob.core.windows.net/usercontent/2025/8/261148_mcp-diagram.png" alt="Building AI-Ready, Discoverable Tools with Model Context Protocol (MCP) in .NET 9 & C#"><em>Integration of existing APIs with MCP</em></p>
<h3 id="benefitsofusingmcp">Benefits of Using MCP</h3>
<ul>
<li><strong>Discoverability</strong>: Clients can query the server to list all available tools and their capabilities, reducing the need for hardcoded API knowledge.</li>
<li><strong>Interoperability</strong>: MCP provides a common language for tools and clients, making integration across platforms and technologies straightforward.</li>
<li><strong>Extensibility</strong>: New tools and operations can be added to the server without breaking existing clients.</li>
<li><strong>Schema Transparenc</strong>y: Each tool exposes its input and output schema, enabling robust validation and easier client development.</li>
<li><strong>Security</strong>: MCP supports modern authentication and authorization mechanisms, such as OAuth 2.0 and Microsoft Entra ID.</li>
<li><strong>Automation &amp; AI Readiness</strong>: MCP is designed for orchestration by automation scripts and AI agents, supporting conversational and intelligent workflows.</li>
</ul>
<h3 id="elicitationwithmcpinteractiveuserworkflows">Elicitation with MCP: Interactive User Workflows</h3>
<p>A unique feature of MCP is its support for elicitation—interactive user input collection. In this project, elicitation is used to prompt users for required information (e.g., selecting a parent branch when creating a new branch). The MCP server sends a schema describing the expected input, and the client (or LLM) collects the user’s response, ensuring a guided and error-resistant workflow.<br>
Example json request/response with using an enum schema:</p>
<pre><code class="language-json">{
    &quot;type&quot;: &quot;object&quot;,
    &quot;properties&quot;: {
        &quot;ParentBranch&quot;: {
            &quot;type&quot;: &quot;string&quot;,
            &quot;enum&quot;: [
                &quot;main&quot;
            ]
        }
    },
    &quot;required&quot;: [
        &quot;ParentBranch&quot;
    ]
}
</code></pre>
<p><em>Request schema</em></p>
<pre><code class="language-json">{
    &quot;action&quot;: &quot;accept&quot;,
    &quot;content&quot;: {
        &quot;ParentBranch&quot;: &quot;main&quot;
    },
    &quot;_meta&quot;: null
}
</code></pre>
<p><em>Response schema</em></p>
<p>This approach makes user interaction smarter and more flexible, allowing for dynamic, context-aware prompts and responses.</p>
<h2 id="architectureoverview">Architecture Overview</h2>
<p>This showcase project on <a href="https://github.com/heluxenhofer/mcp-server-azure-devops">GitHub</a> is built with .NET 9 and C#, using MCP to abstract a set of Azure DevOps operations as MCP tools. The diagram below illustrates the key components and their interactions:</p>
<ul>
<li><strong>MCP Server</strong>:  Hosts the MCP tools and exposes a standardized discovery endpoint. Implements authentication via Microsoft Entra ID.</li>
<li><strong>MCP Tools</strong>: Each tool represents a server-side operation (e.g., create branch, list repositories). Tools expose input/output schemas for validation and interoperability. Requests operations to Azure DevOps REST API.</li>
<li><strong>Client/LLM</strong>: Discovers available tools dynamically and invokes them using the MCP protocol. Supports elicitation for interactive workflows.</li>
<li><strong>Authentication Layer</strong>:  Uses OAuth 2.0 and Entra ID for secure access control. Uses on-behalf-flow for accessing Azure DevOps REST API.</li>
</ul>
<p><img src="https://developersde.blob.core.windows.net/usercontent/2025/8/261154_architecture.png" alt="Building AI-Ready, Discoverable Tools with Model Context Protocol (MCP) in .NET 9 & C#"><em>Components of current architecture</em></p>
<h2 id="technicalimplementation">Technical Implementation</h2>
<p>This project is a practical demonstration of MCP’s power when combined with .NET and C#:</p>
<ul>
<li><strong>Modern</strong> .NET: Built with .NET 9 for reliability and performance.</li>
<li><strong>C# Best Practices</strong>: Clean, maintainable code that’s easy to extend.</li>
<li><strong>MCP Tooling</strong>: Azure DevOps operations are exposed as MCP tools, with clear schemas and discoverable endpoints.</li>
<li><strong>Secure by Design</strong>: Authentication via Entra ID and secure configuration management. Using on-behalf authentication flow for accessing Azure DevOps REST API in a secure way.</li>
</ul>
<p>More technical details, instructions and examples can be found in <a href="https://github.com/heluxenhofer/mcp-server-azure-devops/blob/main/README.md">readme</a> file of <a href="https://github.com/heluxenhofer/mcp-server-azure-devops">GitHub project</a></p>
<h2 id="whytrymcpwithnetandc">Why Try MCP with .NET and C#?</h2>
<p>If you’re a developer, architect, or automation enthusiast, this showcase is for you. MCP makes it easy to build smarter, more flexible integrations—whether you’re connecting tools, enabling AI, or future-proofing your APIs. With .NET and C#, you get a robust, enterprise-ready foundation for your MCP server.</p>
<h2 id="references">References</h2>
<p><a href="https://github.com/heluxenhofer/mcp-server-azure-devops">Project GitHub Repository</a><br>
<a href="https://github.com/modelcontextprotocol/csharp-sdk">MCP C# SDK</a><br>
<a href="https://github.com/modelcontextprotocol/modelcontextprotocol">MCP GitHub (Official)</a><br>
<a href="https://modelcontextprotocol.io/docs/getting-started/intro">MCP Specification</a></p>
</div>]]></content:encoded></item></channel></rss>