Initialize verification flow for browsers
Endpoint
Query parameters
URL to redirect the browser to after successful verification.
Response
The flow ID, used to fetch and submit the flow.
The flow type:
browser or api.Time when this flow expires (RFC3339 format).
Time when this flow was issued (RFC3339 format).
The original request URL.
Current state of the flow:
choose_method, sent_email, or passed_challenge.UI container with form fields and messages.
Status codes
| Status | Description |
|---|---|
| 200 | Verification flow created (AJAX requests) |
| 303 | Redirect to verification UI with flow ID |
| 400 | Already authenticated user trying to verify |
Initialize verification flow for native apps
Endpoint
Query parameters
URL for informational purposes. This has no effect on the flow logic.
Response
Returns the same verification flow object as the browser endpoint.Status codes
| Status | Description |
|---|---|
| 200 | Verification flow created successfully |
| 400 | Invalid request |
Get verification flow
Endpoint
Query parameters
The verification flow ID from the
flow URL query parameter.Headers
HTTP Cookie header for browser flows. Required for CSRF validation.
Response
Returns the verification flow object.Status codes
| Status | Description |
|---|---|
| 200 | Verification flow found |
| 403 | Forbidden (CSRF violation) |
| 404 | Flow not found |
Submit verification flow
The verification flow has multiple states, each requiring different submissions:Choose method state
Submit the email address to send a verification link or code.Sent email state
Submit the verification code received via email.Endpoint
Query parameters
The verification flow ID.
Verification token from the verification link (used in
passed_challenge state).Headers
HTTP Cookie header for browser flows.
Request body
Verification method:
link or code.Email address to verify (required in
choose_method state).Verification code (required when submitting code in
sent_email state).CSRF token from the flow (required for browser flows).
Response
Updated flow state.
Updated UI with messages and form fields.
Response (browser flows)
Browser flows behave differently: Inchoose_method state:
- 200 OK with updated flow (API/AJAX)
- 303 redirect to verification UI (browser)
sent_email state:
- 200 OK with updated flow (API/AJAX)
- 303 redirect to verification UI with success message (browser)
passed_challenge state (valid verification link):
- 303 redirect to configured success URL or settings UI
passed_challenge state (invalid verification link):
- 303 redirect to verification UI with error message
Status codes
| Status | Description |
|---|---|
| 200 | Flow updated successfully |
| 303 | Redirect (browser flows) |
| 400 | Form validation errors |
| 410 | Flow expired |
Verification flow states
The verification flow progresses through these states:- choose_method - User selects verification method and provides email
- sent_email - Verification email sent, user can submit code or request another
- passed_challenge - User clicked verification link or submitted valid code
Error responses
Common validation errors:emailis required - No email providedCould not find email- Email not foundVerification token is invalid- Token expired or already usedThe verification code is invalid- Code is incorrect or expiredsecurity_csrf_violation- CSRF token validation failed