[API] Enable Power Save Mode via API

Is there a way to enable/disable power save mode via the API? either websocket, REST, MQTT or local network?

Maybe with an OAuth token for security?

I could try to reverse engineer what the web page is doing, but that seems like a lot of work.

I was thinking to leave the Sky in low power mode unless it becomes windy, then switch it to high power (normal) mode. I know it takes a couple of minutes to take effect, but it might be worthwhile.

Any suggestions for how I can do this programatically?

Thanks

2 Likes

Hi Nick,
welcome to the community.

I’m quite sure actually there is no option for that in the API. But it’s a good point for an feature request.

Maybe @corrineb can tell more about the plans?

1 Like

Thanks,

I can send actions to my devices via websocket (listen_start for example), so maybe that would be the easiest route (but then security would be an issue), although I’m using the UDP broadcasts to receive data locally.

From my point of view MQTT is easiest, as 80% of my home automation uses MQTT already, so it’s easy to integrate. I know there was some talk about MQTT a couple of years ago, and wetherflow already uses MQTT to send/retrieve data from their backend, but seeing as that never got implemented, there would be the most infrastructure to implement.

Having said that, a simple REST call with an OAuth2 token would be the simplest to implement.

The same method could be used for enable/disable the lightning sensor, so maybe there is an argument for enhancements to the API to allow users to send json to the hub.

Just my first thoughts having played around with the API for a week or so since I got my Air and Sky installed.

2 Likes

That is not correct. The websocket data comes from the WeatherFlow servers. You send a command to those servers to tell them what data to send over the socket.

At this point there is no local interface to communicate directly with the Hub.

3 Likes