Calling API from Power bi Desktop throws multiple errors (API KEY should be provided)

21 views Asked by At

Im trying to call an API from power bi desktop using the web connector. I have the url which includes a query. I also have a Key which i will be using for connecting from power bi to that api.

I tried the below options:

  1. Use Web connector --> Advanced --> In the headers, creates "Authorization" and provided the key, it failed with the error "A web API key can only be specified when a web API key name is provided"

  2. M Query --> Web.Contents("https://api.xyz.com/page-metrics/get",[ApiKeyName="x_api_key"]), and passed the Key in the "Key" prompt using WEB API credential.

  3. Use Web connector --> Advanced --> In the headers, create "ApiKeyName" and provided the key.

None of the above worked, while all the forums that i read through provided almost similar answers.

Am I doing something wrong here? or is there a different way of doing this? Appreciate if someone can throw some light. TIA.

My URL(test) looks like this : https://api.testing.com/v3/external/reporting/sharing?endDate=2019-03-12&startDate=2019-03-02&metric=blend_sharing%67

0

There are 0 answers