Local Weather App HTTPS API

Local Weather App HTTPS API
0

#1

Hi everyone,

TLDR: go here, click pricing, click free tier: https://www.apixu.com/

I found working with OpenWeatherMap very restrictive because I’m running my code from an HTTPS server and they serve their free API content over HTTP which modern browsers block by default. There are quite a few crafty workarounds for this on StackOverflow, many of which involve creating proxies or CURLing the site to somewhere on a server and working from the local page. I wasn’t inclined to do either of those and wanted something better and found APIXU’s weather API to be a great solution. Their free tier serves over both HTTP and HTTPS and let’s you send 5000 requests per month. You can check them out here:

https://www.apixu.com/

Hopefully this helps someone else!

Cheers!

Kyle


#2

Thank you for the link @KyleMcKenzie! I just migrated from GitHub Pages to a Digital Ocean VPS, and ran into the same problem with OpenWeatherMap. I ended up going with the Weather Underground API. It worked out well, because Weather Underground can do the IP based geolocation and current conditions with one API call. :smile:


#3

Thanks Zack, I’ll definitely check out Weather Underground too!


#4

Thanks. The exercise’s default suggestion of an HTTP API seems a bit strange, considering the previous lessons cover geolocation. This suggests to me that they would want you to use geolocation for the app ;). Geolocation only works with HTTPS…