image icon indicating copy to clipboard operation
image copied to clipboard

How to add parameters to the Fetch image API

Open imransilvake opened this issue 2 years ago • 1 comments

I want to add headers to the API that fetches the Image.

I upload an image with the POST API request and got the URL back. I want to pass headers to the image url in order to make it work. How can I do that?

example:

https://api.personal.ai/v1/image-audio-memory?id=64039119152d7977caa16123&Screenshot 2023-03-03 at 20.19.22.png

imransilvake avatar Mar 04 '23 18:03 imransilvake

Hi @imransilvake, I can't view the screenshot link that you posted, but from what I've understood from your comment, seems like your image tags are missing the "crossorgin" attribute which will enable image tags to fetch data from third party server. Setting "crossorigin" attribute to "anonymous" can help fix the problem, it did at-least in my case. Hope this help.

iHaroon29 avatar Mar 09 '23 15:03 iHaroon29