Email Verification
Before the user signs up (i.e. creates an Identities::User), we verify their email within the sign up form.
- User inputs email
- User clicks verify email
- OTP field appears
- System sends OTP
- User receives OTP
- User inputs OTP into the OTP field
- User clicks verify
This process requires us to store name@email.com: 123456 key-value pair in temporary storage.
- We store this in Redis, since it's fast.
Generate OTP Rules
Email- valid email format with
valid_email2gem
- valid email format with
Identities::Users::EmailVerification- if exists, ensure it is within resend window
- if not exists, send the OTP