Verify OTP

Verify OTP

POST https://api.oneroute.io/api/oneotp/verify

Use this endpoint to verify that the customer entered the same OTP that was sent with the Send OTP endpoint.

Headers

Name
Type
Description

apikey

string

API key, for Authentication.

Request Body

Name
Type
Description

key

string

Verification Key, from the Send OTP request.

otp

string

OTP to verify

identifier

string

email or phone number the OTP was sent to

{
    "message": "Otp verified successfully",
    "body": {
        "status": "Success",
        "response": "OTP Matched"
    },
    "success": true
}

Verify with USSD

When you include USSD as one of your preferred OneOTP channels, your customers can verify their OTP by dialing your USSD code which you can find on your Account Settings Page.

Once verification is complete, a notification will be sent to the webhook urlconfigured on your Account Settings Page to notify you that the OTP has been verified successfully.

Webhook Payload Sample

{
    "id": "63d45b42-0898-43b3-b81d-1fb2d45bc78f",
    "otp": "1234",
    "identifier": "+234XXXXXXXX",
    "expiration_time": "1941-06-22T16:36:45.742Z"
    "createdAt": "1941-06-22T16:36:45.742Z"
}

Last updated

Was this helpful?