import type { Command } from 'commander';
import { type SessionMeta } from '../lib/session/types.js';
import { type Backend, type EngineContext, type Packing } from '../lib/terminal/index.js';
import { type StrictResumeOptions } from './resume.js';
/** Opening more than this many live sessions at once asks for confirmation first. */
export declare const CONFIRM_THRESHOLD = 5;
export interface ResumeOptions extends StrictResumeOptions {
    agent?: string;
    all?: boolean;
    teams?: boolean;
    since?: string;
    limit?: string;
    device?: string;
    iterm?: boolean;
    ghostty?: boolean;
    tmux?: boolean;
    vscodium?: boolean;
    /** --terminal-app: force macOS Terminal.app. Named to avoid reading as `run --terminal`. */
    terminalApp?: boolean;
    splits?: boolean;
    attachOnly?: boolean;
    local?: boolean;
}
export declare function registerSessionsResumeCommand(sessionsCmd: Command): void;
export declare function sessionsResumeAction(query: string | undefined, prompt: string | undefined, options: ResumeOptions): Promise<void>;
/** IDs and tmux aliases are actions, not picker search text. Human phrases keep
 * the existing pre-filtered picker, while an explicit identity resumes directly. */
export declare function isDirectResumeSelector(query: string): boolean;
/** Re-enter through sessions resume so fleet routing and harness policy
 * stay centralized. The child inherits this terminal for a real interactive resume. */
export declare function resumeSelectorInPlace(selector: string): Promise<void>;
/** Direct identities use focus as the lifecycle dispatcher: it rechecks the
 * live fleet, attaches a healthy pane, and falls through to `agents resume`
 * only when the process is no longer attachable. */
/** True when `sessions resume <id> --attach-only|--local` must go through
 *  `sessions focus` instead of `runStrictResume` (which can fork a copy). */
export declare function resumeUsesLifecycleDispatch(query: string | undefined, prompt: string | undefined, options: Pick<ResumeOptions, 'attachOnly' | 'local' | 'mode' | 'interactive' | 'headless' | 'here'>): boolean;
export declare function dispatchSessionLifecycleInPlace(selector: string, hosts?: string[], attachOnly?: boolean, local?: boolean): Promise<void>;
export declare function buildSessionLifecycleArgs(selector: string, hosts?: string[], attachOnly?: boolean, local?: boolean): string[];
export declare function resolveResumePacking(options: Pick<ResumeOptions, 'splits'>): Packing;
export declare function resumeHostMismatch(session: Pick<SessionMeta, 'shortId' | 'machine'>, requestedHost: string, self?: string): string | null;
/**
 * Decide which backend to launch into. Returns a concrete backend, `'inplace'`
 * (resume in the current process — no GUI/tmux available), or `'cancel'` (the
 * user dismissed the chooser).
 */
export declare function resolveBackend(options: ResumeOptions, ctx: EngineContext, count: number): Promise<Backend | 'inplace' | 'cancel'>;
