import type { AutomationRunTelemetry } from '../../automation/runs.js';
import type { DistributedPendingWork, DistributedRuntimeAuditRecord, DistributedRuntimePairRequest, DistributedPeerRecord, DistributedPeerTokenRecord, StoredPairRequest, StoredPeerRecord, StoredPeerTokenRecord } from './distributed-runtime-types.js';
export declare function hashSecret(secret: string): string;
export declare function matchesSecret(secret: string, expectedHash: string): boolean;
export declare function randomSecret(prefix: string): string;
export declare function fingerprint(secret: string): string;
export declare function coerceStringArray(value: unknown): string[];
export declare function summarizeValue(value: unknown, max?: number): string;
export declare function sortPairRequests<T extends {
    readonly updatedAt: number;
    readonly id: string;
}>(records: Iterable<T>): T[];
export declare function sortPeers<T extends {
    readonly id: string;
    readonly pairedAt: number;
    readonly verifiedAt?: number | undefined;
    readonly lastSeenAt?: number | undefined;
}>(records: Iterable<T>): T[];
export declare function sortWork<T extends DistributedPendingWork>(records: Iterable<T>): T[];
export declare function sanitizePairRequest(request: StoredPairRequest): DistributedRuntimePairRequest;
export declare function sanitizePeer(peer: StoredPeerRecord): DistributedPeerRecord;
export declare function sanitizeToken(token: StoredPeerTokenRecord): DistributedPeerTokenRecord;
export declare function buildAudit(action: DistributedRuntimeAuditRecord['action'], actor: string, input?: {
    readonly peerId?: string | undefined;
    readonly requestId?: string | undefined;
    readonly workId?: string | undefined;
    readonly note?: string | undefined;
    readonly metadata?: Record<string, unknown> | undefined;
}): DistributedRuntimeAuditRecord;
export declare function normalizePairRequest(record: unknown): StoredPairRequest | null;
export declare function normalizeToken(record: unknown): StoredPeerTokenRecord | null;
export declare function normalizePeer(record: unknown): StoredPeerRecord | null;
export declare function normalizeWork(record: unknown): DistributedPendingWork | null;
export declare function normalizeAutomationTelemetry(record: unknown): AutomationRunTelemetry | undefined;
export declare function normalizeAudit(record: unknown): DistributedRuntimeAuditRecord | null;
//# sourceMappingURL=distributed-runtime-utils.d.ts.map