Forum Discussion
questions regarding using RESTful API as data source
- 9 years ago
it turns out it was an error on my part regarding the link that I used for my api call, it shouldve been https not http, everything works now
Hey v-ljerr-msft, thanks for the response.
I am able to send an http get request using postman to the api with just a authorization HTTP header and get a response (without a cookie)
however when I try to do the same in powerquery, it says user not authorized
this is my power query:
= let
actualUrl = "http://webpage.net/rest/v1/projects",
options = [Headers =[#"Content-type"="application/json", #"Authorization"="Basic usernamepassword(in base 64 encoding)"]],
result = Json.Document(Web.Contents(actualUrl, options))
in
result
Hi ukeasyproj,
Have you tried setting the Cookie explicitly instead of using Authorization in the Headers to see if it works?:smileyhappy:
Regards
- ukeasyproj9 years agoHelper II
it turns out it was an error on my part regarding the link that I used for my api call, it shouldve been https not http, everything works now
- v-ljerr-msft9 years agoMicrosoft Employee
Hi ukeasyproj,
Great to hear the problem got resolved!:smileyhappy:Could you accept your reply as solution to help others who has similar issue easily find the answer and close this thread?
Regards
- MeryBen9 years agoRegular Visitor