Sort:  

In theory, this script could be used for that. The logic would be entirely off-chain, so you'd have to set up a dedicated scheduler to make sure it executes.