Has anyone used the new(ish) API that Weather Underground has available for folks who have a personal weather station on their site? I’ve found lots of info for the old (and free for everyone) API but haven’t had any luck finding anything for the new one (that either costs or requires having a PWS). Here’s a link to the API info they provide:
Below is the JSON file I’ve cobbled together from various sources (with my API key hashed out) but I keep getting errors (404 if I recall) when I try to test it after setting up a webhook. I’m guessing I’m just not interfacing with the new API correctly (Admittedly, I’ve never messed with APIs before) but I’m having trouble finding any good info in regards to this specific one.
Any help would be much appreciated!
{
“event”: “weatherU_hook”,
“url”: “https://api.weather.com/v3/wx/forecast/daily/5day?geocode=39.05,-94.62&format=json&units=e&language=en-US&apiKey=XXXXXXXXXXXXXX”,
“requestType”: “POST”,
“headers”: null,
“query”: null,
“responseTemplate”: “{{daypart.0.precipChance.0}}{{daypart.0.precipChance.1}}{{daypart.0.qpf.0}}{{daypart.0.qpf.1}}”,
“json”: null,
“auth”: null,
“mydevices”: true
}
Just bumping this. I’d prefer to use Weather Underground because I can pull forecast data that is at least theoretically/loosely based on the data my weather station is providing. If anyone has another weather website they like with a good API for pulling forecast data (specifically rain forecast) I’d be open as well. Bonus points if I can add my weather station to it and get to more or less the same result.
Did you ever resolve this? I’m having the exact same problem and getting a 401 error.
Thanks,
Ross
@Ross43, Weather Underground is no longer free which is most likely why you received the 401 error.
Thank you, peekay123.
At least it wasn’t my coding! What alternative have folks come up with?
Ross
I assume you don’t have a weather station on Weather Underground? It IS still free if you have a station (at least last I checked over 6 months ago); I just couldn’t get my code working.
I’m also open to alternatives, but like I mentioned in my earlier post I’d really like to be able to use my own weather station as well. AmbientWeather.net has an API that I believe lets you pull data from your weather station, but I haven’t looked into it to see if you can pull forecast data as well.
@Ross43, a widely used and still free weather site is openweathermap.org. They have a free tier and a lot of open source code examples are available for it.
1 Like