How do I call App.RefreshDevice on a schedule?

I’m using the Hubitat built-in integration and occasionally, perhaps upon reboot of the hub, the websocket gets stuck and a RefreshDevice seems to unstick it so I’d like to perform an App.RefreshDevice(“Hubitat”) every few hours, say, without requiring any human input on the HR tablets I have mounted all over the house.

Thanks for any suggestions,
Dan

You can probably use Idle Events to automatically refresh your Hubitat connection. Although that was originally intended for screensaver type things there’s really no reason you couldn’t use it to refresh your connection.

Thanks. I set up an Idle Event as suggested but that works only once. The event triggers after the timeout but App.IsIdle stays True even after the event is triggered. Is there a way to restart the idle countdown (other than interacting with the screen)? From your feature announcement, I thought maybe I could use OpenPage in the event actions to restart the countdown but it gives “Specified method is not supported” error. I also tried pushing another page and popping back to the MainPage. That didn’t cause an error but it also didn’t restart the countdown. I also tried manually setting IsIdle to False but that didn’t restart the countdown either. Thoughts?