IFTTT raining trigger from REST API

The weatherflow IFTTT service has a trigger for when a station determines that it is raining. I’d like to reproduce that functionality based on the REST API. Given the different rain properties in the returned json I’m just not how to leverage them properly for this.

Thanks in advance for the help

You have got two options. If you want a near-instant notification that it is raining you can use the Websocket and listen for evt_precip messages. These will be sent when it starts reading. WeatherFlow Tempest API Websocket Reference

If you want to use REST API requests, your best bet is to pay attention to the rain accumulation field in Sky (index 3 of the obs JSON) and Tempest (index 12 of the obs JSON) responses. This gives the amount of rain accumulated over the previous 1 minute. You’ll want to look for when that value becomes non-zero (i.e. it has gone from not raining to raining).

Hope this helps

Thanks so much Peter. I was aware of the Websocket approach. But, monitoring index 12 of the obs JSON is exactly what I was looking for.

Thanks again

1 Like