import type { ToolContext } from "../context.js"; import { z } from "../define-tool.js"; export interface SyncGroupRole { name: string; deviceId: string; } export interface SyncGroup { name: string; roles: SyncGroupRole[]; createdAt: number; ttlTimer: ReturnType; lastRun: SyncRunResult | null; } export interface SyncStep { role: string; action: string; args?: Record; barrier?: string; label?: string; on_error?: "stop" | "skip" | "retry"; } export interface SyncStepResult { role: string; stepIndex: number; action: string; status: "OK" | "FAIL" | "SKIP" | "BARRIER"; message: string; durationMs: number; } export interface SyncRunResult { groupName: string; totalMs: number; results: Map; barrierTimings: Array<{ name: string; role: string; waitedMs: number; }>; success: boolean; } export declare const SYNC_MAX_GROUPS = 5; export declare const SYNC_MAX_ROLES = 10; export declare const SYNC_MAX_STEPS = 30; export declare const SYNC_MAX_DURATION = 120000; export declare const SYNC_BARRIER_TIMEOUT: 30000; export declare const SYNC_TTL_MS: number; export declare const SYNC_ASSERT_MAX_RETRIES = 5; export declare const SYNC_ASSERT_RETRY_DELAY = 500; export declare const SYNC_ASSERT_DEFAULT_DELAY = 1000; export declare const activeGroups: Map; export declare function validateStepArgs(args: Record): void; export declare function isSyncActionAllowed(actionName: string): boolean; export declare function getGroup(name: string): SyncGroup; export declare function getDeviceIdForRole(group: SyncGroup, role: string): string; export declare function destroyGroupInternal(name: string): void; export declare function executeSync(group: SyncGroup, steps: SyncStep[], ctx: ToolContext, depth: number, maxDuration: number): Promise; export declare function formatSyncResult(result: SyncRunResult, group: SyncGroup): string; export declare const roleSchema: z.ZodObject<{ name: z.ZodString; deviceId: z.ZodString; }, z.core.$strip>; export declare const stepSchema: z.ZodObject<{ role: z.ZodString; action: z.ZodString; args: z.ZodOptional>; barrier: z.ZodOptional; label: z.ZodOptional; on_error: z.ZodOptional>; }, z.core.$strip>; //# sourceMappingURL=common.d.ts.map