Sync Auth0 email verification for a user with application

I would like to be able to keep a user’s email verification status in sync with my application. Is there some way to trigger an action from Auth0 that talks to an external system when a change occurs? I looked into hooks - that doesn’t look like an option because those things fire based on pre-defined events, none of which are “user’s data has been modified”. Similar situation with rules; those occur only during an authentication event. Consider the following scenario: a user logs into my application without a verified email (this is allowed, but they are restricted from performing certain actions). The user sees that they cannot perform one of the restricted actions, so they click the verification link in the email that they received from Auth0. They are now verified in Auth0, but my application doesn’t know about it. Short of calling Auth0’s API every time I need to check to see if a user is verified, how can I sync that information with my application? If I had the ability to trigger a call to a third party system when the email verification occurs, that would be ideal. I guess I could embed a tracking link in the verification email, but at that point I might as well implement the email verification myself.

Does what I am asking for make sense? Is there some other option that I am not considering here?

1 Like

Use the webhook extension. You can set it up from the management dashboard. I’ve never used it myself, so can’t tell you exactly whether you need the Authorization API or Management API one and what data the webhook would send. But you can test that.

1 Like

Wow, I feel dumb haha. I was looking at “Hooks” - hadn’t looked under “Extensions”. I see what you are referring to now. I will spend some time looking at this today.

Cliche answer: dumb questions don’t exist, you really have to know it’s there. :wink: Glad it’s what you’re looking for.

Thank you @thijmen96 for sharing your knowledge on that front!

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.