D365 FO UE to Azure Application Insights Connection Error

Ahmad "NPT" Mansoor 0 Reputation points
2025-11-24T09:44:02.6+00:00

Greetings,

I have a D365 FO environment deployed from PPAC, it has Telemetry feature enabled.

I have already deployed an Application Insights resource on Azure and setup the D365 env to connect to it:

User's image

But I am not seeing any activity and getting this error on Application Insights:

Unable to retrieve token. Error: invalid_scope. Error description: Principal is not authorized for requested scopes. {   "Principal": "finops-aos:e87ad95f-194e-e111-8982-",   "Context": "finops-env:e87ad95f-194e-e111-8982-"",   "RequestedScopes": [     "https://financeinsightsinitiatorservice.operations365.dynamics.com/.default"   ],   "UnauthorizedScopes": [     "https://financeinsightsinitiatorservice.operations365.dynamics.com/.default"   ] }. Error URI: . Correlation id: 872c1be8-59d1-0006-181a-dc87d159dc01 

I thought D365 and Azure would setup IAM automatically. Any guidance on this?

Azure Analysis Services
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Adam Zachary 2,025 Reputation points
    2025-11-25T03:07:08.8+00:00

    The error means D365 FO is trying to send telemetry to Application Insights using a scope it is not allowed to use. The principal finops-aos:<GUID> does not have permissions for the scope:

    https://financeinsightsinitiatorservice.operations365.dynamics.com/.default

    This happens when Telemetry in D365 FO is enabled, but Application Insights is not configured using the new Managed Identity model.

    What you need to do:

    Go to Azure → Application Insights → Access Control (IAM)

    Assign the following roles to the FO environment's managed identity (the “finops-aos:…” principal):

    • Monitoring Metrics Publisher
    • Application Insights Component Contributor

    Confirm the correct identity is listed in the D365 environment details in LCS/PPAC.

    1. Wait 5 - 10 minutes and try again.

    This resolves the invalid_scope issue because App Insights now trusts the FO environment’s managed identity.


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.