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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
Cherie
New Member

Automatically connect to API Requiring Dates in Parts

I'm connecting to an External API and the API URL requires the parts {date_start} and {date_end}.

GET /ranks/{site_id}/{date_start}/{date_end}

 

I can connect to the API easily but, I don't know how I could automatically connect to the API daily and automatically change the date parts to reflect this to then push the data to the data set.

 

I've done this historically through a script but I've new to PowerBI.
When reading the automation document all I find is scheduling the REST API for Power BI.

 

Should I be using the Python Script Connector to call to the API to auto add new data on a schedule?

2 REPLIES 2
v-henryk-mstf
Community Support
Community Support

Hi @Cherie ,

 

In the api you provide, you can only manually enter the date range, but you cannot create a date column to dynamically get the latest date.

 

As for the Python Script Connector, I read the related documents, and it didn’t mention that you can set the dynamic date parameter to get the latest data set.

vhenrykmstf_1-1624589215031.png

 

If you want to dynamically get the latest date and refresh the data set, my suggestion is to configure a scheduled refresh, you can set the refresh interval.

vhenrykmstf_0-1624588821119.png

 

related blog link:

Automate Your Power BI Dataset Refresh with Python - Pivotal BI

Data refresh in Power BI - Power BI | Microsoft Docs

Best Regards,
Henry

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thanks for the advice @v-henryk-mstf,
I'll try it an dlet you know if it works.

PREVIEW
 
 
 

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors