/**
 * Serialized error sentinel returned by host-side bridge callbacks.
 * When a callback throws, the bridge catches the error and returns this
 * sentinel instead of letting it cross the isolate boundary (which strips
 * custom class identity and properties).
 */
export interface ErrorSentinel {
    __isError: true;
    name: string;
    message: string;
    stack?: string;
    extra?: Record<string, unknown>;
}
/**
 * If `value` is an error sentinel from a host-side callback, throw it
 * directly. The isolate's outer try-catch will detect __isError and
 * return it as the result. Error reconstruction happens on the host only.
 */
export declare function throwIfErrorSentinel(value: unknown): void;
/** Returns true if `obj` is a deep lazy proxy created by createDeepLazyProxy. */
export declare function isLazyProxy(obj: unknown): boolean;
/** Returns the basePath the proxy was created with, or undefined if not a proxy. */
export declare function getProxyPath(obj: object): string[] | undefined;
/**
 * Creates a deep lazy-loading proxy for workflow data.
 *
 * This proxy system enables on-demand loading of nested properties across
 * the isolate boundary using metadata-driven callbacks.
 *
 * Pattern:
 * 1. When property accessed: Call getValueAtPath([path]) to get metadata
 * 2. Metadata indicates type: primitive, object, array, or function
 * 3. For objects/arrays: Create nested proxy for lazy loading
 * 4. For functions: Create wrapper that calls callFunctionAtPath
 * 5. Cache all fetched values in target to avoid repeated callbacks
 *
 * @param basePath - Current path in object tree (e.g., ['$json', 'user'])
 * @param knownKeys - Optional pre-known keys for the proxy
 * @param callbacks - ivm.Reference callbacks for cross-isolate communication
 * @returns Proxy object with lazy loading behavior
 */
export declare function createDeepLazyProxy(basePath?: string[], knownKeys?: string[], callbacks?: {
    getValueAtPath: any;
    getArrayElement: any;
    callFunctionAtPath: any;
}): any;
//# sourceMappingURL=lazy-proxy.d.ts.map