Is there a way to clean up if your app is uninstalled?

I see callbacks for installed(), updated(), initialize(), but is there any way to clean up if your app is uninstalled()? I create a virtual device to allow it to track an overall app state, but if you uninstall the app this virtual device is just left as an orphan.

See OpenDoorAlert.groovy here:

see:

https://docs.hubitat.com/index.php?title=App_Object#uninstalled

2 Likes

Thanks @nh.schottfam. I've bookmarked this area now. I was looking here:

https://docs.smartthings.com/en/latest/getting-started/first-smartapp.html#events-and-callback-methods