Skip to main content

Request OTP

POST /v1/users/auth/otp/request

Auth: None

FieldTypeRequiredDescription
channelstringYes"email" or "phone"
identifierstringYesEmail address or phone number matching channel
curl -X POST https://api.2settle.io/v1/users/auth/otp/request \
-H "Content-Type: application/json" \
-d '{ "channel": "email", "identifier": "jane@example.com" }'
{ "success": true, "data": { "expiresInSec": 300 } }

Notes:

  • There's a 60-second cooldown between resend requests for the same (channel, identifier) — requesting again too soon returns OTP_RATE_LIMITED (429) with the remaining wait time in the message.
  • Codes are 6 digits and expire after 5 minutes.
  • Email codes arrive as a branded email; phone codes arrive by SMS.