export type ClientStatusResult = { state: "available"; value: T; } | { state: "unavailable"; status?: number; stale?: boolean; }; declare global { interface Window { __agentNativeSessionBootstrap?: Promise>; } } /** * One signed-in session answer serves the whole page load: the shell's * bootstrap read, analytics, and every `useSession` consumer share it for this * long. Focus and visibility do not expire it here; `use-session` decides when * a session must be re-read (logout, a peer tab's invalidation, a 401, a stale * answer). A signed-out answer keeps the short TTL, because signing in * elsewhere is exactly what the next focus should pick up. */ export declare const SESSION_RESULT_LIFETIME_MS = 30000; export declare function invalidateClientStatusRequest(path: string): void; /** * Drop a cached result without aborting a read already in flight, so callers * refreshing on the same event share that read instead of starting another. */ export declare function expireClientStatusResult(path: string): void; export declare function invalidateClientStatusRequests(): void; export declare function fetchAgentEngineStatus(options?: { fresh?: boolean; url?: string; fetch?: typeof fetch; headers?: HeadersInit; credentials?: RequestCredentials; }): Promise>; export declare function fetchEnvironmentStatus(): Promise>; export declare function fetchBuilderStatus(): Promise>; export declare function fetchFileUploadStatus(): Promise>; export declare function fetchAuthSessionStatus(): Promise>;