Send e-mail on 'user_add' event

Is it possible to:

  1. Automatically send e-mails to users that have been added to privacyIDEA via resolvers/realms (without them logging in first)?
  2. Automatically send them registration tokens for self-service? Or, if not, somehow automatically distribute tokens generated with another event handler?

I’ve read in documentation that event action can’t trigger another event, so maybe it’s possible via scripts. I’ve searched for a few that can enumerate realm users and generate tokens, but haven’t found one that would generate and send an e-mail.

Also kind of unrelated but is it possible to make it so OTP popup window in OpenVPN appears for non-email OTP also? Not sure how privacyIDEA handles it but would like to have an option of not concatenating OTP to password.

Users are located in an external database.
“Added to privacyIDEA” does not exist!

A user is not added to privacyIDEA. Or are you managing your users in privacyIDEA?
Like with an editable SQL resolver?

So you need to elaborate on your resolver config.

Currently not answerable.