Hey everyone, I'm building a bot using Azure AI Foundry that connects to Microsoft Teams, and I'm running into some trouble. The flow is supposed to work like this: a user asks a question in Teams, the Agent picks it up, which then triggers a Workflow I've built inside AI Foundry. Ultimately, the Workflow should return a response back to the user. I have the Agent set up and the Workflow created, but I'm puzzled about how to link them together. Specifically, I'm unsure about the following: where in the Agent settings I can attach the Workflow as a tool, how the Agent decides when to trigger the Workflow, and if the Workflow needs a specific trigger type to be callable by the Agent. I already understand how workflows can call agents for executing actions based on responses, but I need clarity on how to trigger the Workflow from the Agent call. I've been searching through the Microsoft documentation for hours, and it's not very clear. Any step-by-step guidance or direction to relevant resources would be greatly appreciated! Thanks in advance 🙏
2 Answers
You might want to check out the Microsoft Agent Framework. There are multiple ways for an agent to call a workflow, and it sounds like you’re looking for the 'handoff' feature. This should help you connect your bot more effectively!
Just to add, Agent Framework workflows and Foundry workflows share the same runtime, so they’re actually quite integrated!
There's a distinction between 'workflow' concepts in Foundry. The workflow you created is an orchestrator and calls agents, meaning you can't directly attach it as a tool. Instead, you need an Azure Logic Apps workflow. Once you create that, you can select it in Foundry’s setup by going to actions and adding it. This link might help you: https://learn.microsoft.com/en-us/azure/logic-apps/add-agent-action-create-run-workflow
Yes, I was checking out Azure Logic Apps just as you said! But we’re trying to figure out how to trigger a 'Foundry' workflow from an agent, so I appreciate your response!

Oh, interesting! I’ll look into that, thanks!