Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago

Use column from Table A and generate response in Table B

I am new to Power BI and trying to setup a security dashboard for Azure AD. Here is what I want to (I'm not sure if this can be done)

 

I need to pull all role definitions in Azure AD using https://graph.microsoft.com/beta/$metadata#roleManagement/directory/roleDefinitions which I have in Table A (this part is done). Now I want to see the role assignments for each role definition. For example, I want to filter for Exchange Administrators or Global Administrator.

 

To get role assignment we can use GET /roleManagement/directory/roleAssignments?$filter=roleDefinitionId eq '{roleDefinition id}' in graph API which requires the role definition to be passed to the query. Now that I have role definition ID in Table A, how can I make queries for each ID against the role assignment API and get that in a table. As of now, I have this solution written in PowerShell which generates an Excel sheet and updates the Power BI. I wish I could do this directly from PBI so that I don't have maintain scripts. I tried watching several tutorials online but didn't find the right method that matches my requirement.

 

Pls let me know if this something possible. Thanks in advance!

 

Cheers!

1 Reply