AI-103 Practice Question 11: Least Privilege Agent Role
Microsoft Azure AI Apps and Agents Developer Associate (AI-103) · Test 2 · question 1 of 10
An order-management microservice needs to call a published prompt agent's endpoint in a Microsoft Foundry project. Security review requires that the service principal be able to do nothing else: it must not create, update or delete agents, must not read project or resource configuration, and must not be able to assign roles. The platform team wants a built-in role rather than a custom one, scoped as narrowly as the role supports.
Which role assignment meets the requirement?
Show answer and explanation
Answer:
Foundry Agent Consumer is the least-privilege role in the Foundry built-in role table: it is the only role whose sole permission is *interact with agent endpoints*. It cannot create projects or accounts, cannot perform data actions, cannot complete role assignments, and does not even carry reader access. The CLI detail matters too; the Azure portal currently supports assigning Foundry Agent Consumer only at the account scope, so assigning it at project (or individual agent) scope has to be done with az role assignment create.
- A is wrong because Foundry User adds reader access to the project and resource *and* the data actions used to build and develop agents. It is the least-privilege role for a developer, not for a caller that only invokes an endpoint. - C is wrong because Foundry Project Manager is far broader: it can build in the project, publish agents, and conditionally assign the Foundry User role to other principals. - D is wrong because Microsoft explicitly says not to assign roles beginning with *Cognitive Services* for Foundry scenarios; those roles target Azure AI services resources directly and don't map to Foundry project permissions.