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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
MonsterSky
Regular Visitor

Refresh Power BI using company scheduler

Hello Community, I'm new on this forum and I hope I have chosen the right section to write this post.

 

I need to schedule the refresh of some Power BI report using an external scheduler because I need to keep all the schedules of our systems inside our company scheduler.

 

Is there a command line way to submit a report refresh? Is this way I will able to submit that command using our company scheduler that is able to send a command line to a server.

 

Thank you.

 

Andrea

1 ACCEPTED SOLUTION

This is possible, but it would be a two step process, so you'd need to write a script using something like Powershell or Python that can call a REST API.

 

The first thing you'd need to do is to setup a scheduled refresh on your report, but you can set this up for a once off date some time in the past so that it does not actually get triggered.

 

Then you would use the following GET request to get a list of the refresh schedules

https://app.swaggerhub.com/apis/microsoft-rs/PBIRS/2.0#/PowerBIReports/GetPowerBICacheRefreshPlans

 

Then you would use the ID of the first refresh plan and use POST request to the model.execute endpoint to trigger the refresh immediately

https://app.swaggerhub.com/apis/microsoft-rs/PBIRS/2.0#/CacheRefreshPlans/ExecuteCacheRefreshPlan

View solution in original post

3 REPLIES 3
MonsterSky
Regular Visitor

Perfect, thank you for all the detailed information.

MonsterSky
Regular Visitor

No one? I have to assume that external schedulations are no possible. Am I right? Thank you.

This is possible, but it would be a two step process, so you'd need to write a script using something like Powershell or Python that can call a REST API.

 

The first thing you'd need to do is to setup a scheduled refresh on your report, but you can set this up for a once off date some time in the past so that it does not actually get triggered.

 

Then you would use the following GET request to get a list of the refresh schedules

https://app.swaggerhub.com/apis/microsoft-rs/PBIRS/2.0#/PowerBIReports/GetPowerBICacheRefreshPlans

 

Then you would use the ID of the first refresh plan and use POST request to the model.execute endpoint to trigger the refresh immediately

https://app.swaggerhub.com/apis/microsoft-rs/PBIRS/2.0#/CacheRefreshPlans/ExecuteCacheRefreshPlan

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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