Forum Discussion
Connecting to web api
Hi Anonymous
You can use the Web Connector
let
Source = Json.Document(Web.Contents("http://https://speca.io/SimonOnlinePOS/external-api-v2"))
in
Source
https://stackoverflow.com/questions/36685463/how-to-connect-my-web-api-wtih-power-bi-reports
- Anonymous6 years agoNot applicable
Thansk Jayendran!
I have been provieded with a token form the web service, where does that fit in ?
If you open the link, then i though i shoul build a Url like this:
Web.Contents("https://api.onlinepos.dk/api/getCardsList/{debtor}/{type}/{offset}")- Jayendran6 years agoSolution Sage
Hi Anonymous
As SteveCampbell mentioned you can pass the token in the Headers,
In Power Query this will be like
Web.Contents("https://api.powerbi.com/v2.0/",[Headers=[Authorization=Bearer 412sdsx1....]])Making much simpler you can also provide your query parameters lilke the below
Web.Contents( "https://data.gov.uk/api", [ RelativePath="3/action/package_search", Query= [ q="cows", rows="20" ] ] )Some References:
https://blog.crossjoin.co.uk/2014/03/26/working-with-web-services-in-power-query/
- Jayendran6 years agoSolution Sage
Hi Anonymous ,
Do you have any update ? If you solved your problem, please accept the answer so that it will help other community members
- SteveCampbell6 years agoMemorable Member
If you go Get Data > Web Contents, you have the option of "Advanced".
This will allow you to apply Headers
Love hearing about Power BI tips, jobs and news?
I love to share about these - connect with me!Stay up to date on
Read my blogs onRemember to spread knowledge in the community when you can!