otplib API Documentation / @otplib/core / types / Digits
Type Alias: Digits
Digits =
number
Defined in: packages/core/src/types.ts:12
Number of characters in the OTP code.
Standard TOTP/HOTP uses 6-8 digits. Non-standard variants (e.g., Steam Guard) may use different lengths. Runtime validation is handled by guardrails.