Validate OTP - ReconoSERID/SDK-ReconoSERID-Android GitHub Wiki

Validate OTP

Method to validate the server's OTP with the one sent by the citizen. sent by the citizen.

#!java

public void validateOTP(@NotNull String guidOTP, @NotNull String oTP, @NotNull CallbackValidateOTP listener)

Input parameter

Parameter ## Parameter ##

Parameter Type Required Description
guidOTP String YES Is the unique identifier of the OTP
oTP String YES String containing a verification code
CallbackValidateOTP Callback IF Returns a ValidateOTP and TransactionResponse

Receives ValidateOTP

Parameters ValidateOTP ## Parameter | Type | Description | Description

Parameter Type Description
isValidation boolean Is the response from the validation that was performed with the OTP
responseTransaction Object Transaction Response

Ex:

#!java

ServicesOlimpia.getInstance().validateOTP(guidOTP, oTP, new OlimpiaInterface.CallbackValidateOTP() {
            @Override
            public void onSuccess(ValidateOTP validateOTP) {
                //
            }

            @Override
            public void onError(TransactionResponse transactionResponse) {
                //
            }
        });

return to services