import type { UserResponse } from '@playdrop/types';
import type { BrowserContextOptions } from 'playwright-core';
export type CaptureLogLevel = 'debug' | 'info' | 'warn' | 'error';
export declare const CAPTURE_LOG_LEVEL_VALUES: CaptureLogLevel[];
export declare const MAX_CAPTURE_TIMEOUT_SECONDS = 600;
type LoginOptions = {
    username: string;
    password: string;
    loginUrl?: string | null;
};
export type RunCaptureOptions = {
    targetUrl: string;
    expectedUrl?: string | null;
    timeoutMs: number;
    settleAfterReadyMs?: number;
    minimumLogLevel: CaptureLogLevel;
    screenshotPath?: string | null;
    logPath?: string | null;
    contextOptions?: BrowserContextOptions;
    token?: string | null;
    user?: UserResponse | null;
    login?: LoginOptions | null;
    savedSessionBootstrap?: boolean;
    enableCaptureBridge?: boolean;
    requireHostedLaunchReady?: boolean;
    expectedHostedLaunchState?: HostedLaunchExpectedState;
};
export type HostedLaunchExpectedState = 'ready' | 'login_required' | 'controller_required' | 'surface_unsupported';
export type CaptureHostedLaunchState = {
    state: 'ready';
} | {
    state: 'login_required';
} | {
    state: 'controller_required';
} | {
    state: 'surface_unsupported';
} | {
    state: 'error';
    errorCode: string | null;
    message: string | null;
};
export type CaptureRunResult = {
    errorCount: number;
    finalUrl: string;
    hostedLaunchState: CaptureHostedLaunchState | null;
};
export declare function resolveCaptureLogLevel(value: string | undefined): CaptureLogLevel;
export declare function validateCaptureTimeout(value: number | undefined): number;
export declare function runCapture(options: RunCaptureOptions): Promise<CaptureRunResult>;
export {};
