newsAPI

फ्रीमियम
द्वारा Strata Consulting LLC | अपडेट किया गया 2 महीने पहले | News, Media
लोकप्रियता

9.7 / 10

लेटेंसी

1,718ms

सेवा का स्तर

100%

Health Check

N/A

सभी चर्चाओं पर वापस जाएं

What is the path for retreiving images?

Rapid account: Adam 1 Ai T 2 Js Qm
adam-1aiT2JsQm
एक महीने पहले

Hi

When fetching data the “image” variable return a value like:

“api/attachments/CC8iK0NnNUJUWFJMZWtKSGVHbFNZbFJ2VFJDb0FSaXNBaWdCTWdhVmxKUXB1Z1k”

I am guessing I need to do another request to fetch this image.

I have tried making a GET request to a few variations like:
https://newsapi90.p.rapidapi.com/api/attachments/CC8iK0NnNUJUWFJMZWtKSGVHbFNZbFJ2VFJDb0FSaXNBaWdCTWdhVmxKUXB1Z1k

Passing X-RapidAPI-host and X-RapidAPI-Key in the headers.

All I get is a 404 not found. Am I querying the correct endpoint?

Regards
Adam

Rapid account: Strataconsultingllc
strataconsultingllc Commented एक महीने पहले

This bug has been fixed. The image URLs that are returned by newsAPI will now look something like this: news.google.com/attachments/CC8iK0NnNVRPVWxVTFhsQlFtaHFTRjlIVFJERUF4aW5CU2dLTWdhQjBJcnlVQVU

One thing to note is that Google News recently changed the way it links to images, so this URL will end up redirecting to the actual image. in this example case, the final URL will look like this: https://encrypted-tbn3.gstatic.com/images?q=tbn:ANd9GcSRv2VhkhJsVkv4MiJXezqlvV50w-OmiC6Qcu1coXY5hVtq14EyCx2FSvbnEUwaBfM

Google might change things in the future, but as of 5/12/2024 when this post was written, this is the most current information.

I hope this helps. Thanks!

Rapid account: Strataconsultingllc
strataconsultingllc Commented एक महीने पहले

Hi Adam,

Thanks for reaching out about this issue. This appears to be a bug that has recently surfaced where the URLs for the article images are not populating correctly. I will look into this issue immediately and get back to you as soon as I can.

Thanks for catching this and bringing it to my attention!

चर्चा में शामिल हों - नीचे टिप्पणी जोड़ें:

नई टिप्पणियाँ पोस्ट करने के लिए लॉग इन / साइनअप करें