GitHunt
MA

madsbolaris/a2a-agent-service

Shows how to access an Azure AI Foundry Agent Service agent with A2A

A2A-Demo

This is a simple test app demonstrating how to call an Azure AI Foundry Agent Service agent using the A2A (Agent-to-Agent) protocol.

The app sends a message to a configured agent endpoint and prints the response. It is intended for internal testing purposes only.

Caution

The service often returns a 500 error; this is being investigated.
In the meantime, use this tunnel as the endpoint URL: https://khbc19mq-5000.usw2.devtunnels.ms/workflows/a2a/v1.0/subscriptions/921496dc-987f-410f-bd57-426eb2611356/resourceGroups/ai-agents-karthik-eu/providers/Microsoft.MachineLearningServices/workspaces/project-demo-eu-fw7g/agents/asst_gzaBKcQzu4G7Dx5FxT6Pk9Wk


๐Ÿ› ๏ธ Prerequisites

  1. .NET 8 SDK
  2. Azure CLI
  3. Access to the A2AProtocolHttpClient libraries (A2A.* packages)

๐Ÿ” Authentication

Before running this app, you must log in to Azure using the following test identity:

az login -u AdeleV@M365x63883554.OnMicrosoft.com

๐Ÿ’ฌ Note: Reach out to Mads Bolaris to obtain the password for this test account.


โ–ถ๏ธ Running the App

Option 1: From VS Code

  1. Open the project in VS Code
  2. Use the preconfigured launch settings in .vscode/
  3. Press F5 to build and run in debug mode

Option 2: Manually from Terminal

dotnet build
dotnet run

๐Ÿ’ฌ Example Output

The app sends a simple message ("Hi there how are you?") to the agent and prints the response parts:

Agent> I'm doing well, thank you! How can I assist you today?


๐Ÿ“ Project Structure

A2A-DEMO/

  • Program.cs โ€” Main entry point
  • a2a-demo.csproj โ€” Project file
  • a2a-demo.sln โ€” Solution file
  • .vscode/ โ€” VS Code launch and build configs
  • README.md โ€” You're here
madsbolaris/a2a-agent-service | GitHunt