Forum Discussion
Scheduling Custom Function that calls for API with Bearer Authorization - possible in the service?
Hello,
I have to API calls with Bearer Token Authorization
The first returns a list of users
The second takes a user as a parameter and makes another API call to get some data for that user.
I have created a Custom Function and add a column that calls for this function for each user.
Works great in the desktop but cannot make it work in the Service.
Is it possible? How can I make it refresh (I need to do it with Bearer Token)
Thanks
Hi michaelshparber ,
You try to add the Headers parameter to the connects() function:
How to refresh report that uses custom functions on Power BI Service?
Best regards,
Lionel ChenIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
4 Replies
- v-lionel-msftCommunity Support
Hi michaelshparber ,
You try to add the Headers parameter to the connects() function:
How to refresh report that uses custom functions on Power BI Service?
Best regards,
Lionel ChenIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- michaelshparberAdvocate V
Thanks for the direction.
Now it allows me to enter credentials but I am getting a different error when refreshing:
Please help
Thanks!
Data source error: {"error":{"code":"ModelRefresh_ShortMessage_ProcessingError","pbi.error":{"code":"ModelRefresh_ShortMessage_ProcessingError","parameters":{},"details":[{"code":"Message","detail":{"type":1,"value":"[Unable to combine data] Section1/users (2)/AutoRemovedColumns1 references other queries or steps, so it may not directly access a data source. Please rebuild this data combination."}}],"exceptionCulprit":1}}} Table: users (2). - v-lionel-msftCommunity Support
Hi michaelshparber ,
Please refer to this this asnwer:
Unable to combine data - Please rebuild this data combination - Refresh
Best regards,
Lionel ChenIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.