Study FAQ
How do I configure a Dataverse plug-in to access an Azure resource with managed identity v2?
Also asked as 2
- What trust and permissions does a Dataverse plug-in need to use Power Platform managed identity v2?
- How do I set up and verify outbound Azure access from a Dataverse plug-in using version 2 identity?
Answer
Configure Power Platform managed identity version 2 for the signed plug-in assembly or package, grant the workload principal the minimum access needed on the Azure resource, and request a token for that resource using IManagedIdentityService.AcquireToken. The Dataverse caller's permission to execute the operation remains a separate check. Set up Power Platform managed identity v2 · Dataverse custom API privileges
- In a development environment, provision a Microsoft Entra app registration or user-assigned managed identity, then sign and register the plug-in. Use a trusted-issuer certificate for production. Microsoft limits self-signed certificates to development or testing.
- Configure the federated credential for the correct environment and cloud. For a trusted-issuer certificate, version 2 uses SHA-256 Base64URL hashes of the exact full runtime
X509Certificate2.IssuerandSubjectstrings. Use the cloud-specific issuer, audience and subject format. - Create the Dataverse identity record with
version=2,credentialsource=2,subjectscope=1, and the matching application and tenant IDs. Associate it with the registered assembly or package and grant access at the resource. - Verify token acquisition and a real, permitted resource operation independently. For
AADSTS700213, compare the configured subject, environment, certificate and cloud settings. If token acquisition succeeds but the resource rejects the call, check the requested resource scope and its access policy. Microsoft's setup and validation procedure
Record the environment mapping and owner of certificate renewal. Validate a deliberately denied operation with the deployed workload identity before relying on the configuration.
Full explanation
AB-400: Custom APIs, Business Events and Plug-in Identity
Study guide · AB-400
Read the full explanation