Groovy device handlers will be going away, probably as soon as the end of September.
So it would probably be better to look for an edge driver, as these are part of the new architecture.
You can find those in the quick browse lists in the community-created wiki:
How to Quick Browse the Community-Created SmartApps Forum Section - Things That Are Smart Wiki
And if you need more information about edge:
FAQ: I have no idea what Edge is. Is that a new developer tool? (2022)
And here’s the information about the changeover date: