Send email when user added to group

In our application the user cannot access directly the application upon registering, he needs to be manually verified and if it’s ok he gets added to the “allowed user” g roup.

Is there a way to automatically send the user an email when he gets added to the group ?
We already implemented a custom listener for the REGISTER event type but I don’t see any event type matching this case.

You can create an event listener for an AdminEvent with OperationType.CREATE and ResourceType.GROUP_MEMBERSHIP.

When I’m trying to figure out “is there an event for action X”, I enable saving for user and admin events in the Admin UI, do “action X”, and then look in the Events tab to see if there was an event.