import { z } from 'zod'; import { CredentialType } from '@bubblelab/shared-schemas'; /** * CDP Cookie schema matching Chrome DevTools Protocol */ export declare const CDPCookieSchema: z.ZodObject<{ name: z.ZodString; value: z.ZodString; domain: z.ZodString; path: z.ZodString; expires: z.ZodNumber; httpOnly: z.ZodBoolean; secure: z.ZodBoolean; }, "strip", z.ZodTypeAny, { value: string; path: string; name: string; domain: string; expires: number; httpOnly: boolean; secure: boolean; }, { value: string; path: string; name: string; domain: string; expires: number; httpOnly: boolean; secure: boolean; }>; export type CDPCookie = z.infer; /** * Embedded proxy config in browser session credential payload * Backward compatible: old credentials omit proxy entirely */ export declare const BrowserSessionProxySchema: z.ZodOptional; password: z.ZodOptional; }, "strip", z.ZodTypeAny, { server: string; password?: string | undefined; username?: string | undefined; }, { server: string; password?: string | undefined; username?: string | undefined; }>>; /** * Browser session data returned from credential injection * This is what gets decrypted from AMAZON_CRED or similar browser session credentials */ export declare const BrowserSessionDataSchema: z.ZodObject<{ contextId: z.ZodString; cookies: z.ZodArray, "many">; proxy: z.ZodOptional; password: z.ZodOptional; }, "strip", z.ZodTypeAny, { server: string; password?: string | undefined; username?: string | undefined; }, { server: string; password?: string | undefined; username?: string | undefined; }>>; }, "strip", z.ZodTypeAny, { contextId: string; cookies: { value: string; path: string; name: string; domain: string; expires: number; httpOnly: boolean; secure: boolean; }[]; proxy?: { server: string; password?: string | undefined; username?: string | undefined; } | undefined; }, { contextId: string; cookies: { value: string; path: string; name: string; domain: string; expires: number; httpOnly: boolean; secure: boolean; }[]; proxy?: { server: string; password?: string | undefined; username?: string | undefined; } | undefined; }>; export type BrowserSessionData = z.infer; /** * Geolocation configuration for BrowserBase proxies */ export declare const ProxyGeolocationSchema: z.ZodObject<{ city: z.ZodOptional; state: z.ZodOptional; country: z.ZodString; }, "strip", z.ZodTypeAny, { country: string; city?: string | undefined; state?: string | undefined; }, { country: string; city?: string | undefined; state?: string | undefined; }>; export type ProxyGeolocation = z.infer; /** * BrowserBase built-in proxy configuration */ export declare const BrowserbaseProxySchema: z.ZodObject<{ type: z.ZodLiteral<"browserbase">; geolocation: z.ZodOptional; state: z.ZodOptional; country: z.ZodString; }, "strip", z.ZodTypeAny, { country: string; city?: string | undefined; state?: string | undefined; }, { country: string; city?: string | undefined; state?: string | undefined; }>>; domainPattern: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: "browserbase"; geolocation?: { country: string; city?: string | undefined; state?: string | undefined; } | undefined; domainPattern?: string | undefined; }, { type: "browserbase"; geolocation?: { country: string; city?: string | undefined; state?: string | undefined; } | undefined; domainPattern?: string | undefined; }>; export type BrowserbaseProxy = z.infer; /** * External/custom proxy configuration */ export declare const ExternalProxySchema: z.ZodObject<{ type: z.ZodLiteral<"external">; server: z.ZodString; username: z.ZodOptional; password: z.ZodOptional; domainPattern: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: "external"; server: string; password?: string | undefined; username?: string | undefined; domainPattern?: string | undefined; }, { type: "external"; server: string; password?: string | undefined; username?: string | undefined; domainPattern?: string | undefined; }>; export type ExternalProxy = z.infer; /** * Union type for proxy configurations */ export declare const ProxyConfigSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{ type: z.ZodLiteral<"browserbase">; geolocation: z.ZodOptional; state: z.ZodOptional; country: z.ZodString; }, "strip", z.ZodTypeAny, { country: string; city?: string | undefined; state?: string | undefined; }, { country: string; city?: string | undefined; state?: string | undefined; }>>; domainPattern: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: "browserbase"; geolocation?: { country: string; city?: string | undefined; state?: string | undefined; } | undefined; domainPattern?: string | undefined; }, { type: "browserbase"; geolocation?: { country: string; city?: string | undefined; state?: string | undefined; } | undefined; domainPattern?: string | undefined; }>, z.ZodObject<{ type: z.ZodLiteral<"external">; server: z.ZodString; username: z.ZodOptional; password: z.ZodOptional; domainPattern: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: "external"; server: string; password?: string | undefined; username?: string | undefined; domainPattern?: string | undefined; }, { type: "external"; server: string; password?: string | undefined; username?: string | undefined; domainPattern?: string | undefined; }>]>; export type ProxyConfig = z.infer; /** * Stealth mode configuration for BrowserBase sessions */ export declare const StealthConfigSchema: z.ZodObject<{ advancedStealth: z.ZodDefault>; solveCaptchas: z.ZodDefault>; captchaImageSelector: z.ZodOptional; captchaInputSelector: z.ZodOptional; }, "strip", z.ZodTypeAny, { advancedStealth: boolean; solveCaptchas: boolean; captchaImageSelector?: string | undefined; captchaInputSelector?: string | undefined; }, { advancedStealth?: boolean | undefined; solveCaptchas?: boolean | undefined; captchaImageSelector?: string | undefined; captchaInputSelector?: string | undefined; }>; export type StealthConfig = z.infer; /** * BrowserBase service bubble parameters schema * Multi-operation service for browser automation */ export declare const BrowserBaseParamsSchema: z.ZodDiscriminatedUnion<"operation", [z.ZodObject<{ operation: z.ZodLiteral<"start_session">; context_id: z.ZodOptional; cookies: z.ZodOptional, "many">>; viewport_width: z.ZodDefault>; viewport_height: z.ZodDefault>; credentials: z.ZodOptional, z.ZodString>>; proxies: z.ZodOptional, z.ZodArray; geolocation: z.ZodOptional; state: z.ZodOptional; country: z.ZodString; }, "strip", z.ZodTypeAny, { country: string; city?: string | undefined; state?: string | undefined; }, { country: string; city?: string | undefined; state?: string | undefined; }>>; domainPattern: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: "browserbase"; geolocation?: { country: string; city?: string | undefined; state?: string | undefined; } | undefined; domainPattern?: string | undefined; }, { type: "browserbase"; geolocation?: { country: string; city?: string | undefined; state?: string | undefined; } | undefined; domainPattern?: string | undefined; }>, z.ZodObject<{ type: z.ZodLiteral<"external">; server: z.ZodString; username: z.ZodOptional; password: z.ZodOptional; domainPattern: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: "external"; server: string; password?: string | undefined; username?: string | undefined; domainPattern?: string | undefined; }, { type: "external"; server: string; password?: string | undefined; username?: string | undefined; domainPattern?: string | undefined; }>]>, "many">]>>; stealth: z.ZodOptional>; solveCaptchas: z.ZodDefault>; captchaImageSelector: z.ZodOptional; captchaInputSelector: z.ZodOptional; }, "strip", z.ZodTypeAny, { advancedStealth: boolean; solveCaptchas: boolean; captchaImageSelector?: string | undefined; captchaInputSelector?: string | undefined; }, { advancedStealth?: boolean | undefined; solveCaptchas?: boolean | undefined; captchaImageSelector?: string | undefined; captchaInputSelector?: string | undefined; }>>; timeout_seconds: z.ZodOptional; }, "strip", z.ZodTypeAny, { operation: "start_session"; viewport_width: number; viewport_height: number; credentials?: Partial> | undefined; stealth?: { advancedStealth: boolean; solveCaptchas: boolean; captchaImageSelector?: string | undefined; captchaInputSelector?: string | undefined; } | undefined; cookies?: { value: string; path: string; name: string; domain: string; expires: number; httpOnly: boolean; secure: boolean; }[] | undefined; context_id?: string | undefined; proxies?: true | ({ type: "browserbase"; geolocation?: { country: string; city?: string | undefined; state?: string | undefined; } | undefined; domainPattern?: string | undefined; } | { type: "external"; server: string; password?: string | undefined; username?: string | undefined; domainPattern?: string | undefined; })[] | undefined; timeout_seconds?: number | undefined; }, { operation: "start_session"; credentials?: Partial> | undefined; stealth?: { advancedStealth?: boolean | undefined; solveCaptchas?: boolean | undefined; captchaImageSelector?: string | undefined; captchaInputSelector?: string | undefined; } | undefined; cookies?: { value: string; path: string; name: string; domain: string; expires: number; httpOnly: boolean; secure: boolean; }[] | undefined; context_id?: string | undefined; viewport_width?: number | undefined; viewport_height?: number | undefined; proxies?: true | ({ type: "browserbase"; geolocation?: { country: string; city?: string | undefined; state?: string | undefined; } | undefined; domainPattern?: string | undefined; } | { type: "external"; server: string; password?: string | undefined; username?: string | undefined; domainPattern?: string | undefined; })[] | undefined; timeout_seconds?: number | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"navigate">; session_id: z.ZodString; url: z.ZodString; wait_until: z.ZodDefault>>; timeout: z.ZodDefault>; credentials: z.ZodOptional, z.ZodString>>; }, "strip", z.ZodTypeAny, { timeout: number; url: string; operation: "navigate"; session_id: string; wait_until: "load" | "domcontentloaded" | "networkidle0" | "networkidle2"; credentials?: Partial> | undefined; }, { url: string; operation: "navigate"; session_id: string; credentials?: Partial> | undefined; timeout?: number | undefined; wait_until?: "load" | "domcontentloaded" | "networkidle0" | "networkidle2" | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"click">; session_id: z.ZodString; selector: z.ZodString; wait_for_navigation: z.ZodDefault>; timeout: z.ZodDefault>; credentials: z.ZodOptional, z.ZodString>>; }, "strip", z.ZodTypeAny, { timeout: number; operation: "click"; session_id: string; selector: string; wait_for_navigation: boolean; credentials?: Partial> | undefined; }, { operation: "click"; session_id: string; selector: string; credentials?: Partial> | undefined; timeout?: number | undefined; wait_for_navigation?: boolean | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"type">; session_id: z.ZodString; selector: z.ZodString; text: z.ZodString; clear_first: z.ZodDefault>; delay: z.ZodDefault>; credentials: z.ZodOptional, z.ZodString>>; }, "strip", z.ZodTypeAny, { text: string; operation: "type"; session_id: string; selector: string; delay: number; clear_first: boolean; credentials?: Partial> | undefined; }, { text: string; operation: "type"; session_id: string; selector: string; credentials?: Partial> | undefined; delay?: number | undefined; clear_first?: boolean | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"select">; session_id: z.ZodString; selector: z.ZodString; value: z.ZodString; timeout: z.ZodDefault>; credentials: z.ZodOptional, z.ZodString>>; }, "strip", z.ZodTypeAny, { value: string; timeout: number; operation: "select"; session_id: string; selector: string; credentials?: Partial> | undefined; }, { value: string; operation: "select"; session_id: string; selector: string; credentials?: Partial> | undefined; timeout?: number | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"evaluate">; session_id: z.ZodString; script: z.ZodString; credentials: z.ZodOptional, z.ZodString>>; }, "strip", z.ZodTypeAny, { script: string; operation: "evaluate"; session_id: string; credentials?: Partial> | undefined; }, { script: string; operation: "evaluate"; session_id: string; credentials?: Partial> | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"get_content">; session_id: z.ZodString; selector: z.ZodOptional; content_type: z.ZodDefault>>; credentials: z.ZodOptional, z.ZodString>>; }, "strip", z.ZodTypeAny, { operation: "get_content"; session_id: string; content_type: "text" | "html" | "outer_html"; credentials?: Partial> | undefined; selector?: string | undefined; }, { operation: "get_content"; session_id: string; credentials?: Partial> | undefined; content_type?: "text" | "html" | "outer_html" | undefined; selector?: string | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"screenshot">; session_id: z.ZodString; selector: z.ZodOptional; full_page: z.ZodDefault>; format: z.ZodDefault>>; quality: z.ZodOptional; credentials: z.ZodOptional, z.ZodString>>; }, "strip", z.ZodTypeAny, { format: "png" | "webp" | "jpeg"; operation: "screenshot"; session_id: string; full_page: boolean; credentials?: Partial> | undefined; quality?: number | undefined; selector?: string | undefined; }, { operation: "screenshot"; session_id: string; format?: "png" | "webp" | "jpeg" | undefined; credentials?: Partial> | undefined; quality?: number | undefined; selector?: string | undefined; full_page?: boolean | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"wait">; session_id: z.ZodString; wait_type: z.ZodEnum<["selector", "timeout", "navigation"]>; selector: z.ZodOptional; timeout: z.ZodDefault>; credentials: z.ZodOptional, z.ZodString>>; }, "strip", z.ZodTypeAny, { timeout: number; operation: "wait"; session_id: string; wait_type: "timeout" | "selector" | "navigation"; credentials?: Partial> | undefined; selector?: string | undefined; }, { operation: "wait"; session_id: string; wait_type: "timeout" | "selector" | "navigation"; credentials?: Partial> | undefined; timeout?: number | undefined; selector?: string | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"get_cookies">; session_id: z.ZodString; domain_filter: z.ZodOptional; credentials: z.ZodOptional, z.ZodString>>; }, "strip", z.ZodTypeAny, { operation: "get_cookies"; session_id: string; credentials?: Partial> | undefined; domain_filter?: string | undefined; }, { operation: "get_cookies"; session_id: string; credentials?: Partial> | undefined; domain_filter?: string | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"end_session">; session_id: z.ZodString; credentials: z.ZodOptional, z.ZodString>>; }, "strip", z.ZodTypeAny, { operation: "end_session"; session_id: string; credentials?: Partial> | undefined; }, { operation: "end_session"; session_id: string; credentials?: Partial> | undefined; }>]>; /** * BrowserBase result schemas for each operation */ export declare const BrowserBaseResultSchema: z.ZodDiscriminatedUnion<"operation", [z.ZodObject<{ operation: z.ZodLiteral<"start_session">; success: z.ZodBoolean; session_id: z.ZodOptional; context_id: z.ZodOptional; debug_url: z.ZodOptional; error: z.ZodString; }, "strip", z.ZodTypeAny, { error: string; success: boolean; operation: "start_session"; session_id?: string | undefined; context_id?: string | undefined; debug_url?: string | undefined; }, { error: string; success: boolean; operation: "start_session"; session_id?: string | undefined; context_id?: string | undefined; debug_url?: string | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"navigate">; success: z.ZodBoolean; url: z.ZodOptional; error: z.ZodString; }, "strip", z.ZodTypeAny, { error: string; success: boolean; operation: "navigate"; url?: string | undefined; }, { error: string; success: boolean; operation: "navigate"; url?: string | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"click">; success: z.ZodBoolean; error: z.ZodString; }, "strip", z.ZodTypeAny, { error: string; success: boolean; operation: "click"; }, { error: string; success: boolean; operation: "click"; }>, z.ZodObject<{ operation: z.ZodLiteral<"type">; success: z.ZodBoolean; error: z.ZodString; }, "strip", z.ZodTypeAny, { error: string; success: boolean; operation: "type"; }, { error: string; success: boolean; operation: "type"; }>, z.ZodObject<{ operation: z.ZodLiteral<"select">; success: z.ZodBoolean; error: z.ZodString; }, "strip", z.ZodTypeAny, { error: string; success: boolean; operation: "select"; }, { error: string; success: boolean; operation: "select"; }>, z.ZodObject<{ operation: z.ZodLiteral<"evaluate">; success: z.ZodBoolean; result: z.ZodOptional; error: z.ZodString; }, "strip", z.ZodTypeAny, { error: string; success: boolean; operation: "evaluate"; result?: unknown; }, { error: string; success: boolean; operation: "evaluate"; result?: unknown; }>, z.ZodObject<{ operation: z.ZodLiteral<"get_content">; success: z.ZodBoolean; content: z.ZodOptional; error: z.ZodString; }, "strip", z.ZodTypeAny, { error: string; success: boolean; operation: "get_content"; content?: string | undefined; }, { error: string; success: boolean; operation: "get_content"; content?: string | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"screenshot">; success: z.ZodBoolean; data: z.ZodOptional; format: z.ZodOptional; error: z.ZodString; }, "strip", z.ZodTypeAny, { error: string; success: boolean; operation: "screenshot"; format?: string | undefined; data?: string | undefined; }, { error: string; success: boolean; operation: "screenshot"; format?: string | undefined; data?: string | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"wait">; success: z.ZodBoolean; error: z.ZodString; }, "strip", z.ZodTypeAny, { error: string; success: boolean; operation: "wait"; }, { error: string; success: boolean; operation: "wait"; }>, z.ZodObject<{ operation: z.ZodLiteral<"get_cookies">; success: z.ZodBoolean; cookies: z.ZodOptional, "many">>; error: z.ZodString; }, "strip", z.ZodTypeAny, { error: string; success: boolean; operation: "get_cookies"; cookies?: { value: string; path: string; name: string; domain: string; expires: number; httpOnly: boolean; secure: boolean; }[] | undefined; }, { error: string; success: boolean; operation: "get_cookies"; cookies?: { value: string; path: string; name: string; domain: string; expires: number; httpOnly: boolean; secure: boolean; }[] | undefined; }>, z.ZodObject<{ operation: z.ZodLiteral<"end_session">; success: z.ZodBoolean; error: z.ZodString; }, "strip", z.ZodTypeAny, { error: string; success: boolean; operation: "end_session"; }, { error: string; success: boolean; operation: "end_session"; }>]>; export type BrowserBaseParams = z.output; export type BrowserBaseParamsInput = z.input; export type BrowserBaseResult = z.output; //# sourceMappingURL=browserbase.schema.d.ts.map