CkOtpConfig constructor

CkOtpConfig({
  1. Set<CkOtpTrigger> autoTriggers = const {},
  2. CkOtpVerificationStrategy verificationStrategy = CkOtpVerificationStrategy.tokenBased,
  3. Duration resendCooldown = const Duration(seconds: 120),
  4. int maxResendAttempts = 0,
  5. int otpLength = 6,
  6. String verificationTokenHeaderKey = 'token',
  7. bool sendVerificationTokenInHeader = true,
  8. int? otpNotVerifiedStatusCode = 403,
  9. required FutureOr<Map<String, dynamic>> verifyBodyBuilder(
    1. VerifyOtpCallBack otpCallBack
    ),
  10. required FutureOr<Map<String, dynamic>> resendBodyBuilder(
    1. ResendOtpCallBack resendOtpCallBack
    ),
})

Implementation

CkOtpConfig({
  this.autoTriggers = const {},
  this.verificationStrategy = CkOtpVerificationStrategy.tokenBased,
  this.resendCooldown = const Duration(seconds: 120),
  this.maxResendAttempts = 0,
  this.otpLength = 6,
  this.verificationTokenHeaderKey = 'token',
  this.sendVerificationTokenInHeader = true,
  this.otpNotVerifiedStatusCode = 403,
  required this.verifyBodyBuilder,
  required this.resendBodyBuilder,
});