Class Otp


public class Otp extends BaseService
  • Constructor Details

    • Otp

      public Otp(String apiKey)
      Constructs an instance of the Otp class.
      Parameters:
      apiKey - The apiKey used for authentication.
  • Method Details

    • send

      public SendOtpResponse send(SendOtpOptions sendOtpOptions) throws ReSMSException
      Send an OTP based on the provided OTP request
      Parameters:
      sendOtpOptions - The request containing OTP details.
      Returns:
      The response indicating the status of the OTP.
      Throws:
      ReSMSException - If an error occurs while sending the OTP.
    • verify

      public VerifyOtpResponse verify(VerifyOtpOptions verifyOtpOptions) throws ReSMSException
      Verify an OTP based on the provided OTP verify request
      Parameters:
      verifyOtpOptions - The request containing OTP verify details.
      Returns:
      The response indicating the status of the OTP verification.
      Throws:
      ReSMSException - If an error occurs while verifying the OTP.