Method: verifyOtp

Verifies the user provided OTP to determine if it matches what the issuer sent. If it matches then the authentication is considered successful.

If the endpoint encounters an error while processing the request, the response body from this endpoint should be of type ErrorResponse.

An example request looks like:


{
  "requestHeader": {
    "protocolVersion": {
      "major": 1
    },
    "requestId": "cmVxdWVzdDE",
    "requestTimestamp": {
      "epochMillis": "1481899949606"
    },
    "paymentIntegratorAccountId": "SpeedyPaymentsIndia_INR"
  },
  "authenticateRequestId": "G112YZH4XPDV88J",
  "otp": "123456"
}

An example response looks like:


{
  "responseHeader": {
    "responseTimestamp": {
      "epochMillis": "1481899949611"
    }
  },
  "eci": "07",
  "result": {
    "success": {}
  }
}

HTTP request

POST https://www.integratorhost.example.com/integrator-base-path/v1/payment-integrator-authenticated-card-fop-api/verifyOtp

Request body

The request body contains data with the following structure:

JSON representation
{
  "requestHeader": {
    object (RequestHeader)
  },
  "authenticateRequestId": string,
  "otp": string
}
Fields
requestHeader

object (RequestHeader)

REQUIRED: Common header for all requests.

authenticateRequestId

string

REQUIRED: requestId from the authenticate request that preceded this call.

otp

string

REQUIRED: This is the OTP the user provided, which this call is verifying

Response body

This method supports multiple return types. For additional information about what 4XX or 5XX HTTP status code to return with an ErrorResponse, consult the ErrorResponse object and HTTP status codes documentation.

Possible response messages
HTTP 200 Status

object (VerifyOtpResponse)

HTTP 4XX / 5XX Status

object (ErrorResponse)

VerifyOtpResponse

Response object for the verifyOtp method.

JSON representation
{
  "responseHeader": {
    object (ResponseHeader)
  },
  "paymentIntegratorVerifyOtpId": string,
  "eci": string,
  "result": {
    object (VerifyOtpResultCode)
  }
}
Fields
responseHeader

object (ResponseHeader)

REQUIRED: Common header for all responses.

paymentIntegratorVerifyOtpId

string

OPTIONAL: Identifier the payment integrator generates and uses to identify this request.

eci

string

OPTIONAL: The Electronic Commerce Indicator returned for the request. It should be returned if available.

result

object (VerifyOtpResultCode)

REQUIRED: Result of this request

VerifyOtpResultCode

JSON representation
{

  // Union field verify_otp_result_code can be only one of the following:
  "success": {
    object (Empty)
  },
  "otpNotMatched": {
    object (Empty)
  },
  "otpAlreadyUsed": {
    object (Empty)
  }
  // End of list of possible types for union field verify_otp_result_code.
}
Fields
Union field verify_otp_result_code. Result codes for verifyOtp. verify_otp_result_code can be only one of the following:
success

object (Empty)

OTP matched what the integrator sent

otpNotMatched

object (Empty)

OTP did not match what the integrator sent.

otpAlreadyUsed

object (Empty)

OTP was already used.