There is a full ARexx interface to MPRender.
See MPRender-rexx.
Also see the example scripts supplied.
ARexx scripts are run before and after each image is rendered, and before each 24 bit image is loaded. The script names can be supplied as parameters (LOADSCRIPT, PRESCRIPT and POSTSCRIPT) to MPRender.
The suffix to each ARexx script should be .MPM.