import type { FeedbackEnvelope } from '../agent-blackboard/feedback-types.mts'; /** What a dry run validated: the redacted envelope and the scope its token is bound to. */ export type Preview = { sessionId: string; parentSessionId: string | null; mode: 'interactive' | 'autonomous'; worktree: string; sourceEventId: string; envelope: FeedbackEnvelope; warnings: string[]; }; export type PreviewScope = Omit; /** In-memory, single-use preview tokens. A restarted server starts with none. */ export declare class PreviewRegistry { #private; constructor(limit?: number); /** Stores a preview under a fresh 32-byte base64url token, evicting the oldest past the cap. */ put(preview: Preview): string; /** Removes and returns the preview, only when it is bound to exactly this scope. */ take(token: string, scope: PreviewScope): Preview | undefined; /** Stores a preview under a token (a taken one too), evicting the oldest past the cap. */ restore(token: string, preview: Preview): void; clear(): void; } export declare const previewRegistry: PreviewRegistry;