Backup Server APIs
This commit is contained in:
parent
77aea40a63
commit
3eb0e30a23
14 changed files with 991 additions and 201 deletions
4
ts/types/Storage.d.ts
vendored
4
ts/types/Storage.d.ts
vendored
|
@ -18,6 +18,7 @@ import type {
|
|||
SessionResetsType,
|
||||
StorageServiceCredentials,
|
||||
} from '../textsecure/Types.d';
|
||||
import type { BackupCredentialType } from './backups';
|
||||
import type { ServiceIdString } from './ServiceId';
|
||||
|
||||
import type { RegisteredChallengeType } from '../challenge';
|
||||
|
@ -134,6 +135,9 @@ export type StorageAccessType = {
|
|||
unidentifiedDeliveryIndicators: boolean;
|
||||
groupCredentials: ReadonlyArray<GroupCredentialType>;
|
||||
callLinkAuthCredentials: ReadonlyArray<GroupCredentialType>;
|
||||
backupCredentials: ReadonlyArray<BackupCredentialType>;
|
||||
backupCredentialsLastRequestTime: number;
|
||||
setBackupSignatureKey: boolean;
|
||||
lastReceivedAtCounter: number;
|
||||
preferredReactionEmoji: ReadonlyArray<string>;
|
||||
skinTone: number;
|
||||
|
|
20
ts/types/backups.ts
Normal file
20
ts/types/backups.ts
Normal file
|
@ -0,0 +1,20 @@
|
|||
// Copyright 2024 Signal Messenger, LLC
|
||||
// SPDX-License-Identifier: AGPL-3.0-only
|
||||
|
||||
import type { BackupLevel } from '@signalapp/libsignal-client/zkgroup';
|
||||
|
||||
export type BackupCredentialType = Readonly<{
|
||||
credential: string;
|
||||
level: BackupLevel;
|
||||
redemptionTimeMs: number;
|
||||
}>;
|
||||
|
||||
export type BackupPresentationHeadersType = Readonly<{
|
||||
'X-Signal-ZK-Auth': string;
|
||||
'X-Signal-ZK-Auth-Signature': string;
|
||||
}>;
|
||||
|
||||
export type BackupSignedPresentationType = Readonly<{
|
||||
headers: BackupPresentationHeadersType;
|
||||
level: BackupLevel;
|
||||
}>;
|
Loading…
Add table
Add a link
Reference in a new issue