Forecast API/Software?

This is rather interesting and not difficult to implicate. I’m looking at accuracy.

Just started … Will be pulling live data from my DB to see how it works on an hourly or so basis .

2 Likes

I like the Norwegian service YR.NO for forecasts.

1 Like

Hi Lasse. We may use anonymous, private data for development of derived products such as forecasts. But if you’re planning to build a business around the smart weather stations, exceptions can be made. Anything is possible and we are committed to building a developer ecosystem that supports all kinds of use cases!

1 Like

I like YR.NO’s free data attitude so much that I’ve actually considered applying for Norway citizenship so that my taxes would pay for this service…

4 Likes

Ok… got it working… It’s sitting on a publicly available server (mine)… just a PHP call with specific parameters and returns the SAGER forecast.

Anyone wanna try?

I plan on incorporating this option into my Wx Console & btstWx apps.

–Sam

2 Likes

Any reason why you used a 12 hour offset instead of the 6 hour offset in the files?
–Sam

2 Likes

what files ? sorry refresh me

The SAGER files use a 6 hour history instead of 12 like you do. Just wondering why you chose 12 hours.

2 Likes

ha ok i see now , i found the 12 hour range offered a better reflection of trend and the output was more accurate to,this specific location.

but if 6 hours is ok for you then stick with that has i said prior to,this i spent an whole year going through the seasons tweaking the output . i also included the dewpoint to reflect cold periods or warmer periods i found monitoring the dewpoint often leads to forthcoming conditions in terms of heat,coldness etc. here in summer periods we observe the dewpoint over temperature as to get an indicator of comfort , li,e last week it was 26c but dewpoint was hovering above 20c meaning uncomfortably humid at night …

as i said before many scenarios you can implement into the script to get a short term forecast … barometer like. glad you pursued it look forward to hearing all about it .

1 Like

I’d be keen to give it a spin!

Peter, et al.

You will use a link like this:
http://beentheresailedthat.com/ws/server/php/bt-sager-wc.php?lat=32.5&lon=-85.5&temp=90.1&tempS=F&brg=170.0&brg6=155.0&wunit=kts&rtime=3600&baro=30.01&baro6=29.98&bunit=inHg

Just replace the values with whatever you have:

lat = Station Latitude (decimal degrees)
lon = Station Longitude (decimal degrees)
temp = current station temp
brg = current station wind bearing
brg6 = station wind bearing 6 hours ago
wunit = wind unit (kts, mph, m/s)
rtime = seconds since last rain
baro = current station barometric pressure
baro6 = station pressure 6 hours ago
bunit = baro pressure units (inHg, mm, etc)

See how it works for you… seems to be pretty accurate here so far.
–Sam

2 Likes

rtime should be MINUTES since last rain, not seconds…

–Sam

2 Likes

Hi! How are the things going for API for forecast? I’ve just seen that hourly and 10 day forecasts in new Tempest app. Is this forecast prepared with use of your own system? Would there be soon a possibility to get this data through API?

Hi there. Yes, details on the forecast side of the API will be published as soon as we finalize them - which should be withing a couple weeks.

6 Likes

Any updates on the forecast API documentation?
Thanks.

Sorry, not yet. It’s rising slowly to the top of the list though.

If someone else wants to help, I’m trying to get the forecast data from the Tempest API to Home Assistant weather entity & sensors. The latter part already easily works with the shared APIs but the former isn’t documented.

I have been able to get about 10 day daily forecast from this API endpoint:
GET https://swd.weatherflow.com/swd/rest/better_forecast?station_id={}&api_key={}&lat={}&lon={}

The DEV API key seems to work, if you don’t have lat/lon for the station you can use the existing API to query it.

For Home Assistant, I’m hoping to fork this and change the weather component data source from DarkSky (which is on death watch) to using the Tempest’s forecast using API above or whatever the final one is: https://github.com/briis/smartweather (fyi @briis)

Hi Max and welcome to the forum! We’d love to help you with your HomeAssistant integration, but we’re not quite ready.

The standard forecast API will NOT work the way you are using it. Access will be based on access token (personal or Oauth based) rather than (or in addition to) API key. And the forecast provided will be based on station_id rather than lat/long. An update to the documentation is coming soon, which will include more details on the access token concept as well as details on the forecast side of the API.

To get you started, check out this post: Oauth2 Access Token - #6 by dsj

Sure, I mean given this is undocumented at this time I fully expect that some changes might happen but I mean this is working right now :slight_smile: In my case my tempest is public so there isn’t a lot of access control needed. I’m assuming many will be in a similar situation as we have been previously trading public station data to wunderground in exchange for being able to use their API. Whenever you guys finalize this we can do the code updates for access.

Either way, I can get both daily and hourly forecast data now and get ahead on integrating with home assistant.