diff --git a/proto/device_sync/device_sync.proto b/proto/device_sync/device_sync.proto index 4fede5e..e8c1498 100644 --- a/proto/device_sync/device_sync.proto +++ b/proto/device_sync/device_sync.proto @@ -7,8 +7,22 @@ import "device_sync/consent_backup.proto"; message BackupElement { oneof element { - xmtp.device_sync.group_backup.GroupSave group = 1; - xmtp.device_sync.message_backup.GroupMessageSave group_message = 2; - xmtp.device_sync.consent_backup.ConsentSave consent = 3; + BackupMetadata metadata = 1; + xmtp.device_sync.group_backup.GroupSave group = 2; + xmtp.device_sync.message_backup.GroupMessageSave group_message = 3; + xmtp.device_sync.consent_backup.ConsentSave consent = 4; } } + +message BackupMetadata { + uint32 backup_version = 1; + repeated BackupElementSelection elements = 2; + int64 exported_at_ns = 3; + optional int64 start_ns = 4; + optional int64 end_ns = 5; +} + +enum BackupElementSelection { + BACKUP_ELEMENT_SELECTION_MESSAGES = 0; + BACKUP_ELEMENT_SELECTION_CONSENT = 1; +}