import Steel from "steel-sdk"; import type { CaptchaSolveResponse, CaptchaStatusResponse } from "steel-sdk/resources/sessions"; import { type Page } from "playwright-core"; type SessionCreateOptions = Steel.SessionCreateParams; type SessionGotoOptions = Parameters[1]; type SessionWaitForSelectorOptions = Parameters[1]; type SessionClickOptions = Parameters[1]; type SessionTypeOptions = Parameters[2]; type SessionScreenshotOptions = Parameters[0]; type SessionPdfOptions = Parameters[0]; type SessionComputerParams = Steel.SessionComputerParams; type SessionComputerResponse = Steel.SessionComputerResponse; export interface LiveSteelSession { id: string; sessionViewerUrl: string; debugUrl: string; page: Page; goto: (url: string, options?: SessionGotoOptions) => Promise; goBack: (options?: Parameters[0]) => Promise; back: (options?: Parameters[0]) => Promise; url: () => string; title: () => Promise; waitForSelector: (selector: string, options?: SessionWaitForSelectorOptions) => Promise; click: (selector: string, options?: SessionClickOptions) => Promise; fill: (selector: string, text: string) => Promise; type: (selector: string, text: string, options?: SessionTypeOptions) => Promise; evaluate: (fn: (...args: any[]) => T, ...args: any[]) => Promise; locator: (selector: string) => ReturnType; content: () => Promise; screenshot: (options?: SessionScreenshotOptions) => Promise; pdf: (options?: SessionPdfOptions) => Promise; computer: (body: SessionComputerParams) => Promise; captchasStatus: () => Promise; captchasSolve: () => Promise; } export interface SteelClientOptions { apiKey?: string | null; baseURL?: string; sessionTimeoutMs?: number; sessionCreateOptions?: Partial; } export interface SessionRefreshOptions { useProxy?: boolean; proxyUrl?: string | null; } export declare function resolveSessionId(session: Record): string | undefined; export declare function resolveSessionConnectURL(session: Record): string | undefined; export declare function buildSessionConnectURL(session: Record, apiKey?: string | null): string | undefined; export declare function resolveSessionViewerURL(session: Record, viewerBaseURL?: string): string | undefined; export declare function sessionDetails(session: { id: string; sessionViewerUrl?: string | null; }): { sessionId: string; sessionViewerUrl: string; }; export declare class SteelClient { private static readonly DEFAULT_SESSION_TIMEOUT_MS; private readonly client; private readonly apiKey; private readonly sessionTimeoutMs; private readonly sessionCreateOptions; private readonly viewerBaseURL?; private currentSession; private readonly sessions; private creatingSession; constructor(apiKey?: string, options?: SteelClientOptions); getOrCreateSession(): Promise; getCurrentSessionId(): string | null; hasActiveSession(): boolean; isProxyConfigured(): boolean; refreshSession(options?: SessionRefreshOptions): Promise; closeSession(sessionId?: string): Promise; closeAllSessions(): Promise; private resolveSessionCreateOptions; private createSession; private buildLiveSession; } export {};