import type { FigmaHttpPort } from "./figmaHttpPort.js";
import { type FigmaRetryPolicy, type FigmaRetrySleep } from "./figmaRetry.js";
import { type FigmaNode, type ReadinessSignal } from "./figmaReadiness.js";
import { type FigmaScopeCoverage, type ScopedPaginationLimits } from "./figmaScopedPagination.js";
export interface FigmaConnectorConfig {
    readonly accessToken?: string;
    readonly depth?: number;
    readonly releaseMarker?: string;
    readonly maxNodeCount?: number;
    /**
     * Per-deployment overrides for the deep scoped-pagination budgets (#837). Any omitted field falls
     * back to {@link DEFAULT_SCOPED_PAGINATION_LIMITS}. Generic budgets — never tuned to a sample board.
     */
    readonly pagination?: Partial<ScopedPaginationLimits>;
}
export interface FigmaEnv {
    readonly FIGMA_ACCESS_TOKEN?: string;
}
export interface FigmaConnectorDeps {
    readonly http: FigmaHttpPort;
    readonly env: FigmaEnv;
    readonly config?: FigmaConnectorConfig;
    readonly vaultToken?: string;
    readonly retryPolicy?: FigmaRetryPolicy;
    readonly sleep?: FigmaRetrySleep;
}
export interface FigmaFetchOptions {
    readonly version?: string;
    readonly fetchedAt?: string;
}
export interface FigmaProvenance {
    readonly fileKey: string;
    readonly nodeId: string;
    readonly version: string | undefined;
    readonly fetchedAt: string;
}
export interface FigmaScopedResult {
    readonly nodes: FigmaNode;
    readonly provenance: FigmaProvenance;
    readonly readiness: ReadinessSignal;
    /**
     * Coverage telemetry, present only on the deep (`fetchScopedNodesDeep`) path (#837). Reports how
     * many screens were deep-fetched / truncated and the assembled node + fetch counts, so the build
     * can surface honest coverage instead of silently under-feeding the IR.
     */
    readonly coverage?: FigmaScopeCoverage;
}
export interface FigmaConnector {
    /** Single shallow scoped fetch (depth cap + oversize guard). Backwards-compatible entry point. */
    fetchScopedNodes(url: string, options?: FigmaFetchOptions): Promise<FigmaScopedResult>;
    /**
     * Bounded per-screen scoped-pagination fetch (#837): one shallow discovery fetch to enumerate
     * screens, then a bounded breadth-first deepening of each screen subtree so in-screen text survives
     * into the IR. Stays within the snapshot-build boundary; reports {@link FigmaScopeCoverage}.
     */
    fetchScopedNodesDeep(url: string, options?: FigmaFetchOptions): Promise<FigmaScopedResult>;
}
export declare const createFigmaConnector: (deps: FigmaConnectorDeps) => FigmaConnector;
//# sourceMappingURL=figmaConnector.d.ts.map