Forum Discussion
How to get current login-user's workspace
Even when you do that you won't know if they are admin or editor/contributor. We use the Tenant Audit log (WorkspacesUsers) for these purposes. That log includes the role type.
Could use below api to get user role.
https://docs.microsoft.com/en-us/rest/api/power-bi/groups/get-group-users
May I know how to get "Tenant Audit log", what are those details inside?
- lbendlin4 years ago
Super User
Ask your tenant admin to help you.
- Anonymous4 years agoNot applicable
Hi frankyhc ,
Please open Admin Portal by using global admin account to enter.
Please refer to the following document about audit logs to see if it helps you.
https://docs.microsoft.com/power-bi/admin/service-admin-auditing
Best Regards
Community Support Team _ Polly
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- frankyhc4 years agoFrequent Visitor
Hi,
Actually my question is how to get current login user's workspace, not ask how to get audit log.
I am Power BI Service admin, and then not able to get audit log. I viewed the documentation you sent, it seems like only get user's recent activity.
- lbendlin4 years ago
Super User
I assume you are on Premium. You need to include a step to promote you users' workspaces from shared to premium.
Don't allow your users to pick a capacity. That is a job for the Power BI service admin.