In my case, I have a Sonoff Basic device on the PEA side of my whole house UPS.
It's the only way I can tell if we have a power cut or internet failure and it triggers me to shut off unnecessary air cons & water heaters to maximise the time I get from my 28.8 KwHr LiFePo4 battery, it also triggers me to call PEA or CAT Telecom and tell them.
I have over a dozen of these devices controlling outside lighting, fountains, grid-tied inverters, table lamps, water heaters, garage door & main gate (the latter 2 are really useful as I can just say "Hey Siri Garage" or "Hey Siri Gate" from a few 100 metres away and they are open when I get there or I can close them after I have left. I can also program the grid-tied inverters to shut off for a few hours if I am away and it's meter reading day.