How do I set up forced email verification?

Question: How do I set up forced email verification?

Answer:

Forced email verification can be accomplished in a Post-Login Action. If you would like to make a new verification email available to your user, it could be done through your application by leveraging the Management API POST api/v2/jobs/verification-email endpoint.

The Action would look like the following:

exports.onExecutePostLogin = async (event, api) => {
  if (!event.user.email_verified) {
    api.access.deny('Please verify your email before logging in.');
  }
};

Video Resource:

Supporting Documentation: