Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Install-Module -Name MicrosoftPowerBIMgmt
- $myArray = @()
- Login-PowerBIServiceAccount
- Get-PowerBIWorkspace -Scope Organization | ForEach-Object {
- $ws = $_
- Get-PowerBIReport -WorkspaceId $_.Id | ForEach-Object {
- $x = [pscustomobject]@{
- workspaceId = $ws.Id
- workspaceName = $ws.Name
- reportId = $_.id
- reportName = $_.Name
- reportUrl = $_.WebUrl
- }
- $myArray += $x
- }
- }
- $myArray | Export-Csv "PowerBIWorkspaceReports.csv"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement