/// Reads/writes the inventory as a raw (unsealed) interchange snapshot — the
/// same JSON a backup uses, but WITHOUT the file-level sealing, because the sync
/// transport already encrypts on the wire. [SyncService] depends on this
/// interface (not the whole export service) so its logic is fakeable.
abstract interface class InventorySnapshotIO {
  /// The full inventory serialized to interchange bytes.
  Future<List<int>> buildSnapshot();

  /// Merges an incoming snapshot into the local inventory (LWW by HLC,
  /// idempotent — re-applying the same or older state is a no-op).
  Future<void> applySnapshot(List<int> bytes);
}
