I’ve been reading over the API documentation and it’s great. I’m thinking of hooking this into my SmartThings setup. To complete part of that integration, is it possible to “do something” when a station starts and stops? For example, if zone 1 starts, I’d like to send an HTTP POST so that my SmartThings hub is aware that the zone is on. Likewise for when it stops.
I suppose I could poll the API every 5, 10, 30 seconds to get station status? But “subscribing” to events would be much cleaner – if there’s a way?
There are no unsolicited event notifications, yet. I’d like to see them and have asked. In some other posts Samer has indicated they are considering them, if not already working them. I don’t have any info on what the mechanism would look like. I would think that the supplied apps would benefit from such a mechanism, too.
Until then I’m trying to balance overhead vs currency of display. I poll for general info every 15s (settable) and trigger additional requests whenever there is an action coming from my app so that displays updates quickly. Polling for specific info occurs more or less frequently depending on the type of info and the state of the controller.