Execute script on email

Running Virtualmin 6.16 on CentOS Linux 7.9.2009 (on AWS EC2 instance)

What is the easiest way to execute either a php or perl script on receiving an email in a specific email account ?
I would like to forward certain incoming mails to SMS via a Twilio API.

Welcome to the community, @sprfn.

I too would like an easy and simple answer to this question. It the very last discussion that we had about this, Virtualmin had permission issues and email could not be triggered, or something to the effect if memory serves.