Forum Discussion
caseycook
Helper I
7 years agoQuarterly audit for user access to Workspaces, Apps, dashboards, and reports.
I need to be able to audit who has access to workspaces, apps, reports, and dashboards on a quarterly basis. Is there a way to pull this information either via powershell or within Power BI itself? ...
- 7 years agoHi there
There are Power BI Admin APIs which will allow you to get the information you require.
Here is an example of an API that gets all the users in an App Workspace.
Yes this could all be put into a PowerShell script and loop through all the App Workspaces
https://docs.microsoft.com/en-us/rest/api/power-bi/admin/groups_getgroupsasadmin#get_workspaces_with_users_expanded_(only_applicable_for_workspaces_in_the_new_workspace_experience) - 7 years agoCurrently that is not possible.
And in the near future all App Workspaces will be migrated to the V2 App Workspaces, which then will allow you to view the members.
GilbertQ
Super User
7 years agoHi there
There are Power BI Admin APIs which will allow you to get the information you require.
Here is an example of an API that gets all the users in an App Workspace.
Yes this could all be put into a PowerShell script and loop through all the App Workspaces
https://docs.microsoft.com/en-us/rest/api/power-bi/admin/groups_getgroupsasadmin#get_workspaces_with_users_expanded_(only_applicable_for_workspaces_in_the_new_workspace_experience)
There are Power BI Admin APIs which will allow you to get the information you require.
Here is an example of an API that gets all the users in an App Workspace.
Yes this could all be put into a PowerShell script and loop through all the App Workspaces
https://docs.microsoft.com/en-us/rest/api/power-bi/admin/groups_getgroupsasadmin#get_workspaces_with_users_expanded_(only_applicable_for_workspaces_in_the_new_workspace_experience)
caseycook
Helper I
7 years ago
GilbertQ wrote:
Hi there
There are Power BI Admin APIs which will allow you to get the information you require.
Here is an example of an API that gets all the users in an App Workspace.
Yes this could all be put into a PowerShell script and loop through all the App Workspaces
https://docs.microsoft.com/en-us/rest/api/power-bi/admin/groups_getgroupsasadmin#get_workspaces_with_users_expanded_(only_applicable_for_workspaces_in_the_new_workspace_experience)
It appears that you can only expand the users in the new workspace experience. Is there a way to get the users for the old workspaces?
- GilbertQ7 years ago
Super User
Currently that is not possible.
And in the near future all App Workspaces will be migrated to the V2 App Workspaces, which then will allow you to view the members.- caseycook7 years ago
Helper I
GilbertQ wrote:
Currently that is not possible.
And in the near future all App Workspaces will be migrated to the V2 App Workspaces, which then will allow you to view the members.So, it seems I could use the method above to pull for new workspaces, and then Get-UnifiedGroup for the old workspaces?
- caseycook7 years ago
Helper I
When I run this command I get the users: Get-PowerBIWorkspace -Scope Organization
However when I try to Get-PowerBIWorkspace -Scope Organization -top 50 | ConvertTo-Json the users all show up "as Microsoft.PowerBI.Common.Api.Workspaces.WorkspaceUser" Is there a way to just keep the users as a json?