I'm a boot camp student, working on a class project. Very new to these things so I appreciate any help. To clarify beforehand, I've replaced my API key with MYKEY in all of the following.
I had been getting blocked by CORS when using $.getJSON("api.openweathermap.org/ImageBox/2.5/weather?q=philadelphia&appid=MYKEY
Then this morning I had a revelation and put http:// prior to the api.openweathermap... and suddenly my API calls started working. After about an hour of tweaking the rest of my JS, I once again started getting error messages.
GET http://api.openweathermap.org/ImageBox/2.5/weather?q=philadelphia&appid=MYKEY 404 (Not Found)
Access to XMLHttpRequest at 'http://api.openweathermap.org/ImageBox/2.5/weather?q=philadelphia&appid=MYKEY' from origin 'null' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.
Help is greatly appreciated. Thank you in advance.
Thank you for request.
What is /ImageBox/ in your API call? The right call is http://api.openweathermap.org/data/2.5/weather?q=philadelphia&appid=MYKEY
If you are using CORS, you should specify headers.
404 error is not about overloading, but “Not found” (Because you are using wrong URL)