import type { BeaconCtx, BeaconPlugin, PluginEntry, PluginStatus } from './types';
export declare class DuplicatePluginNameError extends Error {
    constructor(name: string);
}
export interface RegisteredPlugin {
    plugin: BeaconPlugin;
    ctx: BeaconCtx;
    status: PluginStatus;
    teardown?: () => void;
}
export interface PluginErrorReport {
    plugin: string;
    error: Error;
    at: 'setupOnce' | 'capture' | 'form';
}
export interface Registry {
    readonly entries: RegisteredPlugin[];
    install(makeCtx: (name: string) => BeaconCtx, onError: (e: PluginErrorReport) => void): void;
    destroy(): void;
    capture(getCaptured: (name: string) => PluginEntry | undefined, onError: (e: PluginErrorReport) => void): Promise<Record<string, PluginEntry>>;
    status(): Record<string, PluginStatus>;
}
export declare function createRegistry(plugins: BeaconPlugin[]): Registry;
/**
 * Auto-wrap rule (§6):
 *   plain object        → { v, ...result }
 *   primitive / array   → { v, value: result }
 *   null / undefined    → null (caller omits the entry)
 *   thrown / rejected   → handled by caller via wrapFailure
 */
export declare function wrapResult(result: unknown, version?: number): PluginEntry | null;
export declare function wrapFailure(error: Error): PluginEntry;
//# sourceMappingURL=registry.d.ts.map