import type { Context } from '../../context.js';
import type { RuntimeCatalog } from '../../runtime/catalog/publication.js';
import { createEmbedDescriptor } from './descriptor.js';
/** Projects one canonical completed provider into a data-only embed source. */
export declare function createEmbedSource(ctx: Context, catalog: RuntimeCatalog, namespace?: 'embed' | 'local'): {
    /** Reads current detached publication; failed collection remains diagnostic data. */
    getDescriptor(): import("@histoire/protocol").HistoireSourceDescriptor;
    /** Shared provider supplies lazy registered docs without source execution. */
    getDocs: (storyId: string, expectedRevision?: string) => Promise<import("@histoire/protocol").HistoireDocsContent>;
    /** Shared provider supplies lazy raw source without source execution. */
    getSource: (storyId: string, expectedRevision?: string) => Promise<import("@histoire/protocol").HistoireSourceContent>;
    /** Search uses completed portable targets and preferred docs text. */
    getSearch(): import("@histoire/protocol").HistoireSourceSearchData;
    /** Observes coherent catalog/content revisions with caller-owned disposal. */
    subscribe(listener: (descriptor: ReturnType<typeof createEmbedDescriptor>) => void): () => void;
    /** Captured provider used by writer; private handles never enter descriptor. */
    catalog: {
        readonly current: import("../../runtime/catalog/types.js").CatalogSnapshot;
        readonly updating: boolean;
        readonly executionRevision: number;
        markUpdating(): void;
        subscribe(listener: (snapshot: import("../../runtime/catalog/types.js").CatalogSnapshot) => void): () => void;
        publish(ctx: Context, outcomes?: ReadonlyMap<string, import("../../collect/outcome.js").StoryCollectionOutcome>): Promise<import("../../runtime/catalog/types.js").CatalogSnapshot>;
        getStory(storyId: string, expectedRevision?: string): {
            projectId: string;
            revision: string;
            story: import("../../runtime/catalog/types.js").CatalogStory;
        };
        getTarget(storyId: string, variantId: string, expectedRevision?: string): {
            projectId: string;
            revision: string;
            story: import("../../runtime/catalog/types.js").CatalogStory;
            variant: {
                id: string;
                title: string;
            };
        };
    };
};
/** Captures completed build data through canonical engine, without a collector or browser. */
export declare function captureEmbedSource(ctx: Context): Promise<{
    /** Reads current detached publication; failed collection remains diagnostic data. */
    getDescriptor(): import("@histoire/protocol").HistoireSourceDescriptor;
    /** Shared provider supplies lazy registered docs without source execution. */
    getDocs: (storyId: string, expectedRevision?: string) => Promise<import("@histoire/protocol").HistoireDocsContent>;
    /** Shared provider supplies lazy raw source without source execution. */
    getSource: (storyId: string, expectedRevision?: string) => Promise<import("@histoire/protocol").HistoireSourceContent>;
    /** Search uses completed portable targets and preferred docs text. */
    getSearch(): import("@histoire/protocol").HistoireSourceSearchData;
    /** Observes coherent catalog/content revisions with caller-owned disposal. */
    subscribe(listener: (descriptor: ReturnType<typeof createEmbedDescriptor>) => void): () => void;
    /** Captured provider used by writer; private handles never enter descriptor. */
    catalog: {
        readonly current: import("../../runtime/catalog/types.js").CatalogSnapshot;
        readonly updating: boolean;
        readonly executionRevision: number;
        markUpdating(): void;
        subscribe(listener: (snapshot: import("../../runtime/catalog/types.js").CatalogSnapshot) => void): () => void;
        publish(ctx: Context, outcomes?: ReadonlyMap<string, import("../../collect/outcome.js").StoryCollectionOutcome>): Promise<import("../../runtime/catalog/types.js").CatalogSnapshot>;
        getStory(storyId: string, expectedRevision?: string): {
            projectId: string;
            revision: string;
            story: import("../../runtime/catalog/types.js").CatalogStory;
        };
        getTarget(storyId: string, variantId: string, expectedRevision?: string): {
            projectId: string;
            revision: string;
            story: import("../../runtime/catalog/types.js").CatalogStory;
            variant: {
                id: string;
                title: string;
            };
        };
    };
}>;
/** Trusted source document projection consumed by dev routes/build writer. */
export type EmbedSource = ReturnType<typeof createEmbedSource>;
//# sourceMappingURL=source.d.ts.map