Forum Discussion
Using refresh token for an API in power bi desktop
Hello
I am trying to call data from an API. My access token is only available for an hour and my current call limits are restricting me to a certain amount of call per second. I am running a Function to call data and the amount of data takes more than an hour to pull. How can I set up the refresh token within power bi desktop? I can get the data ok, but I don't want to be adding new access token when it expires.
When requesting a token from the API
Thanks
Joe
1 Reply
- v-jingzhangCommunity Support
Hi Anonymous
A common practice is creating a query to get access token from an API and converting it into a custom function. Then in other queries, invoke this custom function to get the token instead of entering a fixed access token.
Here is an old similar thread for your reference. You would need to modify the code according to your API.
Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.