Export single contact, nickname

This commit is contained in:
Fedor Indutny
2025-01-08 16:14:04 -08:00
committed by GitHub
parent a877435eea
commit 8c57d243c0
11 changed files with 256 additions and 166 deletions

View File

@@ -21,7 +21,7 @@ message BackupInfo {
// e.g. a Recipient must come before any Chat referencing it.
// 3. All ChatItems must appear in global Chat rendering order.
// (The order in which they were received by the client.)
// 4. ChatFolders must appear in render order (e.g., left to right for
// 4. ChatFolders must appear in render order (e.g., left to right for
// LTR locales), but can appear anywhere relative to other frames respecting
// rule 2 (after Recipients and Chats).
//
@@ -137,7 +137,7 @@ message Contact {
UNVERIFIED = 2;
}
message Registered { }
message Registered {}
message NotRegistered {
uint64 unregisteredTimestamp = 1;
}
@@ -148,6 +148,11 @@ message Contact {
HIDDEN_MESSAGE_REQUEST = 2;
}
message Name {
string given = 1;
string family = 2;
}
optional bytes aci = 1; // should be 16 bytes
optional bytes pni = 2; // should be 16 bytes
optional string username = 3;
@@ -167,6 +172,7 @@ message Contact {
bool hideStory = 13;
optional bytes identityKey = 14;
IdentityState identityState = 15;
Name nickname = 16; // absent iff both `given` and `family` are empty
}
message Group {
@@ -206,7 +212,7 @@ message Group {
message GroupAttributeBlob {
oneof content {
string title = 1;
bytes avatar = 2;
bytes avatar = 2;
uint32 disappearingMessagesDuration = 3;
string descriptionText = 4;
}
@@ -438,7 +444,7 @@ message StandardMessage {
}
message ContactMessage {
repeated ContactAttachment contact = 1;
ContactAttachment contact = 1;
repeated Reaction reactions = 2;
}
@@ -467,14 +473,14 @@ message PaymentNotification {
Status status = 1;
// This identification is used to map the payment table to the ledger
// and is likely required otherwise we may have issues reconciling with
// and is likely required otherwise we may have issues reconciling with
// the ledger
MobileCoinTxoIdentification mobileCoinIdentification = 2;
optional uint64 timestamp = 3;
optional uint64 blockIndex = 4;
optional uint64 blockTimestamp = 5;
optional bytes transaction = 6; // mobile coin blobs
optional bytes receipt = 7; // mobile coin blobs
optional bytes transaction = 6; // mobile coin blobs
optional bytes receipt = 7; // mobile coin blobs
}
oneof payment {
@@ -482,12 +488,11 @@ message PaymentNotification {
FailedTransaction failedTransaction = 2;
}
}
optional string amountMob = 1; // stored as a decimal string, e.g. 1.00001
optional string feeMob = 2; // stored as a decimal string, e.g. 1.00001
optional string note = 3;
TransactionDetails transactionDetails = 4;
}
message GiftBadge {
@@ -510,12 +515,12 @@ message ViewOnceMessage {
message ContactAttachment {
message Name {
optional string givenName = 1;
optional string familyName = 2;
optional string prefix = 3;
optional string suffix = 4;
optional string middleName = 5;
optional string nickname = 6;
string givenName = 1;
string familyName = 2;
string prefix = 3;
string suffix = 4;
string middleName = 5;
string nickname = 6;
}
message Phone {
@@ -527,9 +532,9 @@ message ContactAttachment {
CUSTOM = 4;
}
optional string value = 1;
optional Type type = 2;
optional string label = 3;
string value = 1;
Type type = 2;
string label = 3;
}
message Email {
@@ -541,9 +546,9 @@ message ContactAttachment {
CUSTOM = 4;
}
optional string value = 1;
optional Type type = 2;
optional string label = 3;
string value = 1;
Type type = 2;
string label = 3;
}
message PostalAddress {
@@ -554,15 +559,15 @@ message ContactAttachment {
CUSTOM = 3;
}
optional Type type = 1;
optional string label = 2;
optional string street = 3;
optional string pobox = 4;
optional string neighborhood = 5;
optional string city = 6;
optional string region = 7;
optional string postcode = 8;
optional string country = 9;
Type type = 1;
string label = 2;
string street = 3;
string pobox = 4;
string neighborhood = 5;
string city = 6;
string region = 7;
string postcode = 8;
string country = 9;
}
optional Name name = 1;
@@ -570,7 +575,7 @@ message ContactAttachment {
repeated Email email = 4;
repeated PostalAddress address = 5;
optional FilePointer avatar = 6;
optional string organization = 7;
string organization = 7;
}
message StickerMessage {
@@ -652,7 +657,7 @@ message FilePointer {
}
// References attachments that are invalid in such a way where download
// cannot be attempted. Could range from missing digests to missing
// cannot be attempted. Could range from missing digests to missing
// CDN keys or anything else that makes download attempts impossible.
// This serves as a 'tombstone' so that the UX can show that an attachment
// did exist, but for whatever reason it's not retrievable.
@@ -661,7 +666,7 @@ message FilePointer {
oneof locator {
BackupLocator backupLocator = 1;
AttachmentLocator attachmentLocator= 2;
AttachmentLocator attachmentLocator = 2;
InvalidAttachmentLocator invalidAttachmentLocator = 3;
}
@@ -798,7 +803,7 @@ message GroupCall {
optional uint64 ringerRecipientId = 3;
optional uint64 startedCallRecipientId = 4;
uint64 startedCallTimestamp = 5;
optional uint64 endedCallTimestamp = 6; // The time the call ended.
optional uint64 endedCallTimestamp = 6; // The time the call ended.
bool read = 7;
}
@@ -1072,7 +1077,7 @@ message GroupMemberJoinedByLinkUpdate {
}
// A gv1->gv2 migration occurred.
message GroupV2MigrationUpdate {}
message GroupV2MigrationUpdate {}
// Another user migrated gv1->gv2 but was unable to add
// the local user and invited them instead.
@@ -1236,4 +1241,4 @@ message ChatFolder {
FolderType folderType = 6;
repeated uint64 includedRecipientIds = 7; // generated recipient id of groups, contacts, and/or note to self
repeated uint64 excludedRecipientIds = 8; // generated recipient id of groups, contacts, and/or note to self
}
}