Skip to main content
POST
https://api.stablepay.global
/
v2
/
users
/
{userId}
/
verify
/
email
/
confirm
Verify Email OTP
curl --request POST \
  --url https://api.stablepay.global/v2/users/{userId}/verify/email/confirm \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "otp": "<string>"
}
'
{
  "success": true,
  "message": "Email verified successfully",
  "data": {
    "emailVerified": true,
    "verifiedAt": "2025-01-15T10:30:00.000Z"
  }
}

Verify Email OTP

Verifies the 6-digit OTP sent to the user’s email address.
userId
string
required
The unique user ID
otp
string
required
The 6-digit OTP received via email

Request

curl -X POST https://api.stablepay.global/v2/users/usr_abc123/verify/email/confirm \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "otp": "123456"
  }'

Response

{
  "success": true,
  "message": "Email verified successfully",
  "data": {
    "emailVerified": true,
    "verifiedAt": "2025-01-15T10:30:00.000Z"
  }
}
  • Maximum 3 verification attempts per OTP
  • After 3 failed attempts, request a new OTP
  • OTP expires after 10 minutes

Errors

CodeDescription
Not FoundUser not found
Already VerifiedEmail is already verified
No OTP FoundNo pending OTP found. Request a new one
Max AttemptsMaximum attempts exceeded
Invalid OTPOTP is incorrect or expired
{
  "success": true,
  "message": "Email verified successfully",
  "data": {
    "emailVerified": true,
    "verifiedAt": "2025-01-15T10:30:00.000Z"
  }
}