Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago
Solved

Is it possible to share multiple workspaces at once?

Hi!  I have multiple workspaces for my clients.  Now we have the scenario that I have 50+ workspaces and a new colleague who needs acces to all of them... do I need to share each workspace indivi...
  • AntrikshSharma's avatar
    3 years ago

    Anonymous You can run this PowerShell script to add the user in each workspace with a specified role.

    # Install-Module -Name MicrosoftPowerBIMgmt
    Login-PowerBI
    $Workspaces = Get-PowerBIWorkspace
    $UserEmail = "[email protected]"
    $AccessType = "Viewer" #Replace with Member, Admin, Contributor
    
    foreach($w in $Workspaces){
        Add-PowerBIWorkspaceUser -Scope Organization -Id $W.Id -UserPrincipalName $UserEmail -AccessRight $AccessType
    }