/**
 * @fileoverview Pure detection of Claude Code usage-limit pause messages.
 *
 * When a Claude subscription limit (5-hour rolling window, weekly, Opus weekly,
 * or extra-usage balance) is hit, the Claude Code TUI stops working and prints a
 * status line with the reset time. These helpers detect that state in cleaned
 * (ANSI-stripped) terminal output and parse the reset time, so the session
 * auto-resume feature (SessionAutoOps) can schedule a "continue" nudge.
 *
 * Message shapes covered (observed across Claude Code 1.0.x–2.1.x, 2025–2026):
 * - `5-hour limit reached ∙ resets 8pm`                                (v1.0.109+ footer)
 * - `Session limit reached ∙ resets 8pm`
 * - `Weekly limit reached ∙ resets 6pm`
 * - `Opus weekly limit reached ∙ resets Oct 6, 1pm`
 * - `Limit reached · resets 1pm (America/Chicago) · /upgrade to Max…`  (v2.0.55+)
 * - `You've hit your limit · resets 1:40pm (America/New_York)`         (v2.1.x)
 * - `You've hit your weekly limit · resets Mon 12:00am`
 * - `You've hit your limit · resets May 5 at 9pm (America/New_York)`
 * - `You're out of extra usage · resets 1pm (America/Los_Angeles)`
 * - `Claude usage limit reached. Your limit will reset at 2pm (America/New_York)` (v1.0.x inline)
 * - `Claude AI usage limit reached|1755309600`                         (raw API, epoch seconds)
 *
 * Deliberately conservative: a limit phrase WITHOUT a parseable reset time is
 * ignored (returns null) so ordinary conversation text mentioning "limit
 * reached" can't arm the scheduler. The downstream retry loop (re-detection
 * after each resume attempt) compensates for any parsing imprecision.
 *
 * All functions are pure (caller passes `now`) for testability.
 *
 * @module usage-limit-patterns
 */
/** Result of scanning terminal output for a usage-limit pause. */
export interface UsageLimitDetection {
    /**
     * Epoch ms when the limit resets. May be in the past when the matched
     * message is stale (caller should treat past values as "retry soon").
     */
    resetAt: number;
    /** Matched message snippet (for logging and UI). */
    matched: string;
}
/**
 * Scan cleaned (ANSI-stripped) terminal output for a usage-limit pause message
 * with a parseable reset time. Returns the LAST parseable occurrence in the
 * chunk (most recent on screen), or null when none is found.
 */
export declare function detectUsageLimitPause(cleanData: string, now?: number): UsageLimitDetection | null;
//# sourceMappingURL=usage-limit-patterns.d.ts.map