Image API URL, in Embedded Image, does not display

Hi guys,

So, I am displaying an Image via the EMBED feature, that pulls the image source - which is a API image URL - from a CMS Collection. However, this works fine on my laptop. But everywhere else the image cannot get displayed; Failed to load resource: the server responded with a status of 401 (Unauthorized)

How can i resolve this issue?


Where are you pulling that image from? did you set the proper authorization headers on the request?

The image url is pulled from a CMS collections, that contains the API ID of the image

I do not think i have not that Jean, how would i go about doing this

this is the embed code i am using currently; <img src="CMSfield" width="100%" height="auto">

Can you please share a read-only with us? Seems to me that The problem here is that you’re trying to get a file that requires you to be authenticated…when I have the read-only I’ll be able to have a better look at it


I think you are right that the file requires authentication

That means you can only access the resource with authentication. A file upload via a form?

I have the same problem. And yes, the image is uploaded via a form.

Never mind, I just fixed it. I needed to turn off “Restrict uploaded file access” (Project settings > Forms)

1 Like