Auth0 log me out after backend set email verified equal true

Hi, we decided to implement our email verification in the backend after user signup. Once the email is verified, we send a patch request to the Auth0 server to set email_verified to true:

auth0_management_request(
    f"users/{user_account_of_email_verified}",
    {"email_verified": True},
    tenant,
    "PATCH",
)

However, after doing this, the frontend automatically logs out the user, requiring them to log in again.

I have checked this post: Email verification without re-login, but the reply only mentions that:

That is the expected behavior. When you update a user’s email address, the user is logged out from your app and asked to provide their credentials to log in again.

My question is: Does updating email_verified also log out of the user? If so, how can we bypass this behavior?

Thanks

Hi @chenchang.lew

Welcome to the Auth0 Community!

Can you send me a DM with your tenant name?

Thank
Dawid

Hi @dawid.matuszczyk

I sent you a DM with my tenant’s name three days ago but haven’t received a reply yet. Could you confirm if I sent it to the correct place or if you have received it?

Thank you,
Chen Chang Lew

Hi @chenchang.lew

I apologize for the late response; I missed your message in my inbox. I’m in touch with Developer Support team, I will get back to you as soon as they respond.

Thanks
Dawid

Hi @dawid.matuszczyk. Thanks for the recent reply and solution given by the Developer teams.

As your suggestion to

toggle in your Tenant Settings → Advanced section of your dashboard with the flag Delete Session User Email Verified Deprecation and it should be off.


However, I didn’t see any setting related to “Delete Session User Email Verified Deprecation” in my tenant’s setting. Here are the settings I currently have:

But here is the interesting thing,
For the tenant: dev-bcyjnx8u, we can now register & without being logged out after the backend set email verified = true.
However, after I merge my code into staging environment, (Tenant: akina-care-stg)
We have the same problem that it logged us out again.
I have checked the tenant setting in the advanced section, both tenants have the same settings.

Can I know what did I miss? Plus, I am afraid this will also happen to my production tenant (akina-care-production) as well, can I know what should I do?

Thanks and looking forward to hearing from you

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