Interface ExtractCodesOptions

Options for extracting verification codes from email or SMS content. Use method to control extraction strategy and allowFallback to control strictness.

Export

Interface

ExtractCodesOptions

Hierarchy

  • ExtractCodesOptions

Properties

allowFallback?: boolean

Allow fallback to deterministic pattern extraction when the selected method is unavailable.

Memberof

ExtractCodesOptions

customPatterns?: string[]

Optional custom regex patterns for code extraction. Each pattern should have either one capture group for the code or match the full code directly.

Memberof

ExtractCodesOptions

maxCandidates?: number

Maximum number of code candidates to return. Best candidate is also returned separately.

Memberof

ExtractCodesOptions

maxLength?: number

Maximum code length to consider.

Memberof

ExtractCodesOptions

Extraction strategy for verification codes. Unsupported strategies may fall back when allowFallback is true.

Memberof

ExtractCodesOptions

minLength?: number

Minimum code length to consider. Typical OTP values are between 4 and 8 characters.

Memberof

ExtractCodesOptions