![]() |
VOOZH | about |
dotnet add package Microsoft.Agents.A365.Tooling.Extensions.AgentFramework --version 1.0.0
NuGet\Install-Package Microsoft.Agents.A365.Tooling.Extensions.AgentFramework -Version 1.0.0
<PackageReference Include="Microsoft.Agents.A365.Tooling.Extensions.AgentFramework" Version="1.0.0" />
<PackageVersion Include="Microsoft.Agents.A365.Tooling.Extensions.AgentFramework" Version="1.0.0" />Directory.Packages.props
<PackageReference Include="Microsoft.Agents.A365.Tooling.Extensions.AgentFramework" />Project file
paket add Microsoft.Agents.A365.Tooling.Extensions.AgentFramework --version 1.0.0
#r "nuget: Microsoft.Agents.A365.Tooling.Extensions.AgentFramework, 1.0.0"
#:package Microsoft.Agents.A365.Tooling.Extensions.AgentFramework@1.0.0
#addin nuget:?package=Microsoft.Agents.A365.Tooling.Extensions.AgentFramework&version=1.0.0Install as a Cake Addin
#tool nuget:?package=Microsoft.Agents.A365.Tooling.Extensions.AgentFramework&version=1.0.0Install as a Cake Tool
Microsoft Agent Framework integration for the Microsoft Agent 365 Tooling SDK. Provides MCP (Model Context Protocol) tool server discovery and registration for agents built with Microsoft.Extensions.AI and Microsoft.Agents.AI.
dotnet add package Microsoft.Agents.A365.Tooling.Extensions.AgentFramework
AddToolServersToAgent — builds an AIAgent with MCP tools loaded alongside any existing toolsGetMcpToolsAsync — returns discovered MCP tools as IList<AITool> for manual agent wiringSendChatHistoryAsync — forwards conversation history to the real-time threat-protection endpointaudience) receive audience-scoped OBO tokens automaticallyASPNETCORE_ENVIRONMENT=Developmentusing Microsoft.Agents.A365.Tooling.Extensions.AgentFramework.Extensions;
// Program.cs
builder.Services.AddMcpServices();
AddMcpServices() registers:
IMcpToolServerConfigurationService → McpToolServerConfigurationService (scoped)IMcpToolRegistrationService → McpToolRegistrationService (scoped)using Microsoft.Agents.A365.Tooling.Extensions.AgentFramework.Services;
using Microsoft.Agents.Builder.App.UserAuth;
using Microsoft.Extensions.AI;
public class MyActivityHandler : ActivityHandler
{
private readonly IMcpToolRegistrationService _mcpTools;
private readonly IChatClient _chatClient;
public MyActivityHandler(IMcpToolRegistrationService mcpTools, IChatClient chatClient)
{
_mcpTools = mcpTools;
_chatClient = chatClient;
}
protected override async Task OnMessageActivityAsync(ITurnContext<IMessageActivity> turnContext, CancellationToken cancellationToken)
{
var userAuth = turnContext.Activity.GetUserAuthorization();
var agent = await _mcpTools.AddToolServersToAgent(
chatClient: _chatClient,
agentInstructions: "You are a helpful assistant.",
initialTools: [],
agentUserId: turnContext.Activity.From.Id,
userAuthorization: userAuth,
authHandlerName: "default",
turnContext: turnContext);
var response = await agent.CompleteAsync(turnContext.Activity.Text, cancellationToken: cancellationToken);
await turnContext.SendActivityAsync(response.Message.Text, cancellationToken: cancellationToken);
}
}
IList<AITool> tools = await _mcpTools.GetMcpToolsAsync(
agentUserId: turnContext.Activity.From.Id,
userAuthorization: userAuth,
authHandlerName: "default",
turnContext: turnContext);
// From a list of ChatMessage objects
OperationResult result = await _mcpTools.SendChatHistoryAsync(chatMessages, turnContext, cancellationToken);
Token acquisition is automatic. The service uses the Agent Framework UserAuthorization and authHandlerName parameters to perform agentic OBO token exchange via AgenticMcpTokenProvider.
audience field, or audience matches the ATG App ID) — receive the shared ATG-scoped token.audience identifies a different application) — receive a token scoped to {audience}/{scope} or {audience}/.default.Set ASPNETCORE_ENVIRONMENT=Development (or DOTNET_ENVIRONMENT=Development). Tokens are read from environment variables instead of the OBO flow:
| Variable | Purpose |
|---|---|
BEARER_TOKEN_<SERVERNAME> |
Per-server token (hyphens in name replaced with underscores, uppercased) |
BEARER_TOKEN |
Shared fallback token for all servers |
Example: for a server named my-mcp-server, set BEARER_TOKEN_MY_MCP_SERVER.
| Variable | Purpose | Default |
|---|---|---|
ASPNETCORE_ENVIRONMENT or DOTNET_ENVIRONMENT |
Set to Development to enable dev mode |
— |
MCP_PLATFORM_ENDPOINT |
Override the Tooling Gateway base URL | https://agent365.svc.cloud.microsoft |
BEARER_TOKEN_<SERVERNAME> |
Dev-mode per-server Bearer token | — |
BEARER_TOKEN |
Dev-mode shared Bearer token fallback | — |
Microsoft, Windows, Microsoft Azure and/or other Microsoft products and services referenced in the documentation may be either trademarks or registered trademarks of Microsoft in the United States and/or other countries. The licenses for this project do not grant you rights to use any Microsoft names, logos, or trademarks. Microsoft's general trademark guidelines can be found at http://go.microsoft.com/fwlink/?LinkID=254653.
Copyright (c) Microsoft Corporation. All rights reserved.
Licensed under the MIT License - see the file for details.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 net8.0 is compatible. net8.0-android net8.0-android was computed. net8.0-browser net8.0-browser was computed. net8.0-ios net8.0-ios was computed. net8.0-maccatalyst net8.0-maccatalyst was computed. net8.0-macos net8.0-macos was computed. net8.0-tvos net8.0-tvos was computed. net8.0-windows net8.0-windows was computed. net9.0 net9.0 was computed. net9.0-android net9.0-android was computed. net9.0-browser net9.0-browser was computed. net9.0-ios net9.0-ios was computed. net9.0-maccatalyst net9.0-maccatalyst was computed. net9.0-macos net9.0-macos was computed. net9.0-tvos net9.0-tvos was computed. net9.0-windows net9.0-windows was computed. net10.0 net10.0 was computed. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
This package is not used by any NuGet packages.
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.1.13-preview | 43 | 6/12/2026 |
| 1.1.9-preview | 56 | 5/27/2026 |
| 1.1.8-preview | 51 | 5/26/2026 |
| 1.1.5-preview | 55 | 5/14/2026 |
| 1.0.0 | 659 | 5/1/2026 |
| 0.3.4-beta | 68 | 4/23/2026 |
| 0.2.152-beta | 77 | 4/13/2026 |
| 0.2.151-beta | 2,489 | 4/3/2026 |
| 0.2.144-beta | 74 | 3/25/2026 |
| 0.2.127-beta | 108 | 2/9/2026 |
| 0.2.118-beta | 156 | 1/24/2026 |
| 0.2.112-beta | 186 | 1/18/2026 |
| 0.1.75-beta | 434 | 11/19/2025 |
| 0.1.72-beta | 2,368 | 11/18/2025 |
See CHANGELOG.md for release notes.