Overview
useSendVerificationEmail returns a function that sends a verification email to the currently authenticated user. The token expires after 5 minutes. Calling it on an already-verified user is a no-op (returns { success: true } without sending).
Usage Example
Parameters
The returned function accepts an optional props object:How the token is delivered.
"code"— user receives a token to type into your app"link"— user receives a clickable button that verifies automatically
Character set for the token.
"numeric" is recommended for OTP-style flows; "hex" for maximum entropy.Length of the generated token (4–12). Ignored when
tokenFormat is "hex".URL to redirect to after link verification. Only used with
mode: "link". Receives ?verified=true or ?verified=false&error=... as query params.Returns
The hook returns an async function. That function resolves to:true when the request completes without a server error.
