code for MySql | MariaDB to trigger / signal external script from database

code for MySql | MariaDB to trigger / signal external script from database
One feature I often wish MySQL / MariaDB (I’ll refer from now to just MariaDB referring to both) had was the ability to trigger or launch an ¬†external script or open a socket connection to some external site; on a database event. Perhaps using a stored procedure in other words generate a signal /event to ...