import type { Browser, BrowserContext } from "playwright";
import type { MatrixCell } from "../../schema/src/records/context.js";
import { type ClassifiedRun, type KernelStores } from "../../core/src/classify/classifier.js";
import { type CapabilityProfile } from "../../core/src/sdk/capability.js";
import { type Detector } from "../../core/src/sdk/detector.js";
import type { MatrixPlanResult } from "./matrix.js";
import { type CaptureOptions, type CellEvidence } from "./cell-runner.js";
export type AuthProof = {
    role: string;
    evidence: unknown;
};
export interface AuthAdapter {
    readonly id: string;
    setup(context: BrowserContext, cell: MatrixCell): Promise<AuthProof>;
}
export type AuthAdapterModuleRef = {
    module: string;
    export: string;
};
export declare class AuthAdapterLoadError extends Error {
    readonly module: string;
    readonly exportName: string;
    readonly reason: string;
    readonly cause?: unknown;
    constructor(ref: AuthAdapterModuleRef, reason: string, cause?: unknown);
}
export declare class AuthProofVerificationError extends Error {
    readonly proof: AuthProof;
    readonly cell: MatrixCell;
    constructor(message: string, proof: AuthProof, cell: MatrixCell);
}
export declare function loadAuthAdapters(refs: readonly AuthAdapterModuleRef[]): Promise<AuthAdapter[]>;
export declare function verifyAuthProof(proof: AuthProof, cell: MatrixCell): void;
export type RunMatrixInput = {
    plan: MatrixPlanResult;
    baseUrl: string;
    adapters: Record<string, AuthAdapter>;
    detectors: Detector<CellEvidence, unknown>[];
    stores: KernelStores;
    runId: string;
    seed: string;
    clockStart: string;
    browser: Browser;
    capture: CaptureOptions;
    timeouts: {
        navigateMs: number;
        settleMs: number;
    };
    capabilities?: CapabilityProfile;
    onCellEvidence?: (evidence: CellEvidence) => void;
};
export declare function runMatrix(input: RunMatrixInput): Promise<ClassifiedRun>;
//# sourceMappingURL=auth.d.ts.map