Get an IFTTT notification when there's wind coming. The notification includes average windspeed, spot and winddirection.
The application scrapes the forecast for the following 3 days from windguru.cz and sends the forecast to the maker webhooks service on ifttt, which can send a notification to your phone if connected to the notifications channel. Or you can connect it to something else.
This application uses a scraper to scrape windguru.cz. This is not allowed by the website, so use this application at you own risk.
Table of contents
- .env file
- IFTTT applet
Run the following commands in terminal.
git clone https://github.com/jeroentvb/wind-notifier.git cd wind-notifier npm install touch .env
Next, create a file named
.env and add the following line.
Get your key for the maker channel here. Paste your key in the
.env file after
An example config file is located in app-config.json.
Spot info is contained in the
spots array. Each spot is represented by an object.
The name of the spot. This name will be used in the notification.
The windguru number of a spot, which is used to get the forecastdata. Get the spot number from the url of the forecast for a spot.
Example: this is the url for the spot tarifa
https://www.windguru.cz/43. 43 is the spot number.
The number windguru uses to identify a forecast model.
You can get these using the inspector in your browser. Or use 0 for the first model, 1 for the second, 2 for the third, e.t.c.
Make sure the selected model has a forecast for 3 days. Otherwise the application may not work.
Example: If I want to use the ICON model for tarifa, the modelnumber would be 4.
directionMin & directionMax
Used to calculate which spot is best with a certain winddirection. The forecast of the best spot matching the winddirection will be used for the notification.
These numbers are degrees. The winddirection of a spot is calculated from
directionMax. If the winddirection (in degrees) is within those values, it will be selected as the best spot for that winddirection.
A spots min and max direction and degrees can pass 360 degrees.
Minimum windspeed (in kts) for at least 3 hours to trigger a notification.
If this value is left empty, the minimum will be set at 14 kts.
You also need to connect the ifttt maker channel to an applet in order to do something with the notification.
It doesn't really matter what service you attatch to it, as long as you set the maker event name to
Since this isn't a server but more of a script that should be run once to send a notification, you need to set up some sort of cron job to run this application at the desired time.