Skip to main content
Use this guide when you want OTP.ID to deliver an OTP to an email address. Send channel: "email" to POST /v3/request or POST /v3/send, then verify the user-entered code with POST /v3/verify. Email OTP fits email-first registration, account recovery, and desktop flows. OTP.ID includes your brand in the email subject and body. If your merchant account has a brand_logo, OTP.ID also displays it in the email.

Flow overview

1

Create the OTP transaction

Use POST /v3/request for an OTP.ID-generated code, or POST /v3/send when your backend generates the code.
2

OTP.ID sends the email

OTP.ID sends an HTML email to the destination address.
3

Collect the code

Ask the user to copy the code from the email. If needed, remind them to check spam or junk.
4

Verify the code

Call POST /v3/verify with the otp_id and submitted code.

Email branding

The Email OTP request payload does not need a logo field. Configure the logo on your merchant account, and OTP.ID applies it automatically for Email OTP.

Option A: OTP.ID generates the code

Request

Success response

The generated OTP code is not returned by the API. OTP.ID sends it only to the user’s email inbox.

Option B: You provide the code

Request

Success response

Verify the Email OTP

Request

Correct code response

Wrong code response

Wrong codes return HTTP 200. Always check data.verified.

Terminal error example

UI recommendations

  • Show copy such as “Enter the code we sent to user@example.com.”
  • Mask long email addresses where appropriate, for example u•••@example.com.
  • Include a Check spam or junk folder hint after a short delay.
  • Keep the resend action visible but disabled until cooldown completes.
  • If the user changes their email address, create a new OTP transaction.
  • Do not ask users to forward the OTP email or send screenshots of it.