Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
YashikaAgrawal
Helper III
Helper III

My workspace(reports) download using PowerShell

Guys, Iam using the below code, to download the reports, it says "Personal workspace 'My Workspace' not found."

Question_1

Can someone please let me know is this correct code or iam missing something...

 

Question_2

As a Power BI Admin, If there are 10 personal workspace, what tenant settings should be done to allow admins to view and manage the Personal workspace.

 

# Install-Module -Name MicrosoftPowerBIMgmt

# Connect to Power BI
Connect-PowerBIServiceAccount

# Get the personal workspace (replace "My Workspace" if your personal workspace has a different name)
$personalWorkspace = Get-PowerBIWorkspace -Name "My Workspace"

# Check if the personal workspace exists
if ($personalWorkspace) {
    Write-Host "Found personal workspace: $($personalWorkspace.Name)"

    # Get reports within the personal workspace
    $reports = Get-PowerBIReport -Scope Individual -WorkspaceId $personalWorkspace.Id

    # Download reports
    foreach ($report in $reports) {
        Write-Host "Downloading report: $($report.Name)"
        Export-PowerBIReport -Scope Individual -WorkspaceId $personalWorkspace.Id -Id $report.Id -Path "C:\Path\To\Download\" -Overwrite
    }

} else {
    Write-Host "Personal workspace 'My Workspace' not found."
}

 

Thanks,

 

5 REPLIES 5
v-venuppu
Community Support
Community Support

Hi @YashikaAgrawal ,

Thank you for reaching out to Microsoft Fabric Community.

Thank you @Akash_Varuna @Cookistador for the prompt response.

I want to check if you had the opportunity to review the information provided and resolve the issue.If the response has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.

Thank you.

Akash_Varuna
Community Champion
Community Champion

Hi @YashikaAgrawal The code needs adjustment, as "My Workspace" isn't explicitly named. Use Get-PowerBIWorkspace -Scope Individual to fetch the personal workspace. For tenant settings, enable "Personal workspaces (My Workspace)" in the Power BI Admin Portal and assign Power BI Service Administrator in Azure AD. 

Which option to select hereWhich option to select here

It this the option, can you please check..

 

You need to set up the option 2

This is how to get access to a personnal workspace when someone leaves your organizatrion

 

On the other hand, you can see that the type is Personal Group and not workspace (for your powershell script)

Cookistador
Solution Sage
Solution Sage

Hi @YashikaAgrawal 

 

According to Microsoft documentation,  for the scope, you have to use Individual instead of organization 

 

https://learn.microsoft.com/en-us/powershell/module/microsoftpowerbimgmt.workspaces/get-powerbiworks...

Helpful resources

Announcements
June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.