Lua code to delete constant alerts from sensors

Since last update 3830 my Elk motion and door sensors have been reporting to Vera every movement armed or disarmed all day long. When we are home this means over 1000 alerts ranging from device change to burglary.
Research shows this has happened to others over the years but I don’t see a working code that can be used in a scene or put into developed apps that would remove more then 50 at a time…
I imagine this can’t be beneficial to Vera’s memory.
Any help would be appreciated as usual.

Yep, a way to delete ALL alerts would make a lot of sense.