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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
pborah
Solution Sage
Solution Sage

Get app icons calling the API from PowerShell?

Hi,

 

I'm trying to retrieve all the icons used in our published apps by calling the API from Powershell but it doesn't seem to return anything. It's however not throwing any error either.

 

I am the owner of all those apps and the workspace admin for their source workspaces. Below is my code. Although the API documentation doesn't mention anything specific about getting the icons, I had a bit of help from co-pilot. Which is why I understand that this capability may not even exist since co-pilot can just make stuff up sometimes.

 

$credential = Get-Credential
Login-PowerBI -Credential $credential


$apiUrl = "https://api.powerbi.com/v1.0/myorg/apps"
$response = Invoke-PowerBIRestMethod -Url $apiUrl -Method Get


$savePath = "C:\Users\xyz\Documents"

foreach ($app in $response.value) {
    $appId = $app.id
    $appName = $app.name
    $iconUrl = $app.iconUrl
    $iconPath = Join-Path -Path $savePath -ChildPath "$appName.png"
  
    
    Invoke-WebRequest -Uri $iconUrl -OutFile $iconPath

    Write-Output "App icon for '$appName' downloaded successfully to $iconPath"
}
1 ACCEPTED SOLUTION
lbendlin
Super User
Super User

Pure hallucination.

 

Apps - Get Apps - REST API (Power BI Power BI REST APIs) | Microsoft Learn

 

If this is important to you please consider voting for an existing idea or raising a new one at https://ideas.fabric.microsoft.com

View solution in original post

4 REPLIES 4
v-echaithra
Community Support
Community Support

Hi @pborah ,

As we haven’t heard back from you, we wanted to kindly follow up to check if the solution provided for the issue worked? or Let us know if you need any further assistance?
If our response addressed, please mark it as Accept as solution and click Yes if you found it helpful.

 

Regards,
Chaithra.

v-echaithra
Community Support
Community Support

Hi @pborah,

May I ask if you have gotten this issue resolved?

 

If it is solved, please mark the helpful reply or share your solution and accept it as solution, it will be helpful for other members of the community who have similar problems as yours to solve it faster.

 

Regards,
Chaithra.

lbendlin
Super User
Super User

Pure hallucination.

 

Apps - Get Apps - REST API (Power BI Power BI REST APIs) | Microsoft Learn

 

If this is important to you please consider voting for an existing idea or raising a new one at https://ideas.fabric.microsoft.com

@lbendlin yeah I think so too. Earlier when I was trying out fetching workspace/report/dashboard details via script, I found there to be some properties that were nested arrays (subproperties) that aren't expliticitly mentioned in the documentation unless you do a deep dive, so I figured maybe that is the case here. But after trying out atleast 20 different variations of the code above, I'm beginning to think this capability does not exist yet. It should but it doesn't.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.