cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
emilyh
Frequent Visitor

API with dynamic access token can't refresh in Power BI service

Hello,

I have a report needs to get data from a REST API. To access the API, I need to first generate a access token and the token will be expired every 1 hour. I've searched many materials and was able to write a power query in Power BI desktop to generate the dynamic token and then refresh the dataset. However, after publishing the report to Power BI service, it won't allow me to refresh the dataset by schedule. Some of the posts say that we need to build a custom connector to make it work in Power BI service. 

Does anyone has idea is there some other way to make it work?

 

Thanks.

8 REPLIES 8
Quebas_2
Regular Visitor

Did you find a solution?

If you have Power BI Premium license, we will be able to do the schedule refresh without issues.

aswathiram
Regular Visitor

Hi All.. I also have the same problem. Does any one know how to fix this?

v-rongtiep-msft
Community Support
Community Support

Hi @emilyh ,

Please refer to the following documents to see if it helps you.

http://blog.datainspirations.com/2018/02/17/dynamic-web-contents-and-power-bi-refresh-errors/

https://community.powerbi.com/t5/Service/Airtable-Power-Bi-Service-Dynamic-Source-Refresh-Error/m-p/...

 

If it does not solve your problem, please provide a screenshot on it.

 

Best Regards

Community Support Team _ Polly

 

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

Hi @v-rongtiep-msft ,

I tried the solution you provided from the links, but did not work for my scenario. I need to access to a API with a dynamic access token which need to be refreshed every one hour. The access token is part of the header.

if I put the authorization part in a query, the authentication did not work.

emilyh_0-1637355724113.png

it works using header, but it won't allow me to refresh in Power Bi service using this way.

emilyh_1-1637355747254.png

 

@emilyh , Where you able to find a solution for this, even I do have the same problem.

Did any of you solve the problem? Facing the same.

Hi @v-rongtiep-msft 

I have the same problem. Is there any solution for that?

 

Thanks

Helpful resources

Announcements
PBI Sept Update Carousel

Power BI September 2023 Update

Take a look at the September 2023 Power BI update to learn more.

Learn Live

Learn Live: Event Series

Join Microsoft Reactor and learn from developers.

Top Solution Authors
Top Kudoed Authors