Bug report
Describe the bug
When signing up a new account with email OTP, already before the OTP code has been verified
- email_verified is set to true
- last_sign_in_at is set to current time
- confirmed_at is set to current time.
To Reproduce
supabase.auth.signInWithOtp({
email,
options: {
shouldCreateUser: true,
{ data: { lang: 'en' } }, // setting email_verified: false here seems to have no effect
},
})
Expected behavior
email_verified should be false and last_sign_in_at should be null before supabase.auth.verifyOtp is called with the correct OTP code. When an email OTP code is verified, setting email_verified to true or saving some other flag or timestamp indicating that the user has proven they have access to the email is desireable.
System information
- Version of @supabase/ssr: 0.7.0
- Version of Node.js: 24.12.0
Currently, in the auth user records, the only way to know if a user has completed the OTP flow (proving they have access to the email) is to compare the created_at and last_sign_in_at timestamps. If the difference is really small, the user has most likely not signed in.
Also, why is email_verified stored in raw_user_meta_data? Should it not be more of an internal property and therefore not in the same column with user defined metadata?
Bug report
Describe the bug
When signing up a new account with email OTP, already before the OTP code has been verified
To Reproduce
Expected behavior
email_verified should be false and last_sign_in_at should be null before
supabase.auth.verifyOtpis called with the correct OTP code. When an email OTP code is verified, setting email_verified to true or saving some other flag or timestamp indicating that the user has proven they have access to the email is desireable.System information
Currently, in the auth user records, the only way to know if a user has completed the OTP flow (proving they have access to the email) is to compare the created_at and last_sign_in_at timestamps. If the difference is really small, the user has most likely not signed in.
Also, why is email_verified stored in raw_user_meta_data? Should it not be more of an internal property and therefore not in the same column with user defined metadata?