import type { FeedbackBreadcrumb, FeedbackRecentException, FeedbackRecentRequest } from "@opengeni/sdk"; /** As many of each as a feedback report carries. */ export declare const FEEDBACK_TRAIL_LIMITS: { readonly requests: 20; readonly exceptions: 10; readonly breadcrumbs: 30; }; /** An address without its query or fragment; data and blob addresses keep only their scheme. */ export declare function addressWithoutQuery(address: string): string; /** * Start timing one API request; call the result once with its status (null * when no response arrived) and the server's correlation id. A request the app * cancelled itself is not worth reporting: pass aborted. Sending feedback * itself is left out. */ export declare function beginFeedbackRequest(method: string, pathname: string): (status: number | null, detail?: { correlationId?: string | null; aborted?: boolean; }) => void; /** Remember an error nobody caught, a rejected promise nobody handled, or a file that failed to load. */ export declare function recordFeedbackException(input: { kind: FeedbackRecentException["kind"]; message: string; stack?: string | undefined; source?: string | undefined; }): void; /** Remember a step: a screen opened, the app hidden or shown, the network lost or back. */ export declare function recordFeedbackBreadcrumb(kind: FeedbackBreadcrumb["kind"], label: string): void; /** Remember that the page in view changed. */ export declare function recordFeedbackNavigation(pathname: string): void; /** Everything remembered, oldest first in each list. */ export declare function feedbackTrail(): { recentRequests: FeedbackRecentRequest[]; recentExceptions: FeedbackRecentException[]; breadcrumbs: FeedbackBreadcrumb[]; }; /** Tests only. */ export declare function clearFeedbackTrail(): void; type TrailWindow = Pick & { location: { pathname: string; }; document?: { visibilityState?: string; } | undefined; }; /** * Listen for uncaught errors, unhandled rejections, files that fail to load, * the network dropping and the page being hidden. Call once at startup; * navigation is recorded by whoever owns the router (recordFeedbackNavigation). */ export declare function installFeedbackTrail(target: TrailWindow): void; /** The chat a console path shows, such as /workspaces//sessions/. */ export declare function sessionIdInPath(pathname: string): string | undefined; export {};