Add PNI endpoints to WebAPI

This commit is contained in:
Fedor Indutny 2021-11-30 20:33:51 +01:00 committed by GitHub
parent 7c1ce3366d
commit 348012ef4c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
17 changed files with 321 additions and 210 deletions

View file

@ -23,7 +23,7 @@ import { SenderKeys } from '../LibSignalStores';
import type { LinkPreviewType } from '../types/message/LinkPreviews';
import { MIMETypeToString } from '../types/MIME';
import type * as Attachment from '../types/Attachment';
import type { UUIDStringType } from '../types/UUID';
import type { UUID, UUIDStringType } from '../types/UUID';
import type {
ChallengeType,
GroupCredentialsType,
@ -2039,7 +2039,7 @@ export default class MessageSender {
number: string,
options: Readonly<{
accessKey?: string;
profileKeyVersion?: string;
profileKeyVersion: string;
profileKeyCredentialRequest?: string;
userLanguages: ReadonlyArray<string>;
}>
@ -2057,6 +2057,10 @@ export default class MessageSender {
return this.server.getProfile(number, options);
}
async checkAccountExistence(uuid: UUID): Promise<boolean> {
return this.server.checkAccountExistence(uuid);
}
async getProfileForUsername(
username: string
): ReturnType<WebAPIType['getProfileForUsername']> {