March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
I've been working on simple automation like adding aad users to aad groups and pbi workspaces. I can add users to workspace , even add groups to workspaces but I cannot remove the groups, although I can remove the users from the workspaces. I've been searching for a week now, but no-one came close. Did anyone figure out how to approach this through Powershell? thanks
Hi @mavhernandez ,
As far as I know, we can remove the group or users from workspcae access.
This function works well in my side, I can remove the security gourp scuccessfully.
Or you can try to remove the user by Power BI Rest API.
For reference: Groups - Delete User In Group - REST API (Power BI Power BI REST APIs) | Microsoft Learn
This API call can be called by a service principal profile. For more information see: Service principal profiles in Power BI Embedded.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks Rico Zhou,
UI interaction also works for me. For the REST API not really much experience in that department yet, a sample how to execute it in python / powershell would be really great. I've seen some sample on the internet however, there were nothing that removes the AAD security group from the workspace.
Below is a sample of my ADD to workspace approach
and below is the one I am working on with PowerShell but no luck
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
7 | |
3 | |
2 | |
1 | |
1 |
User | Count |
---|---|
8 | |
3 | |
2 | |
2 | |
2 |