Forum Discussion
matkopajko
Nov 11, 2025Copper Contributor
Azure AI foundry projects
Hello, my use case: I need to be able to call my agent, which I created inside my azure ai foundry project. I have API route and also some API key, and the most crucial thing - agent id. ...
sannavajjala
Nov 12, 2025Copper Contributor
Hi,
You’re absolutely right, calling your Azure AI Foundry agent directly works fine using the project endpoint and API key.
The documentation emphasizes “authorization” because Azure supports two modes: API key based access for inference and Entra ID based access for management and enterprise controls.
For production, you wouldn’t expose your Foundry key to end users, instead, have your backend or API Management layer call the Foundry endpoint securely using either a Managed Identity or a stored API key in Key Vault. Your users then authenticate only to your app, while your backend communicates with the agent on their behalf this keeps things secure, scalable, and compliant. Hope this helps, I am available to assist if needed more information on this.