export type AggregateSyncStatus = "ok" | "partial" | "stale" | "error" | "empty"; export type RiskSeverity = "info" | "warning" | "critical"; export type SyncStateValue = "fresh" | "stale" | "error" | "not_configured" | "unavailable" | "locked"; export type SyncErrorCode = "not_configured" | "auth_expired" | "permission_denied" | "rate_limited" | "timeout" | "network" | "upstream_unavailable" | "schema_changed" | "invalid_data" | "local_source_missing" | "local_io" | "internal"; export interface SyncErrorView { code: SyncErrorCode; retryable: boolean; userActionRequired: boolean; message: string; } export interface ItemSyncView { state: SyncStateValue; observedAt: string | null; lastAttemptAt: string | null; lastSuccessAt: string | null; freshUntil: string | null; staleUntil: string | null; ageSeconds: number | null; source: string; error: SyncErrorView | null; lastRefreshFailed: boolean; } export declare function createSyncError(code: SyncErrorCode, message?: string): SyncErrorView; export declare function syncViewFromFreshness(options: { freshness: "live" | "stale" | "error" | "unavailable" | "not_configured" | "locked"; checkedAt: string | null; generatedAt: string; ttlSeconds?: number | null; source: string; message?: string | null; lastAttemptAt?: string | null; lastSuccessAt?: string | null; freshUntil?: string | null; staleUntil?: string | null; lastRefreshFailed?: boolean; }): ItemSyncView; export declare function summarizeAggregateSync(items: readonly ItemSyncView[]): { status: AggregateSyncStatus; freshCount: number; staleCount: number; errorCount: number; neutralCount: number; lastSuccessAt: string | null; }; export declare function syncStateFromFreshness(freshness: "live" | "stale" | "error" | "unavailable" | "not_configured" | "locked"): SyncStateValue; export declare function isNeutralSyncState(state: SyncStateValue): boolean; //# sourceMappingURL=sync-state.d.ts.map