Passwordless OTP
One-time codes over email or SMS — no password required.
The user enters their email or phone, gets a 6-digit code, and types it back. No password.
Server config
allowSignUp: false disables the auto-signup behavior — passwordless then only works for existing users.
Endpoints
| Method | Path | Purpose |
|---|---|---|
POST | /auth/passwordless/send | { identifier, channel: 'email' | 'sms' } — emits PasswordlessCodeRequestedEvent |
POST | /auth/login | { providerName: 'passwordless', credentials: { identifier, code, channels } } |
The send endpoint generates the code and emits an event. Your listener delivers it via Resend / Twilio / etc.
Client call
Listener (server)
See Sending Emails and Sending SMS for production examples.
Custom code generation
Related
- Magic Link — clickable URL instead of a typed code.
- MFA — passwordless OTPs are reused for MFA challenges, but the flows are independent.