import { ApprovalProcessSnapshot, ApprovalParticipantSnapshot } from '../models/approval-process';
type MaybePromise<T = void> = T | Promise<T>;
interface IApprovableProcess {
    readonly id: string;
    readonly authenticatorParticipant: ApprovalParticipantSnapshot | undefined;
    readonly isAuthenticationComplete: boolean;
    readonly moderatorParticipants: ApprovalParticipantSnapshot[];
    readonly approvalProcess: ApprovalProcessSnapshot;
    withApprovalProcess(ap: ApprovalProcessSnapshot): this;
    withStep(step: any): this;
}
interface IApprovalOperations<P> {
    getApprovals(processId: string): Promise<ApprovalProcessSnapshot>;
    save(process: P): Promise<void>;
    requestApproval(processId: string): Promise<void>;
    notifyApprovalParticipants(processId: string): Promise<void>;
}
export interface ApprovalOrchestratorCallbacks {
    onApprovalsRequested?: () => MaybePromise;
}
export declare class SharedPlanApprovalOrchestrator {
    private pendingApprovalResolve;
    signalApprovalUpdate(): void;
    runApprovalStep<P extends IApprovableProcess>(process: P, operations: IApprovalOperations<P>, callbacks: ApprovalOrchestratorCallbacks, emit: (p: P) => Promise<void>, authStepName: string, isCancelled: () => boolean): Promise<P>;
    private isTerminal;
    private pollUntilComplete;
    private waitForApprovalUpdate;
}
export {};
