import type { AutomationRunTelemetry } from '../../automation/runs.js';
import type { DistributedPendingWork, DistributedPeerRecord, DistributedRuntimeManagerState, DistributedWorkPriority, DistributedWorkType } from './distributed-runtime-types.js';
export declare function enqueueDistributedWork(state: DistributedRuntimeManagerState, input: {
    readonly peerId: string;
    readonly type?: DistributedWorkType;
    readonly command: string;
    readonly payload?: unknown;
    readonly priority?: DistributedWorkPriority;
    readonly actor?: string;
    readonly timeoutMs?: number;
    readonly sessionId?: string;
    readonly routeId?: string;
    readonly automationRunId?: string;
    readonly automationJobId?: string;
    readonly approvalId?: string;
    readonly metadata?: Record<string, unknown>;
}): Promise<DistributedPendingWork>;
export declare function invokeDistributedPeer(state: DistributedRuntimeManagerState, input: {
    readonly peerId: string;
    readonly command: string;
    readonly payload?: unknown;
    readonly priority?: DistributedWorkPriority;
    readonly actor?: string;
    readonly waitMs?: number;
    readonly timeoutMs?: number;
    readonly sessionId?: string;
    readonly routeId?: string;
    readonly automationRunId?: string;
    readonly automationJobId?: string;
    readonly approvalId?: string;
    readonly metadata?: Record<string, unknown>;
}): Promise<{
    work: DistributedPendingWork;
    completed: boolean;
}>;
export declare function claimDistributedWork(state: DistributedRuntimeManagerState, auth: {
    readonly peer: DistributedPeerRecord;
    readonly token: {
        readonly id: string;
    };
}, input?: {
    readonly maxItems?: number;
    readonly leaseMs?: number;
}): Promise<DistributedPendingWork[]>;
export declare function completeDistributedWork(state: DistributedRuntimeManagerState, auth: {
    readonly peer: DistributedPeerRecord;
    readonly token: {
        readonly id: string;
    };
}, workId: string, input?: {
    readonly status?: 'completed' | 'failed' | 'cancelled';
    readonly result?: unknown;
    readonly error?: string;
    readonly telemetry?: AutomationRunTelemetry;
    readonly metadata?: Record<string, unknown>;
}): Promise<DistributedPendingWork | null>;
export declare function cancelDistributedWork(state: DistributedRuntimeManagerState, workId: string, input?: {
    readonly actor?: string;
    readonly reason?: string;
}): Promise<DistributedPendingWork | null>;
//# sourceMappingURL=distributed-runtime-work.d.ts.map