Validate OTP API

Checksum required: NO

Use Case


To validate the OTP entered by user to complete authentication for login into Paytm ecosystem

Request Attributes:

API Content format: JSON

Head

PARAMETERDESCRIPTIONMANDATORY
Version String (4)Version of the API. Current version is v1Yes
requestTimestamp String (15)UNIX timestamp of the time request is being sentNo
channelId String (3)For websites, the value is WEB. For Mobile websites/App, the value is WAPYes
txnToken String (64)Provided in response of Create Subscription/ Initiate Transaction APIYes

Body

PARAMETERDESCRIPTIONMANDATORY
OTP String6 digit OTP entered by the userYes

Response Attributes:

API Content format: JSON

Head

PARAMETERDESCRIPTIONMANDATORY
Version String (2)Version of the API passed in the requestYes
responseTimestamp String (15)UNIX Timestamp of the responseYes

Body

PARAMETERDESCRIPTIONMANDATORY
isAuthenticated BooleanLogin successful or failedYes
resultInfo ResultInfoResult info of API callYes

ResultInfo

PARAMETERDESCRIPTIONMANDATORY
resultStatusString (S(Success), F(Failure), U(Unknown))Status of API callYes
resultCodestringResult code returned to merchant . Max length of result code can be 64Yes
resultMsgstring (Max length can be 256])Result Message contains information about the result.Yes

Validate OTP Response Codes and Messages

CODEMESSAGE
01Success
403Invalid OTP entered.
513Invalid Code,
708Oops ! You have reached OTP limit, please raise a query at paytm.com/care.
434Oops ! You have reached OTP limit, please raise a query at paytm.com/care.
00000900System Error

Endpoints

Staging: https://securegw-stage.paytm.in/theia/api/v1/login/validateOtp?mid=<mid>&orderId=<orderId>

Production: https://securegw.paytm.in/theia/api/v1/login/validateOtp?mid=<mid>&orderId=<orderId>

Request CodeResponse JSON
curl -X POST 'https://securegw-stage.paytm.in/login/validateOtp?mid=xxxxxxxxxxxxxxxxxxxx&orderId=xxxxxxxxxxxxxx' --header 'Content-Type: application/json' --data '{"head":{"version":"v1","requestTimestamp":"xxxxxxxxxx","channelId":"WEB","txnToken":"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"},"body":{"otp":"xxxxxx"}}'