/**
 * Playwright Codegen Manager
 *
 * Manages the lifecycle of Playwright codegen recording sessions.
 */
import { ChildProcess } from 'child_process';
import { TestStep } from '../core';
export interface CodegenSession {
    id: string;
    process: ChildProcess | null;
    outputFile: string;
    url: string;
    status: 'running' | 'completed' | 'error';
    error?: string;
    startedAt: number;
    testIdAttribute?: string;
}
/**
 * Manages Playwright codegen sessions
 */
export declare class CodegenManager {
    private sessions;
    /**
     * Generate a unique session ID
     */
    private generateSessionId;
    /**
     * Start a new recording session
     */
    startRecording(url: string, options?: {
        testIdAttribute?: string;
    }): Promise<string>;
    /**
     * Stop a recording session and get the recorded steps
     */
    stopRecording(sessionId: string): Promise<TestStep[]>;
    /**
     * Get the status of a session
     */
    getStatus(sessionId: string): CodegenSession | undefined;
    /**
     * Clean up a session (remove temp file)
     */
    cleanup(sessionId: string): void;
    /**
     * Clean up all sessions (call on server shutdown)
     */
    cleanupAll(): void;
    /**
     * Get all active sessions
     */
    getActiveSessions(): CodegenSession[];
}
export declare const codegenManager: CodegenManager;
