at method

String? at({
  1. int? counter,
})

Generate the HOTP value with the given count

HOTP hotp = HOTP(secret: 'BASE32ENCODEDSECRET');
hotp.at(counter: 0); // => 432143

Implementation

String? at({int? counter}) {
  if (counter == null || counter < 0) {
    return null;
  }

  return super.generateOTP(input: counter);
}