RainLoop WebMail Hooks

How can i use hooks in rainloop, this APP is awesome but i need callback my function from my Personal App.

I wish could do something like this:

 //from myapp: Hook sending email
$RAINLOOP->AddHook('filter.smtp-from', function( $args ){ ............... });