Forum Discussion
need help on list of Azure entra id groups associated for the appid / registered application
- Aug 15, 2024
Hello againvenkatchandra2024 !
If you run the following instead then you will get the Name of the group or user that is assigned to the application in a nice list 🙂
Connect-MgGraph -Scope "Application.Read.All" $ServicePrincipalId = "<YourEnterpriseAppObjectID>" Get-MgServicePrincipalAppRoleAssignedTo -ServicePrincipalId $ServicePrincipalId | select PrincipalDisplayName, PrincipalTypeSo all you need to edit is the last command. And your output will look like this
Let me know how it goes!
Kind Regards
Oliwer Sundgren
oliwer_sundgren Thank you for the response, I will try through Rest.
I am still wanting to write PowerShell program using Azure graph due to access issues
No problem venkatchandra2024 hope it helps 🙂
If you want to do it with a Graph Powershell cmdlet then you could try the following
$ServicePrincipalId = "<YourEnterpriseAppObjectID>"
Get-MgServicePrincipalAppRoleAssignedTo -ServicePrincipalId $ServicePrincipalId
If this works for you feel free to mark my response as "Best response"
Cheers
Oliwer Sundgren