Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
wkolcz
Frequent Visitor

Failed to update data source credentials: Web.Contents failed to get contents from... (Custom API)

I know this topic has a thousand of variations on the forum but I can't seem to find any that address my issue. I created an API online to pull data for my reports. In the desktop I am able to connect to the data and perform a refresh without issue but when I publish it to my online account (currently Permium) I get the Failed to update data source credentials: Web.Contents failed to get contents from 'https://mycoolapi.com/v1/getdata' (404): Not Found

 

When setting up my API I used:

 

Get Data > Web > Advanced

For URL parts I entered https://mycoolapi.com/v1/getdata

For HTTP request headers parameters I entered 'Auth' and a key

Then I set the access to Anonymous

 

All worked fine and I was able to pull in my data from my api but when I published it and went to Datasets > My Dataset > Settings I see Your data source can't be refreshed because the credentials are invalid. Please update your credentials and try again. So I clicked on Edit Credentials and left it as anonymous and tried all 4 privacy levels and it keeps giving me an error. AND the refresh still works on my desktop version.

 

What am I missing? Why does it work on the desktop and not on the 'cloud' service. I do not want to have to continously upload new data to update my reports. I have installed a gateway for my personal account, which allowed my to access the data directly from the database but I cannot on my business machine due to IT restrictions so I switched it to an API approach but still having issues.

1 ACCEPTED SOLUTION
ibarrau
Super User
Super User

Hi. Before I continue I want to say that the best practice will always be getting data direct from source. Try explaining your company that it's importante to get data from there and not from API.

Now, it looks like you have built the API. That might mean the API can only be requested from your local network. That's why you can get data from desktop but you can't get it from Service. Even though Web.Content doesn't need gateway, you might need you in case your API only responds in local network.

Just to recap. 404 means the address can't be reach. It can be because it's wrong like you have typed it wrong or because you can't get there.

I hope that helps,


If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Happy to help!

LaDataWeb Blog

View solution in original post

4 REPLIES 4
Mmahachi
Advocate I
Advocate I

Did the gateway work to resolve this i have the same issue using the zenqms api

ibarrau
Super User
Super User

Hi. Before I continue I want to say that the best practice will always be getting data direct from source. Try explaining your company that it's importante to get data from there and not from API.

Now, it looks like you have built the API. That might mean the API can only be requested from your local network. That's why you can get data from desktop but you can't get it from Service. Even though Web.Content doesn't need gateway, you might need you in case your API only responds in local network.

Just to recap. 404 means the address can't be reach. It can be because it's wrong like you have typed it wrong or because you can't get there.

I hope that helps,


If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Happy to help!

LaDataWeb Blog

B_F
Regular Visitor

Hi @ibarrau,

I am facing similar issue. In your experience what do you think is a possible solution for this issue? Is to create a Gateway for the API? How do I do that?

Thanks!

Hi,

 

I am facing similar issue, how can I set gateway in order to fix this ? 

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors