Hi all,
I have a PowerBI model that interacts with a REST API datasource. This particular datasource only reports using POST calls. I used the workaround described here: https://community.powerbi.com/t5/Desktop/Power-BI-Desktop-and-REST-API-POST-METHOD/m-p/196892 . My POST datacall has an authorization header FWIW.
This all works fine and I can refresh all the data manually in desktop. However when I schedule a refresh and try to enter credentials for the POST source it errors out (anonymous doesnt work, neither does basic with my username and PW).
1) any luck on getting this to work?
2) is there a way where the POST source can be left out of the scheduled refresh?
Thanks!
Steve
Solved! Go to Solution.
1. mind mentioning the error message?
2. you can always choose to use a gateway and to skip the connection test on the gateway, although that is not recommended.
I figured this out. The key is getting a gateway setup as users pointer out.
Hi , @shuhn1229
As far as I understand, the API corresponding to the connection is normally accessed using anonymous mode. There should be a token string in the request header of your API, the general token is generated by another API, you can try to create the API that generated this token as a function in Power Query, and then generate a token to pass into your parameters. Then both use anonymous credentials to log in. If your API can only be accessed on your intranet, you may also need to download the on-premise data gateway on your computer to configure the corresponding credentials.
For more information, you can refer to :
Power BI Gateway | Microsoft Power BI
On-premises data gateway - Power BI | Microsoft Learn
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
The datasource can only be accessed locally (e.g. mycompany.database.com) and as noted above, login requires a UN/PW that is provided by the AUTH header in my code. I'll look into the data gateway.
Steve
1. mind mentioning the error message?
2. you can always choose to use a gateway and to skip the connection test on the gateway, although that is not recommended.
Hi @lbendlin thank you for responding.
Two important notes:
User | Count |
---|---|
114 | |
60 | |
59 | |
40 | |
40 |
User | Count |
---|---|
117 | |
66 | |
65 | |
65 | |
47 |