diff --git a/WAProto/WAProto.proto b/WAProto/WAProto.proto index 1d28b5d..652d4a3 100644 --- a/WAProto/WAProto.proto +++ b/WAProto/WAProto.proto @@ -151,7 +151,6 @@ message ClientPayload { repeated int32 shards = 14; optional DNSSource dnsSource = 15; optional uint32 connectAttemptCount = 16; - optional uint32 agent = 17; optional uint32 device = 18; optional CompanionRegData regData = 19; enum ClientPayloadProduct { @@ -162,7 +161,7 @@ message ClientPayload { optional bytes fbCat = 21; optional bytes fbUserAgent = 22; optional bool oc = 23; - optional uint32 lc = 24; + optional int32 lc = 24; enum ClientPayloadIOSAppExtension { SHARE_EXTENSION = 0; SERVICE_EXTENSION = 1; @@ -173,7 +172,8 @@ message ClientPayload { optional bytes fbDeviceId = 32; } -message Details { +// Renamed from Details +message NoiseCertificateDetails { optional uint32 serial = 1; optional string issuer = 2; optional uint64 expires = 3; @@ -253,6 +253,15 @@ message BizAccountPayload { optional bytes bizAcctLinkInfo = 2; } +// Renamed from Details +message VerifiedNameDetails { + optional uint64 serial = 1; + optional string issuer = 2; + optional string verifiedName = 4; + repeated LocalizedName localizedNames = 8; + optional uint64 issueTime = 10; +} + message VerifiedNameCertificate { optional bytes details = 1; optional bytes signature = 2; @@ -685,6 +694,7 @@ message ExternalAdReplyInfo { optional string sourceType = 7; optional string sourceId = 8; optional string sourceUrl = 9; + optional bool containsAutoReply = 10; } message ContextInfo { @@ -1485,7 +1495,8 @@ message DisappearingMode { optional DisappearingModeInitiator initiator = 1; } -message MediaData { +// Renamed from MediaData +message PBMediaData { optional bytes mediaKey = 1; optional int64 mediaKeyTimestamp = 2; optional bytes fileSha256 = 3; @@ -1502,7 +1513,7 @@ message PaymentBackground { optional fixed32 placeholderArgb = 6; optional fixed32 textArgb = 7; optional fixed32 subtextArgb = 8; - optional MediaData mediaData = 9; + optional PBMediaData mediaData = 9; enum PaymentBackgroundType { UNKNOWN = 0; DEFAULT = 1; @@ -1577,6 +1588,15 @@ message Point { optional double y = 4; } +// Duplicate type omitted +//message AppVersion { +// optional uint32 primary = 1; +// optional uint32 secondary = 2; +// optional uint32 tertiary = 3; +// optional uint32 quaternary = 4; +// optional uint32 quinary = 5; +//} + message CompanionProps { optional string os = 1; optional AppVersion version = 2; @@ -1653,12 +1673,21 @@ message UserReceipt { repeated string deliveredDeviceJid = 6; } +message StatusPSA { + required string campaignId = 44; + optional uint64 campaignExpirationTimestamp = 45; +} + message PhotoChange { optional bytes oldPhoto = 1; optional bytes newPhoto = 2; optional uint32 newPhotoId = 3; } +message MediaData { + optional string localPath = 1; +} + message WebFeatures { enum WebFeaturesFlag { NOT_STARTED = 0; @@ -1948,6 +1977,8 @@ message WebMessageInfo { BIZ_PRIVACY_MODE_TO_BSP = 129; DISAPPEARING_MODE = 130; E2E_DEVICE_FETCH_FAILED = 131; + ADMIN_REVOKE = 132; + GROUP_INVITE_LINK_GROWTH_LOCKED = 133; } optional WebMessageInfoStubType messageStubType = 24; optional bool clearMedia = 25; @@ -1975,7 +2006,6 @@ message WebMessageInfo { repeated Reaction reactions = 41; optional MediaData quotedStickerData = 42; optional bytes futureproofData = 43; - optional string statusPsaCampaignId = 44; - optional uint32 statusPsaCampaignDuration = 45; - optional uint64 statusPsaCampaignReadTimestamp = 46; + optional StatusPSA statusPsa = 44; } + diff --git a/WAProto/index.d.ts b/WAProto/index.d.ts index b5e645c..1bd988a 100644 --- a/WAProto/index.d.ts +++ b/WAProto/index.d.ts @@ -871,9 +871,6 @@ export namespace proto { /** ClientPayload connectAttemptCount */ connectAttemptCount?: (number|null); - /** ClientPayload agent */ - agent?: (number|null); - /** ClientPayload device */ device?: (number|null); @@ -950,9 +947,6 @@ export namespace proto { /** ClientPayload connectAttemptCount. */ public connectAttemptCount: number; - /** ClientPayload agent. */ - public agent: number; - /** ClientPayload device. */ public device: number; @@ -1099,115 +1093,115 @@ export namespace proto { } } - /** Properties of a Details. */ - interface IDetails { + /** Properties of a NoiseCertificateDetails. */ + interface INoiseCertificateDetails { - /** Details serial */ + /** NoiseCertificateDetails serial */ serial?: (number|null); - /** Details issuer */ + /** NoiseCertificateDetails issuer */ issuer?: (string|null); - /** Details expires */ + /** NoiseCertificateDetails expires */ expires?: (number|Long|null); - /** Details subject */ + /** NoiseCertificateDetails subject */ subject?: (string|null); - /** Details key */ + /** NoiseCertificateDetails key */ key?: (Uint8Array|null); } - /** Represents a Details. */ - class Details implements IDetails { + /** Represents a NoiseCertificateDetails. */ + class NoiseCertificateDetails implements INoiseCertificateDetails { /** - * Constructs a new Details. + * Constructs a new NoiseCertificateDetails. * @param [properties] Properties to set */ - constructor(properties?: proto.IDetails); + constructor(properties?: proto.INoiseCertificateDetails); - /** Details serial. */ + /** NoiseCertificateDetails serial. */ public serial: number; - /** Details issuer. */ + /** NoiseCertificateDetails issuer. */ public issuer: string; - /** Details expires. */ + /** NoiseCertificateDetails expires. */ public expires: (number|Long); - /** Details subject. */ + /** NoiseCertificateDetails subject. */ public subject: string; - /** Details key. */ + /** NoiseCertificateDetails key. */ public key: Uint8Array; /** - * Creates a new Details instance using the specified properties. + * Creates a new NoiseCertificateDetails instance using the specified properties. * @param [properties] Properties to set - * @returns Details instance + * @returns NoiseCertificateDetails instance */ - public static create(properties?: proto.IDetails): proto.Details; + public static create(properties?: proto.INoiseCertificateDetails): proto.NoiseCertificateDetails; /** - * Encodes the specified Details message. Does not implicitly {@link proto.Details.verify|verify} messages. - * @param message Details message or plain object to encode + * Encodes the specified NoiseCertificateDetails message. Does not implicitly {@link proto.NoiseCertificateDetails.verify|verify} messages. + * @param message NoiseCertificateDetails message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ - public static encode(message: proto.IDetails, writer?: $protobuf.Writer): $protobuf.Writer; + public static encode(message: proto.INoiseCertificateDetails, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Encodes the specified Details message, length delimited. Does not implicitly {@link proto.Details.verify|verify} messages. - * @param message Details message or plain object to encode + * Encodes the specified NoiseCertificateDetails message, length delimited. Does not implicitly {@link proto.NoiseCertificateDetails.verify|verify} messages. + * @param message NoiseCertificateDetails message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ - public static encodeDelimited(message: proto.IDetails, writer?: $protobuf.Writer): $protobuf.Writer; + public static encodeDelimited(message: proto.INoiseCertificateDetails, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Decodes a Details message from the specified reader or buffer. + * Decodes a NoiseCertificateDetails message from the specified reader or buffer. * @param reader Reader or buffer to decode from * @param [length] Message length if known beforehand - * @returns Details + * @returns NoiseCertificateDetails * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): proto.Details; + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): proto.NoiseCertificateDetails; /** - * Decodes a Details message from the specified reader or buffer, length delimited. + * Decodes a NoiseCertificateDetails message from the specified reader or buffer, length delimited. * @param reader Reader or buffer to decode from - * @returns Details + * @returns NoiseCertificateDetails * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): proto.Details; + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): proto.NoiseCertificateDetails; /** - * Verifies a Details message. + * Verifies a NoiseCertificateDetails message. * @param message Plain object to verify * @returns `null` if valid, otherwise the reason why it is not */ public static verify(message: { [k: string]: any }): (string|null); /** - * Creates a Details message from a plain object. Also converts values to their respective internal types. + * Creates a NoiseCertificateDetails message from a plain object. Also converts values to their respective internal types. * @param object Plain object - * @returns Details + * @returns NoiseCertificateDetails */ - public static fromObject(object: { [k: string]: any }): proto.Details; + public static fromObject(object: { [k: string]: any }): proto.NoiseCertificateDetails; /** - * Creates a plain object from a Details message. Also converts values to other types if specified. - * @param message Details + * Creates a plain object from a NoiseCertificateDetails message. Also converts values to other types if specified. + * @param message NoiseCertificateDetails * @param [options] Conversion options * @returns Plain object */ - public static toObject(message: proto.Details, options?: $protobuf.IConversionOptions): { [k: string]: any }; + public static toObject(message: proto.NoiseCertificateDetails, options?: $protobuf.IConversionOptions): { [k: string]: any }; /** - * Converts this Details to JSON. + * Converts this NoiseCertificateDetails to JSON. * @returns JSON object */ public toJSON(): { [k: string]: any }; @@ -2089,6 +2083,120 @@ export namespace proto { public toJSON(): { [k: string]: any }; } + /** Properties of a VerifiedNameDetails. */ + interface IVerifiedNameDetails { + + /** VerifiedNameDetails serial */ + serial?: (number|Long|null); + + /** VerifiedNameDetails issuer */ + issuer?: (string|null); + + /** VerifiedNameDetails verifiedName */ + verifiedName?: (string|null); + + /** VerifiedNameDetails localizedNames */ + localizedNames?: (proto.ILocalizedName[]|null); + + /** VerifiedNameDetails issueTime */ + issueTime?: (number|Long|null); + } + + /** Represents a VerifiedNameDetails. */ + class VerifiedNameDetails implements IVerifiedNameDetails { + + /** + * Constructs a new VerifiedNameDetails. + * @param [properties] Properties to set + */ + constructor(properties?: proto.IVerifiedNameDetails); + + /** VerifiedNameDetails serial. */ + public serial: (number|Long); + + /** VerifiedNameDetails issuer. */ + public issuer: string; + + /** VerifiedNameDetails verifiedName. */ + public verifiedName: string; + + /** VerifiedNameDetails localizedNames. */ + public localizedNames: proto.ILocalizedName[]; + + /** VerifiedNameDetails issueTime. */ + public issueTime: (number|Long); + + /** + * Creates a new VerifiedNameDetails instance using the specified properties. + * @param [properties] Properties to set + * @returns VerifiedNameDetails instance + */ + public static create(properties?: proto.IVerifiedNameDetails): proto.VerifiedNameDetails; + + /** + * Encodes the specified VerifiedNameDetails message. Does not implicitly {@link proto.VerifiedNameDetails.verify|verify} messages. + * @param message VerifiedNameDetails message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: proto.IVerifiedNameDetails, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified VerifiedNameDetails message, length delimited. Does not implicitly {@link proto.VerifiedNameDetails.verify|verify} messages. + * @param message VerifiedNameDetails message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: proto.IVerifiedNameDetails, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a VerifiedNameDetails message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns VerifiedNameDetails + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): proto.VerifiedNameDetails; + + /** + * Decodes a VerifiedNameDetails message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns VerifiedNameDetails + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): proto.VerifiedNameDetails; + + /** + * Verifies a VerifiedNameDetails message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a VerifiedNameDetails message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns VerifiedNameDetails + */ + public static fromObject(object: { [k: string]: any }): proto.VerifiedNameDetails; + + /** + * Creates a plain object from a VerifiedNameDetails message. Also converts values to other types if specified. + * @param message VerifiedNameDetails + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: proto.VerifiedNameDetails, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this VerifiedNameDetails to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + } + /** Properties of a VerifiedNameCertificate. */ interface IVerifiedNameCertificate { @@ -8291,6 +8399,9 @@ export namespace proto { /** ExternalAdReplyInfo sourceUrl */ sourceUrl?: (string|null); + + /** ExternalAdReplyInfo containsAutoReply */ + containsAutoReply?: (boolean|null); } /** Represents an ExternalAdReplyInfo. */ @@ -8329,6 +8440,9 @@ export namespace proto { /** ExternalAdReplyInfo sourceUrl. */ public sourceUrl: string; + /** ExternalAdReplyInfo containsAutoReply. */ + public containsAutoReply: boolean; + /** * Creates a new ExternalAdReplyInfo instance using the specified properties. * @param [properties] Properties to set @@ -17539,115 +17653,115 @@ export namespace proto { } } - /** Properties of a MediaData. */ - interface IMediaData { + /** Properties of a PBMediaData. */ + interface IPBMediaData { - /** MediaData mediaKey */ + /** PBMediaData mediaKey */ mediaKey?: (Uint8Array|null); - /** MediaData mediaKeyTimestamp */ + /** PBMediaData mediaKeyTimestamp */ mediaKeyTimestamp?: (number|Long|null); - /** MediaData fileSha256 */ + /** PBMediaData fileSha256 */ fileSha256?: (Uint8Array|null); - /** MediaData fileEncSha256 */ + /** PBMediaData fileEncSha256 */ fileEncSha256?: (Uint8Array|null); - /** MediaData directPath */ + /** PBMediaData directPath */ directPath?: (string|null); } - /** Represents a MediaData. */ - class MediaData implements IMediaData { + /** Represents a PBMediaData. */ + class PBMediaData implements IPBMediaData { /** - * Constructs a new MediaData. + * Constructs a new PBMediaData. * @param [properties] Properties to set */ - constructor(properties?: proto.IMediaData); + constructor(properties?: proto.IPBMediaData); - /** MediaData mediaKey. */ + /** PBMediaData mediaKey. */ public mediaKey: Uint8Array; - /** MediaData mediaKeyTimestamp. */ + /** PBMediaData mediaKeyTimestamp. */ public mediaKeyTimestamp: (number|Long); - /** MediaData fileSha256. */ + /** PBMediaData fileSha256. */ public fileSha256: Uint8Array; - /** MediaData fileEncSha256. */ + /** PBMediaData fileEncSha256. */ public fileEncSha256: Uint8Array; - /** MediaData directPath. */ + /** PBMediaData directPath. */ public directPath: string; /** - * Creates a new MediaData instance using the specified properties. + * Creates a new PBMediaData instance using the specified properties. * @param [properties] Properties to set - * @returns MediaData instance + * @returns PBMediaData instance */ - public static create(properties?: proto.IMediaData): proto.MediaData; + public static create(properties?: proto.IPBMediaData): proto.PBMediaData; /** - * Encodes the specified MediaData message. Does not implicitly {@link proto.MediaData.verify|verify} messages. - * @param message MediaData message or plain object to encode + * Encodes the specified PBMediaData message. Does not implicitly {@link proto.PBMediaData.verify|verify} messages. + * @param message PBMediaData message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ - public static encode(message: proto.IMediaData, writer?: $protobuf.Writer): $protobuf.Writer; + public static encode(message: proto.IPBMediaData, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Encodes the specified MediaData message, length delimited. Does not implicitly {@link proto.MediaData.verify|verify} messages. - * @param message MediaData message or plain object to encode + * Encodes the specified PBMediaData message, length delimited. Does not implicitly {@link proto.PBMediaData.verify|verify} messages. + * @param message PBMediaData message or plain object to encode * @param [writer] Writer to encode to * @returns Writer */ - public static encodeDelimited(message: proto.IMediaData, writer?: $protobuf.Writer): $protobuf.Writer; + public static encodeDelimited(message: proto.IPBMediaData, writer?: $protobuf.Writer): $protobuf.Writer; /** - * Decodes a MediaData message from the specified reader or buffer. + * Decodes a PBMediaData message from the specified reader or buffer. * @param reader Reader or buffer to decode from * @param [length] Message length if known beforehand - * @returns MediaData + * @returns PBMediaData * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): proto.MediaData; + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): proto.PBMediaData; /** - * Decodes a MediaData message from the specified reader or buffer, length delimited. + * Decodes a PBMediaData message from the specified reader or buffer, length delimited. * @param reader Reader or buffer to decode from - * @returns MediaData + * @returns PBMediaData * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): proto.MediaData; + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): proto.PBMediaData; /** - * Verifies a MediaData message. + * Verifies a PBMediaData message. * @param message Plain object to verify * @returns `null` if valid, otherwise the reason why it is not */ public static verify(message: { [k: string]: any }): (string|null); /** - * Creates a MediaData message from a plain object. Also converts values to their respective internal types. + * Creates a PBMediaData message from a plain object. Also converts values to their respective internal types. * @param object Plain object - * @returns MediaData + * @returns PBMediaData */ - public static fromObject(object: { [k: string]: any }): proto.MediaData; + public static fromObject(object: { [k: string]: any }): proto.PBMediaData; /** - * Creates a plain object from a MediaData message. Also converts values to other types if specified. - * @param message MediaData + * Creates a plain object from a PBMediaData message. Also converts values to other types if specified. + * @param message PBMediaData * @param [options] Conversion options * @returns Plain object */ - public static toObject(message: proto.MediaData, options?: $protobuf.IConversionOptions): { [k: string]: any }; + public static toObject(message: proto.PBMediaData, options?: $protobuf.IConversionOptions): { [k: string]: any }; /** - * Converts this MediaData to JSON. + * Converts this PBMediaData to JSON. * @returns JSON object */ public toJSON(): { [k: string]: any }; @@ -17681,7 +17795,7 @@ export namespace proto { subtextArgb?: (number|null); /** PaymentBackground mediaData */ - mediaData?: (proto.IMediaData|null); + mediaData?: (proto.IPBMediaData|null); /** PaymentBackground type */ type?: (proto.PaymentBackground.PaymentBackgroundType|null); @@ -17721,7 +17835,7 @@ export namespace proto { public subtextArgb: number; /** PaymentBackground mediaData. */ - public mediaData?: (proto.IMediaData|null); + public mediaData?: (proto.IPBMediaData|null); /** PaymentBackground type. */ public type: proto.PaymentBackground.PaymentBackgroundType; @@ -19896,6 +20010,102 @@ export namespace proto { public toJSON(): { [k: string]: any }; } + /** Properties of a StatusPSA. */ + interface IStatusPSA { + + /** StatusPSA campaignId */ + campaignId: string; + + /** StatusPSA campaignExpirationTimestamp */ + campaignExpirationTimestamp?: (number|Long|null); + } + + /** Represents a StatusPSA. */ + class StatusPSA implements IStatusPSA { + + /** + * Constructs a new StatusPSA. + * @param [properties] Properties to set + */ + constructor(properties?: proto.IStatusPSA); + + /** StatusPSA campaignId. */ + public campaignId: string; + + /** StatusPSA campaignExpirationTimestamp. */ + public campaignExpirationTimestamp: (number|Long); + + /** + * Creates a new StatusPSA instance using the specified properties. + * @param [properties] Properties to set + * @returns StatusPSA instance + */ + public static create(properties?: proto.IStatusPSA): proto.StatusPSA; + + /** + * Encodes the specified StatusPSA message. Does not implicitly {@link proto.StatusPSA.verify|verify} messages. + * @param message StatusPSA message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: proto.IStatusPSA, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified StatusPSA message, length delimited. Does not implicitly {@link proto.StatusPSA.verify|verify} messages. + * @param message StatusPSA message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: proto.IStatusPSA, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a StatusPSA message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns StatusPSA + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): proto.StatusPSA; + + /** + * Decodes a StatusPSA message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns StatusPSA + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): proto.StatusPSA; + + /** + * Verifies a StatusPSA message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a StatusPSA message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns StatusPSA + */ + public static fromObject(object: { [k: string]: any }): proto.StatusPSA; + + /** + * Creates a plain object from a StatusPSA message. Also converts values to other types if specified. + * @param message StatusPSA + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: proto.StatusPSA, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this StatusPSA to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + } + /** Properties of a PhotoChange. */ interface IPhotoChange { @@ -19998,6 +20208,96 @@ export namespace proto { public toJSON(): { [k: string]: any }; } + /** Properties of a MediaData. */ + interface IMediaData { + + /** MediaData localPath */ + localPath?: (string|null); + } + + /** Represents a MediaData. */ + class MediaData implements IMediaData { + + /** + * Constructs a new MediaData. + * @param [properties] Properties to set + */ + constructor(properties?: proto.IMediaData); + + /** MediaData localPath. */ + public localPath: string; + + /** + * Creates a new MediaData instance using the specified properties. + * @param [properties] Properties to set + * @returns MediaData instance + */ + public static create(properties?: proto.IMediaData): proto.MediaData; + + /** + * Encodes the specified MediaData message. Does not implicitly {@link proto.MediaData.verify|verify} messages. + * @param message MediaData message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encode(message: proto.IMediaData, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Encodes the specified MediaData message, length delimited. Does not implicitly {@link proto.MediaData.verify|verify} messages. + * @param message MediaData message or plain object to encode + * @param [writer] Writer to encode to + * @returns Writer + */ + public static encodeDelimited(message: proto.IMediaData, writer?: $protobuf.Writer): $protobuf.Writer; + + /** + * Decodes a MediaData message from the specified reader or buffer. + * @param reader Reader or buffer to decode from + * @param [length] Message length if known beforehand + * @returns MediaData + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): proto.MediaData; + + /** + * Decodes a MediaData message from the specified reader or buffer, length delimited. + * @param reader Reader or buffer to decode from + * @returns MediaData + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): proto.MediaData; + + /** + * Verifies a MediaData message. + * @param message Plain object to verify + * @returns `null` if valid, otherwise the reason why it is not + */ + public static verify(message: { [k: string]: any }): (string|null); + + /** + * Creates a MediaData message from a plain object. Also converts values to their respective internal types. + * @param object Plain object + * @returns MediaData + */ + public static fromObject(object: { [k: string]: any }): proto.MediaData; + + /** + * Creates a plain object from a MediaData message. Also converts values to other types if specified. + * @param message MediaData + * @param [options] Conversion options + * @returns Plain object + */ + public static toObject(message: proto.MediaData, options?: $protobuf.IConversionOptions): { [k: string]: any }; + + /** + * Converts this MediaData to JSON. + * @returns JSON object + */ + public toJSON(): { [k: string]: any }; + } + /** Properties of a WebFeatures. */ interface IWebFeatures { @@ -20904,14 +21204,8 @@ export namespace proto { /** WebMessageInfo futureproofData */ futureproofData?: (Uint8Array|null); - /** WebMessageInfo statusPsaCampaignId */ - statusPsaCampaignId?: (string|null); - - /** WebMessageInfo statusPsaCampaignDuration */ - statusPsaCampaignDuration?: (number|null); - - /** WebMessageInfo statusPsaCampaignReadTimestamp */ - statusPsaCampaignReadTimestamp?: (number|Long|null); + /** WebMessageInfo statusPsa */ + statusPsa?: (proto.IStatusPSA|null); } /** Represents a WebMessageInfo. */ @@ -21025,14 +21319,8 @@ export namespace proto { /** WebMessageInfo futureproofData. */ public futureproofData: Uint8Array; - /** WebMessageInfo statusPsaCampaignId. */ - public statusPsaCampaignId: string; - - /** WebMessageInfo statusPsaCampaignDuration. */ - public statusPsaCampaignDuration: number; - - /** WebMessageInfo statusPsaCampaignReadTimestamp. */ - public statusPsaCampaignReadTimestamp: (number|Long); + /** WebMessageInfo statusPsa. */ + public statusPsa?: (proto.IStatusPSA|null); /** * Creates a new WebMessageInfo instance using the specified properties. @@ -21250,7 +21538,9 @@ export namespace proto { BIZ_PRIVACY_MODE_TO_FB = 128, BIZ_PRIVACY_MODE_TO_BSP = 129, DISAPPEARING_MODE = 130, - E2E_DEVICE_FETCH_FAILED = 131 + E2E_DEVICE_FETCH_FAILED = 131, + ADMIN_REVOKE = 132, + GROUP_INVITE_LINK_GROWTH_LOCKED = 133 } /** WebMessageInfoBizPrivacyStatus enum. */ diff --git a/WAProto/index.js b/WAProto/index.js index fa9f78b..0af8a11 100644 --- a/WAProto/index.js +++ b/WAProto/index.js @@ -2422,7 +2422,6 @@ $root.proto = (function() { * @property {Array.|null} [shards] ClientPayload shards * @property {proto.IDNSSource|null} [dnsSource] ClientPayload dnsSource * @property {number|null} [connectAttemptCount] ClientPayload connectAttemptCount - * @property {number|null} [agent] ClientPayload agent * @property {number|null} [device] ClientPayload device * @property {proto.ICompanionRegData|null} [regData] ClientPayload regData * @property {proto.ClientPayload.ClientPayloadProduct|null} [product] ClientPayload product @@ -2547,14 +2546,6 @@ $root.proto = (function() { */ ClientPayload.prototype.connectAttemptCount = 0; - /** - * ClientPayload agent. - * @member {number} agent - * @memberof proto.ClientPayload - * @instance - */ - ClientPayload.prototype.agent = 0; - /** * ClientPayload device. * @member {number} device @@ -2684,8 +2675,6 @@ $root.proto = (function() { $root.proto.DNSSource.encode(message.dnsSource, writer.uint32(/* id 15, wireType 2 =*/122).fork()).ldelim(); if (message.connectAttemptCount != null && Object.hasOwnProperty.call(message, "connectAttemptCount")) writer.uint32(/* id 16, wireType 0 =*/128).uint32(message.connectAttemptCount); - if (message.agent != null && Object.hasOwnProperty.call(message, "agent")) - writer.uint32(/* id 17, wireType 0 =*/136).uint32(message.agent); if (message.device != null && Object.hasOwnProperty.call(message, "device")) writer.uint32(/* id 18, wireType 0 =*/144).uint32(message.device); if (message.regData != null && Object.hasOwnProperty.call(message, "regData")) @@ -2699,7 +2688,7 @@ $root.proto = (function() { if (message.oc != null && Object.hasOwnProperty.call(message, "oc")) writer.uint32(/* id 23, wireType 0 =*/184).bool(message.oc); if (message.lc != null && Object.hasOwnProperty.call(message, "lc")) - writer.uint32(/* id 24, wireType 0 =*/192).uint32(message.lc); + writer.uint32(/* id 24, wireType 0 =*/192).int32(message.lc); if (message.iosAppExtension != null && Object.hasOwnProperty.call(message, "iosAppExtension")) writer.uint32(/* id 30, wireType 0 =*/240).int32(message.iosAppExtension); if (message.fbAppId != null && Object.hasOwnProperty.call(message, "fbAppId")) @@ -2783,9 +2772,6 @@ $root.proto = (function() { case 16: message.connectAttemptCount = reader.uint32(); break; - case 17: - message.agent = reader.uint32(); - break; case 18: message.device = reader.uint32(); break; @@ -2805,7 +2791,7 @@ $root.proto = (function() { message.oc = reader.bool(); break; case 24: - message.lc = reader.uint32(); + message.lc = reader.int32(); break; case 30: message.iosAppExtension = reader.int32(); @@ -2924,9 +2910,6 @@ $root.proto = (function() { if (message.connectAttemptCount != null && message.hasOwnProperty("connectAttemptCount")) if (!$util.isInteger(message.connectAttemptCount)) return "connectAttemptCount: integer expected"; - if (message.agent != null && message.hasOwnProperty("agent")) - if (!$util.isInteger(message.agent)) - return "agent: integer expected"; if (message.device != null && message.hasOwnProperty("device")) if (!$util.isInteger(message.device)) return "device: integer expected"; @@ -3114,8 +3097,6 @@ $root.proto = (function() { } if (object.connectAttemptCount != null) message.connectAttemptCount = object.connectAttemptCount >>> 0; - if (object.agent != null) - message.agent = object.agent >>> 0; if (object.device != null) message.device = object.device >>> 0; if (object.regData != null) { @@ -3146,7 +3127,7 @@ $root.proto = (function() { if (object.oc != null) message.oc = Boolean(object.oc); if (object.lc != null) - message.lc = object.lc >>> 0; + message.lc = object.lc | 0; switch (object.iosAppExtension) { case "SHARE_EXTENSION": case 0: @@ -3209,7 +3190,6 @@ $root.proto = (function() { object.connectReason = options.enums === String ? "PUSH" : 0; object.dnsSource = null; object.connectAttemptCount = 0; - object.agent = 0; object.device = 0; object.regData = null; object.product = options.enums === String ? "WHATSAPP" : 0; @@ -3273,8 +3253,6 @@ $root.proto = (function() { object.dnsSource = $root.proto.DNSSource.toObject(message.dnsSource, options); if (message.connectAttemptCount != null && message.hasOwnProperty("connectAttemptCount")) object.connectAttemptCount = message.connectAttemptCount; - if (message.agent != null && message.hasOwnProperty("agent")) - object.agent = message.agent; if (message.device != null && message.hasOwnProperty("device")) object.device = message.device; if (message.regData != null && message.hasOwnProperty("regData")) @@ -3407,28 +3385,28 @@ $root.proto = (function() { return ClientPayload; })(); - proto.Details = (function() { + proto.NoiseCertificateDetails = (function() { /** - * Properties of a Details. + * Properties of a NoiseCertificateDetails. * @memberof proto - * @interface IDetails - * @property {number|null} [serial] Details serial - * @property {string|null} [issuer] Details issuer - * @property {number|Long|null} [expires] Details expires - * @property {string|null} [subject] Details subject - * @property {Uint8Array|null} [key] Details key + * @interface INoiseCertificateDetails + * @property {number|null} [serial] NoiseCertificateDetails serial + * @property {string|null} [issuer] NoiseCertificateDetails issuer + * @property {number|Long|null} [expires] NoiseCertificateDetails expires + * @property {string|null} [subject] NoiseCertificateDetails subject + * @property {Uint8Array|null} [key] NoiseCertificateDetails key */ /** - * Constructs a new Details. + * Constructs a new NoiseCertificateDetails. * @memberof proto - * @classdesc Represents a Details. - * @implements IDetails + * @classdesc Represents a NoiseCertificateDetails. + * @implements INoiseCertificateDetails * @constructor - * @param {proto.IDetails=} [properties] Properties to set + * @param {proto.INoiseCertificateDetails=} [properties] Properties to set */ - function Details(properties) { + function NoiseCertificateDetails(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -3436,67 +3414,67 @@ $root.proto = (function() { } /** - * Details serial. + * NoiseCertificateDetails serial. * @member {number} serial - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @instance */ - Details.prototype.serial = 0; + NoiseCertificateDetails.prototype.serial = 0; /** - * Details issuer. + * NoiseCertificateDetails issuer. * @member {string} issuer - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @instance */ - Details.prototype.issuer = ""; + NoiseCertificateDetails.prototype.issuer = ""; /** - * Details expires. + * NoiseCertificateDetails expires. * @member {number|Long} expires - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @instance */ - Details.prototype.expires = $util.Long ? $util.Long.fromBits(0,0,true) : 0; + NoiseCertificateDetails.prototype.expires = $util.Long ? $util.Long.fromBits(0,0,true) : 0; /** - * Details subject. + * NoiseCertificateDetails subject. * @member {string} subject - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @instance */ - Details.prototype.subject = ""; + NoiseCertificateDetails.prototype.subject = ""; /** - * Details key. + * NoiseCertificateDetails key. * @member {Uint8Array} key - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @instance */ - Details.prototype.key = $util.newBuffer([]); + NoiseCertificateDetails.prototype.key = $util.newBuffer([]); /** - * Creates a new Details instance using the specified properties. + * Creates a new NoiseCertificateDetails instance using the specified properties. * @function create - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @static - * @param {proto.IDetails=} [properties] Properties to set - * @returns {proto.Details} Details instance + * @param {proto.INoiseCertificateDetails=} [properties] Properties to set + * @returns {proto.NoiseCertificateDetails} NoiseCertificateDetails instance */ - Details.create = function create(properties) { - return new Details(properties); + NoiseCertificateDetails.create = function create(properties) { + return new NoiseCertificateDetails(properties); }; /** - * Encodes the specified Details message. Does not implicitly {@link proto.Details.verify|verify} messages. + * Encodes the specified NoiseCertificateDetails message. Does not implicitly {@link proto.NoiseCertificateDetails.verify|verify} messages. * @function encode - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @static - * @param {proto.IDetails} message Details message or plain object to encode + * @param {proto.INoiseCertificateDetails} message NoiseCertificateDetails message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Details.encode = function encode(message, writer) { + NoiseCertificateDetails.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.serial != null && Object.hasOwnProperty.call(message, "serial")) @@ -3513,33 +3491,33 @@ $root.proto = (function() { }; /** - * Encodes the specified Details message, length delimited. Does not implicitly {@link proto.Details.verify|verify} messages. + * Encodes the specified NoiseCertificateDetails message, length delimited. Does not implicitly {@link proto.NoiseCertificateDetails.verify|verify} messages. * @function encodeDelimited - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @static - * @param {proto.IDetails} message Details message or plain object to encode + * @param {proto.INoiseCertificateDetails} message NoiseCertificateDetails message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - Details.encodeDelimited = function encodeDelimited(message, writer) { + NoiseCertificateDetails.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a Details message from the specified reader or buffer. + * Decodes a NoiseCertificateDetails message from the specified reader or buffer. * @function decode - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {proto.Details} Details + * @returns {proto.NoiseCertificateDetails} NoiseCertificateDetails * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Details.decode = function decode(reader, length) { + NoiseCertificateDetails.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.proto.Details(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.proto.NoiseCertificateDetails(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -3567,30 +3545,30 @@ $root.proto = (function() { }; /** - * Decodes a Details message from the specified reader or buffer, length delimited. + * Decodes a NoiseCertificateDetails message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {proto.Details} Details + * @returns {proto.NoiseCertificateDetails} NoiseCertificateDetails * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - Details.decodeDelimited = function decodeDelimited(reader) { + NoiseCertificateDetails.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a Details message. + * Verifies a NoiseCertificateDetails message. * @function verify - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - Details.verify = function verify(message) { + NoiseCertificateDetails.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.serial != null && message.hasOwnProperty("serial")) @@ -3612,17 +3590,17 @@ $root.proto = (function() { }; /** - * Creates a Details message from a plain object. Also converts values to their respective internal types. + * Creates a NoiseCertificateDetails message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @static * @param {Object.} object Plain object - * @returns {proto.Details} Details + * @returns {proto.NoiseCertificateDetails} NoiseCertificateDetails */ - Details.fromObject = function fromObject(object) { - if (object instanceof $root.proto.Details) + NoiseCertificateDetails.fromObject = function fromObject(object) { + if (object instanceof $root.proto.NoiseCertificateDetails) return object; - var message = new $root.proto.Details(); + var message = new $root.proto.NoiseCertificateDetails(); if (object.serial != null) message.serial = object.serial >>> 0; if (object.issuer != null) @@ -3647,15 +3625,15 @@ $root.proto = (function() { }; /** - * Creates a plain object from a Details message. Also converts values to other types if specified. + * Creates a plain object from a NoiseCertificateDetails message. Also converts values to other types if specified. * @function toObject - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @static - * @param {proto.Details} message Details + * @param {proto.NoiseCertificateDetails} message NoiseCertificateDetails * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - Details.toObject = function toObject(message, options) { + NoiseCertificateDetails.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; @@ -3693,17 +3671,17 @@ $root.proto = (function() { }; /** - * Converts this Details to JSON. + * Converts this NoiseCertificateDetails to JSON. * @function toJSON - * @memberof proto.Details + * @memberof proto.NoiseCertificateDetails * @instance * @returns {Object.} JSON object */ - Details.prototype.toJSON = function toJSON() { + NoiseCertificateDetails.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; - return Details; + return NoiseCertificateDetails; })(); proto.NoiseCertificate = (function() { @@ -5965,6 +5943,332 @@ $root.proto = (function() { return BizAccountPayload; })(); + proto.VerifiedNameDetails = (function() { + + /** + * Properties of a VerifiedNameDetails. + * @memberof proto + * @interface IVerifiedNameDetails + * @property {number|Long|null} [serial] VerifiedNameDetails serial + * @property {string|null} [issuer] VerifiedNameDetails issuer + * @property {string|null} [verifiedName] VerifiedNameDetails verifiedName + * @property {Array.|null} [localizedNames] VerifiedNameDetails localizedNames + * @property {number|Long|null} [issueTime] VerifiedNameDetails issueTime + */ + + /** + * Constructs a new VerifiedNameDetails. + * @memberof proto + * @classdesc Represents a VerifiedNameDetails. + * @implements IVerifiedNameDetails + * @constructor + * @param {proto.IVerifiedNameDetails=} [properties] Properties to set + */ + function VerifiedNameDetails(properties) { + this.localizedNames = []; + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * VerifiedNameDetails serial. + * @member {number|Long} serial + * @memberof proto.VerifiedNameDetails + * @instance + */ + VerifiedNameDetails.prototype.serial = $util.Long ? $util.Long.fromBits(0,0,true) : 0; + + /** + * VerifiedNameDetails issuer. + * @member {string} issuer + * @memberof proto.VerifiedNameDetails + * @instance + */ + VerifiedNameDetails.prototype.issuer = ""; + + /** + * VerifiedNameDetails verifiedName. + * @member {string} verifiedName + * @memberof proto.VerifiedNameDetails + * @instance + */ + VerifiedNameDetails.prototype.verifiedName = ""; + + /** + * VerifiedNameDetails localizedNames. + * @member {Array.} localizedNames + * @memberof proto.VerifiedNameDetails + * @instance + */ + VerifiedNameDetails.prototype.localizedNames = $util.emptyArray; + + /** + * VerifiedNameDetails issueTime. + * @member {number|Long} issueTime + * @memberof proto.VerifiedNameDetails + * @instance + */ + VerifiedNameDetails.prototype.issueTime = $util.Long ? $util.Long.fromBits(0,0,true) : 0; + + /** + * Creates a new VerifiedNameDetails instance using the specified properties. + * @function create + * @memberof proto.VerifiedNameDetails + * @static + * @param {proto.IVerifiedNameDetails=} [properties] Properties to set + * @returns {proto.VerifiedNameDetails} VerifiedNameDetails instance + */ + VerifiedNameDetails.create = function create(properties) { + return new VerifiedNameDetails(properties); + }; + + /** + * Encodes the specified VerifiedNameDetails message. Does not implicitly {@link proto.VerifiedNameDetails.verify|verify} messages. + * @function encode + * @memberof proto.VerifiedNameDetails + * @static + * @param {proto.IVerifiedNameDetails} message VerifiedNameDetails message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + VerifiedNameDetails.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.serial != null && Object.hasOwnProperty.call(message, "serial")) + writer.uint32(/* id 1, wireType 0 =*/8).uint64(message.serial); + if (message.issuer != null && Object.hasOwnProperty.call(message, "issuer")) + writer.uint32(/* id 2, wireType 2 =*/18).string(message.issuer); + if (message.verifiedName != null && Object.hasOwnProperty.call(message, "verifiedName")) + writer.uint32(/* id 4, wireType 2 =*/34).string(message.verifiedName); + if (message.localizedNames != null && message.localizedNames.length) + for (var i = 0; i < message.localizedNames.length; ++i) + $root.proto.LocalizedName.encode(message.localizedNames[i], writer.uint32(/* id 8, wireType 2 =*/66).fork()).ldelim(); + if (message.issueTime != null && Object.hasOwnProperty.call(message, "issueTime")) + writer.uint32(/* id 10, wireType 0 =*/80).uint64(message.issueTime); + return writer; + }; + + /** + * Encodes the specified VerifiedNameDetails message, length delimited. Does not implicitly {@link proto.VerifiedNameDetails.verify|verify} messages. + * @function encodeDelimited + * @memberof proto.VerifiedNameDetails + * @static + * @param {proto.IVerifiedNameDetails} message VerifiedNameDetails message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + VerifiedNameDetails.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a VerifiedNameDetails message from the specified reader or buffer. + * @function decode + * @memberof proto.VerifiedNameDetails + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {proto.VerifiedNameDetails} VerifiedNameDetails + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + VerifiedNameDetails.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.proto.VerifiedNameDetails(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: + message.serial = reader.uint64(); + break; + case 2: + message.issuer = reader.string(); + break; + case 4: + message.verifiedName = reader.string(); + break; + case 8: + if (!(message.localizedNames && message.localizedNames.length)) + message.localizedNames = []; + message.localizedNames.push($root.proto.LocalizedName.decode(reader, reader.uint32())); + break; + case 10: + message.issueTime = reader.uint64(); + break; + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a VerifiedNameDetails message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof proto.VerifiedNameDetails + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {proto.VerifiedNameDetails} VerifiedNameDetails + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + VerifiedNameDetails.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a VerifiedNameDetails message. + * @function verify + * @memberof proto.VerifiedNameDetails + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + VerifiedNameDetails.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.serial != null && message.hasOwnProperty("serial")) + if (!$util.isInteger(message.serial) && !(message.serial && $util.isInteger(message.serial.low) && $util.isInteger(message.serial.high))) + return "serial: integer|Long expected"; + if (message.issuer != null && message.hasOwnProperty("issuer")) + if (!$util.isString(message.issuer)) + return "issuer: string expected"; + if (message.verifiedName != null && message.hasOwnProperty("verifiedName")) + if (!$util.isString(message.verifiedName)) + return "verifiedName: string expected"; + if (message.localizedNames != null && message.hasOwnProperty("localizedNames")) { + if (!Array.isArray(message.localizedNames)) + return "localizedNames: array expected"; + for (var i = 0; i < message.localizedNames.length; ++i) { + var error = $root.proto.LocalizedName.verify(message.localizedNames[i]); + if (error) + return "localizedNames." + error; + } + } + if (message.issueTime != null && message.hasOwnProperty("issueTime")) + if (!$util.isInteger(message.issueTime) && !(message.issueTime && $util.isInteger(message.issueTime.low) && $util.isInteger(message.issueTime.high))) + return "issueTime: integer|Long expected"; + return null; + }; + + /** + * Creates a VerifiedNameDetails message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof proto.VerifiedNameDetails + * @static + * @param {Object.} object Plain object + * @returns {proto.VerifiedNameDetails} VerifiedNameDetails + */ + VerifiedNameDetails.fromObject = function fromObject(object) { + if (object instanceof $root.proto.VerifiedNameDetails) + return object; + var message = new $root.proto.VerifiedNameDetails(); + if (object.serial != null) + if ($util.Long) + (message.serial = $util.Long.fromValue(object.serial)).unsigned = true; + else if (typeof object.serial === "string") + message.serial = parseInt(object.serial, 10); + else if (typeof object.serial === "number") + message.serial = object.serial; + else if (typeof object.serial === "object") + message.serial = new $util.LongBits(object.serial.low >>> 0, object.serial.high >>> 0).toNumber(true); + if (object.issuer != null) + message.issuer = String(object.issuer); + if (object.verifiedName != null) + message.verifiedName = String(object.verifiedName); + if (object.localizedNames) { + if (!Array.isArray(object.localizedNames)) + throw TypeError(".proto.VerifiedNameDetails.localizedNames: array expected"); + message.localizedNames = []; + for (var i = 0; i < object.localizedNames.length; ++i) { + if (typeof object.localizedNames[i] !== "object") + throw TypeError(".proto.VerifiedNameDetails.localizedNames: object expected"); + message.localizedNames[i] = $root.proto.LocalizedName.fromObject(object.localizedNames[i]); + } + } + if (object.issueTime != null) + if ($util.Long) + (message.issueTime = $util.Long.fromValue(object.issueTime)).unsigned = true; + else if (typeof object.issueTime === "string") + message.issueTime = parseInt(object.issueTime, 10); + else if (typeof object.issueTime === "number") + message.issueTime = object.issueTime; + else if (typeof object.issueTime === "object") + message.issueTime = new $util.LongBits(object.issueTime.low >>> 0, object.issueTime.high >>> 0).toNumber(true); + return message; + }; + + /** + * Creates a plain object from a VerifiedNameDetails message. Also converts values to other types if specified. + * @function toObject + * @memberof proto.VerifiedNameDetails + * @static + * @param {proto.VerifiedNameDetails} message VerifiedNameDetails + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + VerifiedNameDetails.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.arrays || options.defaults) + object.localizedNames = []; + if (options.defaults) { + if ($util.Long) { + var long = new $util.Long(0, 0, true); + object.serial = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.serial = options.longs === String ? "0" : 0; + object.issuer = ""; + object.verifiedName = ""; + if ($util.Long) { + var long = new $util.Long(0, 0, true); + object.issueTime = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.issueTime = options.longs === String ? "0" : 0; + } + if (message.serial != null && message.hasOwnProperty("serial")) + if (typeof message.serial === "number") + object.serial = options.longs === String ? String(message.serial) : message.serial; + else + object.serial = options.longs === String ? $util.Long.prototype.toString.call(message.serial) : options.longs === Number ? new $util.LongBits(message.serial.low >>> 0, message.serial.high >>> 0).toNumber(true) : message.serial; + if (message.issuer != null && message.hasOwnProperty("issuer")) + object.issuer = message.issuer; + if (message.verifiedName != null && message.hasOwnProperty("verifiedName")) + object.verifiedName = message.verifiedName; + if (message.localizedNames && message.localizedNames.length) { + object.localizedNames = []; + for (var j = 0; j < message.localizedNames.length; ++j) + object.localizedNames[j] = $root.proto.LocalizedName.toObject(message.localizedNames[j], options); + } + if (message.issueTime != null && message.hasOwnProperty("issueTime")) + if (typeof message.issueTime === "number") + object.issueTime = options.longs === String ? String(message.issueTime) : message.issueTime; + else + object.issueTime = options.longs === String ? $util.Long.prototype.toString.call(message.issueTime) : options.longs === Number ? new $util.LongBits(message.issueTime.low >>> 0, message.issueTime.high >>> 0).toNumber(true) : message.issueTime; + return object; + }; + + /** + * Converts this VerifiedNameDetails to JSON. + * @function toJSON + * @memberof proto.VerifiedNameDetails + * @instance + * @returns {Object.} JSON object + */ + VerifiedNameDetails.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + return VerifiedNameDetails; + })(); + proto.VerifiedNameCertificate = (function() { /** @@ -21436,6 +21740,7 @@ $root.proto = (function() { * @property {string|null} [sourceType] ExternalAdReplyInfo sourceType * @property {string|null} [sourceId] ExternalAdReplyInfo sourceId * @property {string|null} [sourceUrl] ExternalAdReplyInfo sourceUrl + * @property {boolean|null} [containsAutoReply] ExternalAdReplyInfo containsAutoReply */ /** @@ -21525,6 +21830,14 @@ $root.proto = (function() { */ ExternalAdReplyInfo.prototype.sourceUrl = ""; + /** + * ExternalAdReplyInfo containsAutoReply. + * @member {boolean} containsAutoReply + * @memberof proto.ExternalAdReplyInfo + * @instance + */ + ExternalAdReplyInfo.prototype.containsAutoReply = false; + /** * Creates a new ExternalAdReplyInfo instance using the specified properties. * @function create @@ -21567,6 +21880,8 @@ $root.proto = (function() { writer.uint32(/* id 8, wireType 2 =*/66).string(message.sourceId); if (message.sourceUrl != null && Object.hasOwnProperty.call(message, "sourceUrl")) writer.uint32(/* id 9, wireType 2 =*/74).string(message.sourceUrl); + if (message.containsAutoReply != null && Object.hasOwnProperty.call(message, "containsAutoReply")) + writer.uint32(/* id 10, wireType 0 =*/80).bool(message.containsAutoReply); return writer; }; @@ -21628,6 +21943,9 @@ $root.proto = (function() { case 9: message.sourceUrl = reader.string(); break; + case 10: + message.containsAutoReply = reader.bool(); + break; default: reader.skipType(tag & 7); break; @@ -21696,6 +22014,9 @@ $root.proto = (function() { if (message.sourceUrl != null && message.hasOwnProperty("sourceUrl")) if (!$util.isString(message.sourceUrl)) return "sourceUrl: string expected"; + if (message.containsAutoReply != null && message.hasOwnProperty("containsAutoReply")) + if (typeof message.containsAutoReply !== "boolean") + return "containsAutoReply: boolean expected"; return null; }; @@ -21744,6 +22065,8 @@ $root.proto = (function() { message.sourceId = String(object.sourceId); if (object.sourceUrl != null) message.sourceUrl = String(object.sourceUrl); + if (object.containsAutoReply != null) + message.containsAutoReply = Boolean(object.containsAutoReply); return message; }; @@ -21776,6 +22099,7 @@ $root.proto = (function() { object.sourceType = ""; object.sourceId = ""; object.sourceUrl = ""; + object.containsAutoReply = false; } if (message.title != null && message.hasOwnProperty("title")) object.title = message.title; @@ -21795,6 +22119,8 @@ $root.proto = (function() { object.sourceId = message.sourceId; if (message.sourceUrl != null && message.hasOwnProperty("sourceUrl")) object.sourceUrl = message.sourceUrl; + if (message.containsAutoReply != null && message.hasOwnProperty("containsAutoReply")) + object.containsAutoReply = message.containsAutoReply; return object; }; @@ -46978,28 +47304,28 @@ $root.proto = (function() { return DisappearingMode; })(); - proto.MediaData = (function() { + proto.PBMediaData = (function() { /** - * Properties of a MediaData. + * Properties of a PBMediaData. * @memberof proto - * @interface IMediaData - * @property {Uint8Array|null} [mediaKey] MediaData mediaKey - * @property {number|Long|null} [mediaKeyTimestamp] MediaData mediaKeyTimestamp - * @property {Uint8Array|null} [fileSha256] MediaData fileSha256 - * @property {Uint8Array|null} [fileEncSha256] MediaData fileEncSha256 - * @property {string|null} [directPath] MediaData directPath + * @interface IPBMediaData + * @property {Uint8Array|null} [mediaKey] PBMediaData mediaKey + * @property {number|Long|null} [mediaKeyTimestamp] PBMediaData mediaKeyTimestamp + * @property {Uint8Array|null} [fileSha256] PBMediaData fileSha256 + * @property {Uint8Array|null} [fileEncSha256] PBMediaData fileEncSha256 + * @property {string|null} [directPath] PBMediaData directPath */ /** - * Constructs a new MediaData. + * Constructs a new PBMediaData. * @memberof proto - * @classdesc Represents a MediaData. - * @implements IMediaData + * @classdesc Represents a PBMediaData. + * @implements IPBMediaData * @constructor - * @param {proto.IMediaData=} [properties] Properties to set + * @param {proto.IPBMediaData=} [properties] Properties to set */ - function MediaData(properties) { + function PBMediaData(properties) { if (properties) for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) if (properties[keys[i]] != null) @@ -47007,67 +47333,67 @@ $root.proto = (function() { } /** - * MediaData mediaKey. + * PBMediaData mediaKey. * @member {Uint8Array} mediaKey - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @instance */ - MediaData.prototype.mediaKey = $util.newBuffer([]); + PBMediaData.prototype.mediaKey = $util.newBuffer([]); /** - * MediaData mediaKeyTimestamp. + * PBMediaData mediaKeyTimestamp. * @member {number|Long} mediaKeyTimestamp - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @instance */ - MediaData.prototype.mediaKeyTimestamp = $util.Long ? $util.Long.fromBits(0,0,false) : 0; + PBMediaData.prototype.mediaKeyTimestamp = $util.Long ? $util.Long.fromBits(0,0,false) : 0; /** - * MediaData fileSha256. + * PBMediaData fileSha256. * @member {Uint8Array} fileSha256 - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @instance */ - MediaData.prototype.fileSha256 = $util.newBuffer([]); + PBMediaData.prototype.fileSha256 = $util.newBuffer([]); /** - * MediaData fileEncSha256. + * PBMediaData fileEncSha256. * @member {Uint8Array} fileEncSha256 - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @instance */ - MediaData.prototype.fileEncSha256 = $util.newBuffer([]); + PBMediaData.prototype.fileEncSha256 = $util.newBuffer([]); /** - * MediaData directPath. + * PBMediaData directPath. * @member {string} directPath - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @instance */ - MediaData.prototype.directPath = ""; + PBMediaData.prototype.directPath = ""; /** - * Creates a new MediaData instance using the specified properties. + * Creates a new PBMediaData instance using the specified properties. * @function create - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @static - * @param {proto.IMediaData=} [properties] Properties to set - * @returns {proto.MediaData} MediaData instance + * @param {proto.IPBMediaData=} [properties] Properties to set + * @returns {proto.PBMediaData} PBMediaData instance */ - MediaData.create = function create(properties) { - return new MediaData(properties); + PBMediaData.create = function create(properties) { + return new PBMediaData(properties); }; /** - * Encodes the specified MediaData message. Does not implicitly {@link proto.MediaData.verify|verify} messages. + * Encodes the specified PBMediaData message. Does not implicitly {@link proto.PBMediaData.verify|verify} messages. * @function encode - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @static - * @param {proto.IMediaData} message MediaData message or plain object to encode + * @param {proto.IPBMediaData} message PBMediaData message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - MediaData.encode = function encode(message, writer) { + PBMediaData.encode = function encode(message, writer) { if (!writer) writer = $Writer.create(); if (message.mediaKey != null && Object.hasOwnProperty.call(message, "mediaKey")) @@ -47084,33 +47410,33 @@ $root.proto = (function() { }; /** - * Encodes the specified MediaData message, length delimited. Does not implicitly {@link proto.MediaData.verify|verify} messages. + * Encodes the specified PBMediaData message, length delimited. Does not implicitly {@link proto.PBMediaData.verify|verify} messages. * @function encodeDelimited - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @static - * @param {proto.IMediaData} message MediaData message or plain object to encode + * @param {proto.IPBMediaData} message PBMediaData message or plain object to encode * @param {$protobuf.Writer} [writer] Writer to encode to * @returns {$protobuf.Writer} Writer */ - MediaData.encodeDelimited = function encodeDelimited(message, writer) { + PBMediaData.encodeDelimited = function encodeDelimited(message, writer) { return this.encode(message, writer).ldelim(); }; /** - * Decodes a MediaData message from the specified reader or buffer. + * Decodes a PBMediaData message from the specified reader or buffer. * @function decode - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from * @param {number} [length] Message length if known beforehand - * @returns {proto.MediaData} MediaData + * @returns {proto.PBMediaData} PBMediaData * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - MediaData.decode = function decode(reader, length) { + PBMediaData.decode = function decode(reader, length) { if (!(reader instanceof $Reader)) reader = $Reader.create(reader); - var end = length === undefined ? reader.len : reader.pos + length, message = new $root.proto.MediaData(); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.proto.PBMediaData(); while (reader.pos < end) { var tag = reader.uint32(); switch (tag >>> 3) { @@ -47138,30 +47464,30 @@ $root.proto = (function() { }; /** - * Decodes a MediaData message from the specified reader or buffer, length delimited. + * Decodes a PBMediaData message from the specified reader or buffer, length delimited. * @function decodeDelimited - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @static * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from - * @returns {proto.MediaData} MediaData + * @returns {proto.PBMediaData} PBMediaData * @throws {Error} If the payload is not a reader or valid buffer * @throws {$protobuf.util.ProtocolError} If required fields are missing */ - MediaData.decodeDelimited = function decodeDelimited(reader) { + PBMediaData.decodeDelimited = function decodeDelimited(reader) { if (!(reader instanceof $Reader)) reader = new $Reader(reader); return this.decode(reader, reader.uint32()); }; /** - * Verifies a MediaData message. + * Verifies a PBMediaData message. * @function verify - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @static * @param {Object.} message Plain object to verify * @returns {string|null} `null` if valid, otherwise the reason why it is not */ - MediaData.verify = function verify(message) { + PBMediaData.verify = function verify(message) { if (typeof message !== "object" || message === null) return "object expected"; if (message.mediaKey != null && message.hasOwnProperty("mediaKey")) @@ -47183,17 +47509,17 @@ $root.proto = (function() { }; /** - * Creates a MediaData message from a plain object. Also converts values to their respective internal types. + * Creates a PBMediaData message from a plain object. Also converts values to their respective internal types. * @function fromObject - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @static * @param {Object.} object Plain object - * @returns {proto.MediaData} MediaData + * @returns {proto.PBMediaData} PBMediaData */ - MediaData.fromObject = function fromObject(object) { - if (object instanceof $root.proto.MediaData) + PBMediaData.fromObject = function fromObject(object) { + if (object instanceof $root.proto.PBMediaData) return object; - var message = new $root.proto.MediaData(); + var message = new $root.proto.PBMediaData(); if (object.mediaKey != null) if (typeof object.mediaKey === "string") $util.base64.decode(object.mediaKey, message.mediaKey = $util.newBuffer($util.base64.length(object.mediaKey)), 0); @@ -47224,15 +47550,15 @@ $root.proto = (function() { }; /** - * Creates a plain object from a MediaData message. Also converts values to other types if specified. + * Creates a plain object from a PBMediaData message. Also converts values to other types if specified. * @function toObject - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @static - * @param {proto.MediaData} message MediaData + * @param {proto.PBMediaData} message PBMediaData * @param {$protobuf.IConversionOptions} [options] Conversion options * @returns {Object.} Plain object */ - MediaData.toObject = function toObject(message, options) { + PBMediaData.toObject = function toObject(message, options) { if (!options) options = {}; var object = {}; @@ -47282,17 +47608,17 @@ $root.proto = (function() { }; /** - * Converts this MediaData to JSON. + * Converts this PBMediaData to JSON. * @function toJSON - * @memberof proto.MediaData + * @memberof proto.PBMediaData * @instance * @returns {Object.} JSON object */ - MediaData.prototype.toJSON = function toJSON() { + PBMediaData.prototype.toJSON = function toJSON() { return this.constructor.toObject(this, $protobuf.util.toJSONOptions); }; - return MediaData; + return PBMediaData; })(); proto.PaymentBackground = (function() { @@ -47309,7 +47635,7 @@ $root.proto = (function() { * @property {number|null} [placeholderArgb] PaymentBackground placeholderArgb * @property {number|null} [textArgb] PaymentBackground textArgb * @property {number|null} [subtextArgb] PaymentBackground subtextArgb - * @property {proto.IMediaData|null} [mediaData] PaymentBackground mediaData + * @property {proto.IPBMediaData|null} [mediaData] PaymentBackground mediaData * @property {proto.PaymentBackground.PaymentBackgroundType|null} [type] PaymentBackground type */ @@ -47394,7 +47720,7 @@ $root.proto = (function() { /** * PaymentBackground mediaData. - * @member {proto.IMediaData|null|undefined} mediaData + * @member {proto.IPBMediaData|null|undefined} mediaData * @memberof proto.PaymentBackground * @instance */ @@ -47449,7 +47775,7 @@ $root.proto = (function() { if (message.subtextArgb != null && Object.hasOwnProperty.call(message, "subtextArgb")) writer.uint32(/* id 8, wireType 5 =*/69).fixed32(message.subtextArgb); if (message.mediaData != null && Object.hasOwnProperty.call(message, "mediaData")) - $root.proto.MediaData.encode(message.mediaData, writer.uint32(/* id 9, wireType 2 =*/74).fork()).ldelim(); + $root.proto.PBMediaData.encode(message.mediaData, writer.uint32(/* id 9, wireType 2 =*/74).fork()).ldelim(); if (message.type != null && Object.hasOwnProperty.call(message, "type")) writer.uint32(/* id 10, wireType 0 =*/80).int32(message.type); return writer; @@ -47511,7 +47837,7 @@ $root.proto = (function() { message.subtextArgb = reader.fixed32(); break; case 9: - message.mediaData = $root.proto.MediaData.decode(reader, reader.uint32()); + message.mediaData = $root.proto.PBMediaData.decode(reader, reader.uint32()); break; case 10: message.type = reader.int32(); @@ -47576,7 +47902,7 @@ $root.proto = (function() { if (!$util.isInteger(message.subtextArgb)) return "subtextArgb: integer expected"; if (message.mediaData != null && message.hasOwnProperty("mediaData")) { - var error = $root.proto.MediaData.verify(message.mediaData); + var error = $root.proto.PBMediaData.verify(message.mediaData); if (error) return "mediaData." + error; } @@ -47629,7 +47955,7 @@ $root.proto = (function() { if (object.mediaData != null) { if (typeof object.mediaData !== "object") throw TypeError(".proto.PaymentBackground.mediaData: object expected"); - message.mediaData = $root.proto.MediaData.fromObject(object.mediaData); + message.mediaData = $root.proto.PBMediaData.fromObject(object.mediaData); } switch (object.type) { case "UNKNOWN": @@ -47693,7 +48019,7 @@ $root.proto = (function() { if (message.subtextArgb != null && message.hasOwnProperty("subtextArgb")) object.subtextArgb = message.subtextArgb; if (message.mediaData != null && message.hasOwnProperty("mediaData")) - object.mediaData = $root.proto.MediaData.toObject(message.mediaData, options); + object.mediaData = $root.proto.PBMediaData.toObject(message.mediaData, options); if (message.type != null && message.hasOwnProperty("type")) object.type = options.enums === String ? $root.proto.PaymentBackground.PaymentBackgroundType[message.type] : message.type; return object; @@ -52919,6 +53245,230 @@ $root.proto = (function() { return UserReceipt; })(); + proto.StatusPSA = (function() { + + /** + * Properties of a StatusPSA. + * @memberof proto + * @interface IStatusPSA + * @property {string} campaignId StatusPSA campaignId + * @property {number|Long|null} [campaignExpirationTimestamp] StatusPSA campaignExpirationTimestamp + */ + + /** + * Constructs a new StatusPSA. + * @memberof proto + * @classdesc Represents a StatusPSA. + * @implements IStatusPSA + * @constructor + * @param {proto.IStatusPSA=} [properties] Properties to set + */ + function StatusPSA(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * StatusPSA campaignId. + * @member {string} campaignId + * @memberof proto.StatusPSA + * @instance + */ + StatusPSA.prototype.campaignId = ""; + + /** + * StatusPSA campaignExpirationTimestamp. + * @member {number|Long} campaignExpirationTimestamp + * @memberof proto.StatusPSA + * @instance + */ + StatusPSA.prototype.campaignExpirationTimestamp = $util.Long ? $util.Long.fromBits(0,0,true) : 0; + + /** + * Creates a new StatusPSA instance using the specified properties. + * @function create + * @memberof proto.StatusPSA + * @static + * @param {proto.IStatusPSA=} [properties] Properties to set + * @returns {proto.StatusPSA} StatusPSA instance + */ + StatusPSA.create = function create(properties) { + return new StatusPSA(properties); + }; + + /** + * Encodes the specified StatusPSA message. Does not implicitly {@link proto.StatusPSA.verify|verify} messages. + * @function encode + * @memberof proto.StatusPSA + * @static + * @param {proto.IStatusPSA} message StatusPSA message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + StatusPSA.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + writer.uint32(/* id 44, wireType 2 =*/354).string(message.campaignId); + if (message.campaignExpirationTimestamp != null && Object.hasOwnProperty.call(message, "campaignExpirationTimestamp")) + writer.uint32(/* id 45, wireType 0 =*/360).uint64(message.campaignExpirationTimestamp); + return writer; + }; + + /** + * Encodes the specified StatusPSA message, length delimited. Does not implicitly {@link proto.StatusPSA.verify|verify} messages. + * @function encodeDelimited + * @memberof proto.StatusPSA + * @static + * @param {proto.IStatusPSA} message StatusPSA message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + StatusPSA.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a StatusPSA message from the specified reader or buffer. + * @function decode + * @memberof proto.StatusPSA + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {proto.StatusPSA} StatusPSA + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + StatusPSA.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.proto.StatusPSA(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 44: + message.campaignId = reader.string(); + break; + case 45: + message.campaignExpirationTimestamp = reader.uint64(); + break; + default: + reader.skipType(tag & 7); + break; + } + } + if (!message.hasOwnProperty("campaignId")) + throw $util.ProtocolError("missing required 'campaignId'", { instance: message }); + return message; + }; + + /** + * Decodes a StatusPSA message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof proto.StatusPSA + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {proto.StatusPSA} StatusPSA + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + StatusPSA.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a StatusPSA message. + * @function verify + * @memberof proto.StatusPSA + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + StatusPSA.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (!$util.isString(message.campaignId)) + return "campaignId: string expected"; + if (message.campaignExpirationTimestamp != null && message.hasOwnProperty("campaignExpirationTimestamp")) + if (!$util.isInteger(message.campaignExpirationTimestamp) && !(message.campaignExpirationTimestamp && $util.isInteger(message.campaignExpirationTimestamp.low) && $util.isInteger(message.campaignExpirationTimestamp.high))) + return "campaignExpirationTimestamp: integer|Long expected"; + return null; + }; + + /** + * Creates a StatusPSA message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof proto.StatusPSA + * @static + * @param {Object.} object Plain object + * @returns {proto.StatusPSA} StatusPSA + */ + StatusPSA.fromObject = function fromObject(object) { + if (object instanceof $root.proto.StatusPSA) + return object; + var message = new $root.proto.StatusPSA(); + if (object.campaignId != null) + message.campaignId = String(object.campaignId); + if (object.campaignExpirationTimestamp != null) + if ($util.Long) + (message.campaignExpirationTimestamp = $util.Long.fromValue(object.campaignExpirationTimestamp)).unsigned = true; + else if (typeof object.campaignExpirationTimestamp === "string") + message.campaignExpirationTimestamp = parseInt(object.campaignExpirationTimestamp, 10); + else if (typeof object.campaignExpirationTimestamp === "number") + message.campaignExpirationTimestamp = object.campaignExpirationTimestamp; + else if (typeof object.campaignExpirationTimestamp === "object") + message.campaignExpirationTimestamp = new $util.LongBits(object.campaignExpirationTimestamp.low >>> 0, object.campaignExpirationTimestamp.high >>> 0).toNumber(true); + return message; + }; + + /** + * Creates a plain object from a StatusPSA message. Also converts values to other types if specified. + * @function toObject + * @memberof proto.StatusPSA + * @static + * @param {proto.StatusPSA} message StatusPSA + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + StatusPSA.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) { + object.campaignId = ""; + if ($util.Long) { + var long = new $util.Long(0, 0, true); + object.campaignExpirationTimestamp = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; + } else + object.campaignExpirationTimestamp = options.longs === String ? "0" : 0; + } + if (message.campaignId != null && message.hasOwnProperty("campaignId")) + object.campaignId = message.campaignId; + if (message.campaignExpirationTimestamp != null && message.hasOwnProperty("campaignExpirationTimestamp")) + if (typeof message.campaignExpirationTimestamp === "number") + object.campaignExpirationTimestamp = options.longs === String ? String(message.campaignExpirationTimestamp) : message.campaignExpirationTimestamp; + else + object.campaignExpirationTimestamp = options.longs === String ? $util.Long.prototype.toString.call(message.campaignExpirationTimestamp) : options.longs === Number ? new $util.LongBits(message.campaignExpirationTimestamp.low >>> 0, message.campaignExpirationTimestamp.high >>> 0).toNumber(true) : message.campaignExpirationTimestamp; + return object; + }; + + /** + * Converts this StatusPSA to JSON. + * @function toJSON + * @memberof proto.StatusPSA + * @instance + * @returns {Object.} JSON object + */ + StatusPSA.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + return StatusPSA; + })(); + proto.PhotoChange = (function() { /** @@ -53169,6 +53719,193 @@ $root.proto = (function() { return PhotoChange; })(); + proto.MediaData = (function() { + + /** + * Properties of a MediaData. + * @memberof proto + * @interface IMediaData + * @property {string|null} [localPath] MediaData localPath + */ + + /** + * Constructs a new MediaData. + * @memberof proto + * @classdesc Represents a MediaData. + * @implements IMediaData + * @constructor + * @param {proto.IMediaData=} [properties] Properties to set + */ + function MediaData(properties) { + if (properties) + for (var keys = Object.keys(properties), i = 0; i < keys.length; ++i) + if (properties[keys[i]] != null) + this[keys[i]] = properties[keys[i]]; + } + + /** + * MediaData localPath. + * @member {string} localPath + * @memberof proto.MediaData + * @instance + */ + MediaData.prototype.localPath = ""; + + /** + * Creates a new MediaData instance using the specified properties. + * @function create + * @memberof proto.MediaData + * @static + * @param {proto.IMediaData=} [properties] Properties to set + * @returns {proto.MediaData} MediaData instance + */ + MediaData.create = function create(properties) { + return new MediaData(properties); + }; + + /** + * Encodes the specified MediaData message. Does not implicitly {@link proto.MediaData.verify|verify} messages. + * @function encode + * @memberof proto.MediaData + * @static + * @param {proto.IMediaData} message MediaData message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + MediaData.encode = function encode(message, writer) { + if (!writer) + writer = $Writer.create(); + if (message.localPath != null && Object.hasOwnProperty.call(message, "localPath")) + writer.uint32(/* id 1, wireType 2 =*/10).string(message.localPath); + return writer; + }; + + /** + * Encodes the specified MediaData message, length delimited. Does not implicitly {@link proto.MediaData.verify|verify} messages. + * @function encodeDelimited + * @memberof proto.MediaData + * @static + * @param {proto.IMediaData} message MediaData message or plain object to encode + * @param {$protobuf.Writer} [writer] Writer to encode to + * @returns {$protobuf.Writer} Writer + */ + MediaData.encodeDelimited = function encodeDelimited(message, writer) { + return this.encode(message, writer).ldelim(); + }; + + /** + * Decodes a MediaData message from the specified reader or buffer. + * @function decode + * @memberof proto.MediaData + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @param {number} [length] Message length if known beforehand + * @returns {proto.MediaData} MediaData + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + MediaData.decode = function decode(reader, length) { + if (!(reader instanceof $Reader)) + reader = $Reader.create(reader); + var end = length === undefined ? reader.len : reader.pos + length, message = new $root.proto.MediaData(); + while (reader.pos < end) { + var tag = reader.uint32(); + switch (tag >>> 3) { + case 1: + message.localPath = reader.string(); + break; + default: + reader.skipType(tag & 7); + break; + } + } + return message; + }; + + /** + * Decodes a MediaData message from the specified reader or buffer, length delimited. + * @function decodeDelimited + * @memberof proto.MediaData + * @static + * @param {$protobuf.Reader|Uint8Array} reader Reader or buffer to decode from + * @returns {proto.MediaData} MediaData + * @throws {Error} If the payload is not a reader or valid buffer + * @throws {$protobuf.util.ProtocolError} If required fields are missing + */ + MediaData.decodeDelimited = function decodeDelimited(reader) { + if (!(reader instanceof $Reader)) + reader = new $Reader(reader); + return this.decode(reader, reader.uint32()); + }; + + /** + * Verifies a MediaData message. + * @function verify + * @memberof proto.MediaData + * @static + * @param {Object.} message Plain object to verify + * @returns {string|null} `null` if valid, otherwise the reason why it is not + */ + MediaData.verify = function verify(message) { + if (typeof message !== "object" || message === null) + return "object expected"; + if (message.localPath != null && message.hasOwnProperty("localPath")) + if (!$util.isString(message.localPath)) + return "localPath: string expected"; + return null; + }; + + /** + * Creates a MediaData message from a plain object. Also converts values to their respective internal types. + * @function fromObject + * @memberof proto.MediaData + * @static + * @param {Object.} object Plain object + * @returns {proto.MediaData} MediaData + */ + MediaData.fromObject = function fromObject(object) { + if (object instanceof $root.proto.MediaData) + return object; + var message = new $root.proto.MediaData(); + if (object.localPath != null) + message.localPath = String(object.localPath); + return message; + }; + + /** + * Creates a plain object from a MediaData message. Also converts values to other types if specified. + * @function toObject + * @memberof proto.MediaData + * @static + * @param {proto.MediaData} message MediaData + * @param {$protobuf.IConversionOptions} [options] Conversion options + * @returns {Object.} Plain object + */ + MediaData.toObject = function toObject(message, options) { + if (!options) + options = {}; + var object = {}; + if (options.defaults) + object.localPath = ""; + if (message.localPath != null && message.hasOwnProperty("localPath")) + object.localPath = message.localPath; + return object; + }; + + /** + * Converts this MediaData to JSON. + * @function toJSON + * @memberof proto.MediaData + * @instance + * @returns {Object.} JSON object + */ + MediaData.prototype.toJSON = function toJSON() { + return this.constructor.toObject(this, $protobuf.util.toJSONOptions); + }; + + return MediaData; + })(); + proto.WebFeatures = (function() { /** @@ -56835,9 +57572,7 @@ $root.proto = (function() { * @property {Array.|null} [reactions] WebMessageInfo reactions * @property {proto.IMediaData|null} [quotedStickerData] WebMessageInfo quotedStickerData * @property {Uint8Array|null} [futureproofData] WebMessageInfo futureproofData - * @property {string|null} [statusPsaCampaignId] WebMessageInfo statusPsaCampaignId - * @property {number|null} [statusPsaCampaignDuration] WebMessageInfo statusPsaCampaignDuration - * @property {number|Long|null} [statusPsaCampaignReadTimestamp] WebMessageInfo statusPsaCampaignReadTimestamp + * @property {proto.IStatusPSA|null} [statusPsa] WebMessageInfo statusPsa */ /** @@ -57132,28 +57867,12 @@ $root.proto = (function() { WebMessageInfo.prototype.futureproofData = $util.newBuffer([]); /** - * WebMessageInfo statusPsaCampaignId. - * @member {string} statusPsaCampaignId + * WebMessageInfo statusPsa. + * @member {proto.IStatusPSA|null|undefined} statusPsa * @memberof proto.WebMessageInfo * @instance */ - WebMessageInfo.prototype.statusPsaCampaignId = ""; - - /** - * WebMessageInfo statusPsaCampaignDuration. - * @member {number} statusPsaCampaignDuration - * @memberof proto.WebMessageInfo - * @instance - */ - WebMessageInfo.prototype.statusPsaCampaignDuration = 0; - - /** - * WebMessageInfo statusPsaCampaignReadTimestamp. - * @member {number|Long} statusPsaCampaignReadTimestamp - * @memberof proto.WebMessageInfo - * @instance - */ - WebMessageInfo.prototype.statusPsaCampaignReadTimestamp = $util.Long ? $util.Long.fromBits(0,0,true) : 0; + WebMessageInfo.prototype.statusPsa = null; /** * Creates a new WebMessageInfo instance using the specified properties. @@ -57250,12 +57969,8 @@ $root.proto = (function() { $root.proto.MediaData.encode(message.quotedStickerData, writer.uint32(/* id 42, wireType 2 =*/338).fork()).ldelim(); if (message.futureproofData != null && Object.hasOwnProperty.call(message, "futureproofData")) writer.uint32(/* id 43, wireType 2 =*/346).bytes(message.futureproofData); - if (message.statusPsaCampaignId != null && Object.hasOwnProperty.call(message, "statusPsaCampaignId")) - writer.uint32(/* id 44, wireType 2 =*/354).string(message.statusPsaCampaignId); - if (message.statusPsaCampaignDuration != null && Object.hasOwnProperty.call(message, "statusPsaCampaignDuration")) - writer.uint32(/* id 45, wireType 0 =*/360).uint32(message.statusPsaCampaignDuration); - if (message.statusPsaCampaignReadTimestamp != null && Object.hasOwnProperty.call(message, "statusPsaCampaignReadTimestamp")) - writer.uint32(/* id 46, wireType 0 =*/368).uint64(message.statusPsaCampaignReadTimestamp); + if (message.statusPsa != null && Object.hasOwnProperty.call(message, "statusPsa")) + $root.proto.StatusPSA.encode(message.statusPsa, writer.uint32(/* id 44, wireType 2 =*/354).fork()).ldelim(); return writer; }; @@ -57401,13 +58116,7 @@ $root.proto = (function() { message.futureproofData = reader.bytes(); break; case 44: - message.statusPsaCampaignId = reader.string(); - break; - case 45: - message.statusPsaCampaignDuration = reader.uint32(); - break; - case 46: - message.statusPsaCampaignReadTimestamp = reader.uint64(); + message.statusPsa = $root.proto.StatusPSA.decode(reader, reader.uint32()); break; default: reader.skipType(tag & 7); @@ -57637,6 +58346,8 @@ $root.proto = (function() { case 129: case 130: case 131: + case 132: + case 133: break; } if (message.clearMedia != null && message.hasOwnProperty("clearMedia")) @@ -57735,15 +58446,11 @@ $root.proto = (function() { if (message.futureproofData != null && message.hasOwnProperty("futureproofData")) if (!(message.futureproofData && typeof message.futureproofData.length === "number" || $util.isString(message.futureproofData))) return "futureproofData: buffer expected"; - if (message.statusPsaCampaignId != null && message.hasOwnProperty("statusPsaCampaignId")) - if (!$util.isString(message.statusPsaCampaignId)) - return "statusPsaCampaignId: string expected"; - if (message.statusPsaCampaignDuration != null && message.hasOwnProperty("statusPsaCampaignDuration")) - if (!$util.isInteger(message.statusPsaCampaignDuration)) - return "statusPsaCampaignDuration: integer expected"; - if (message.statusPsaCampaignReadTimestamp != null && message.hasOwnProperty("statusPsaCampaignReadTimestamp")) - if (!$util.isInteger(message.statusPsaCampaignReadTimestamp) && !(message.statusPsaCampaignReadTimestamp && $util.isInteger(message.statusPsaCampaignReadTimestamp.low) && $util.isInteger(message.statusPsaCampaignReadTimestamp.high))) - return "statusPsaCampaignReadTimestamp: integer|Long expected"; + if (message.statusPsa != null && message.hasOwnProperty("statusPsa")) { + var error = $root.proto.StatusPSA.verify(message.statusPsa); + if (error) + return "statusPsa." + error; + } return null; }; @@ -58363,6 +59070,14 @@ $root.proto = (function() { case 131: message.messageStubType = 131; break; + case "ADMIN_REVOKE": + case 132: + message.messageStubType = 132; + break; + case "GROUP_INVITE_LINK_GROWTH_LOCKED": + case 133: + message.messageStubType = 133; + break; } if (object.clearMedia != null) message.clearMedia = Boolean(object.clearMedia); @@ -58472,19 +59187,11 @@ $root.proto = (function() { $util.base64.decode(object.futureproofData, message.futureproofData = $util.newBuffer($util.base64.length(object.futureproofData)), 0); else if (object.futureproofData.length) message.futureproofData = object.futureproofData; - if (object.statusPsaCampaignId != null) - message.statusPsaCampaignId = String(object.statusPsaCampaignId); - if (object.statusPsaCampaignDuration != null) - message.statusPsaCampaignDuration = object.statusPsaCampaignDuration >>> 0; - if (object.statusPsaCampaignReadTimestamp != null) - if ($util.Long) - (message.statusPsaCampaignReadTimestamp = $util.Long.fromValue(object.statusPsaCampaignReadTimestamp)).unsigned = true; - else if (typeof object.statusPsaCampaignReadTimestamp === "string") - message.statusPsaCampaignReadTimestamp = parseInt(object.statusPsaCampaignReadTimestamp, 10); - else if (typeof object.statusPsaCampaignReadTimestamp === "number") - message.statusPsaCampaignReadTimestamp = object.statusPsaCampaignReadTimestamp; - else if (typeof object.statusPsaCampaignReadTimestamp === "object") - message.statusPsaCampaignReadTimestamp = new $util.LongBits(object.statusPsaCampaignReadTimestamp.low >>> 0, object.statusPsaCampaignReadTimestamp.high >>> 0).toNumber(true); + if (object.statusPsa != null) { + if (typeof object.statusPsa !== "object") + throw TypeError(".proto.WebMessageInfo.statusPsa: object expected"); + message.statusPsa = $root.proto.StatusPSA.fromObject(object.statusPsa); + } return message; }; @@ -58562,13 +59269,7 @@ $root.proto = (function() { if (options.bytes !== Array) object.futureproofData = $util.newBuffer(object.futureproofData); } - object.statusPsaCampaignId = ""; - object.statusPsaCampaignDuration = 0; - if ($util.Long) { - var long = new $util.Long(0, 0, true); - object.statusPsaCampaignReadTimestamp = options.longs === String ? long.toString() : options.longs === Number ? long.toNumber() : long; - } else - object.statusPsaCampaignReadTimestamp = options.longs === String ? "0" : 0; + object.statusPsa = null; } if (message.key != null && message.hasOwnProperty("key")) object.key = $root.proto.MessageKey.toObject(message.key, options); @@ -58659,15 +59360,8 @@ $root.proto = (function() { object.quotedStickerData = $root.proto.MediaData.toObject(message.quotedStickerData, options); if (message.futureproofData != null && message.hasOwnProperty("futureproofData")) object.futureproofData = options.bytes === String ? $util.base64.encode(message.futureproofData, 0, message.futureproofData.length) : options.bytes === Array ? Array.prototype.slice.call(message.futureproofData) : message.futureproofData; - if (message.statusPsaCampaignId != null && message.hasOwnProperty("statusPsaCampaignId")) - object.statusPsaCampaignId = message.statusPsaCampaignId; - if (message.statusPsaCampaignDuration != null && message.hasOwnProperty("statusPsaCampaignDuration")) - object.statusPsaCampaignDuration = message.statusPsaCampaignDuration; - if (message.statusPsaCampaignReadTimestamp != null && message.hasOwnProperty("statusPsaCampaignReadTimestamp")) - if (typeof message.statusPsaCampaignReadTimestamp === "number") - object.statusPsaCampaignReadTimestamp = options.longs === String ? String(message.statusPsaCampaignReadTimestamp) : message.statusPsaCampaignReadTimestamp; - else - object.statusPsaCampaignReadTimestamp = options.longs === String ? $util.Long.prototype.toString.call(message.statusPsaCampaignReadTimestamp) : options.longs === Number ? new $util.LongBits(message.statusPsaCampaignReadTimestamp.low >>> 0, message.statusPsaCampaignReadTimestamp.high >>> 0).toNumber(true) : message.statusPsaCampaignReadTimestamp; + if (message.statusPsa != null && message.hasOwnProperty("statusPsa")) + object.statusPsa = $root.proto.StatusPSA.toObject(message.statusPsa, options); return object; }; @@ -58840,6 +59534,8 @@ $root.proto = (function() { * @property {number} BIZ_PRIVACY_MODE_TO_BSP=129 BIZ_PRIVACY_MODE_TO_BSP value * @property {number} DISAPPEARING_MODE=130 DISAPPEARING_MODE value * @property {number} E2E_DEVICE_FETCH_FAILED=131 E2E_DEVICE_FETCH_FAILED value + * @property {number} ADMIN_REVOKE=132 ADMIN_REVOKE value + * @property {number} GROUP_INVITE_LINK_GROWTH_LOCKED=133 GROUP_INVITE_LINK_GROWTH_LOCKED value */ WebMessageInfo.WebMessageInfoStubType = (function() { var valuesById = {}, values = Object.create(valuesById); @@ -58975,6 +59671,8 @@ $root.proto = (function() { values[valuesById[129] = "BIZ_PRIVACY_MODE_TO_BSP"] = 129; values[valuesById[130] = "DISAPPEARING_MODE"] = 130; values[valuesById[131] = "E2E_DEVICE_FETCH_FAILED"] = 131; + values[valuesById[132] = "ADMIN_REVOKE"] = 132; + values[valuesById[133] = "GROUP_INVITE_LINK_GROWTH_LOCKED"] = 133; return values; })(); diff --git a/package.json b/package.json index 6c39b15..353acf9 100644 --- a/package.json +++ b/package.json @@ -24,7 +24,7 @@ "build:tsc": "tsc", "example": "node --inspect -r ts-node/register Example/example.ts", "example:legacy": "node --inspect -r ts-node/register Example/example-legacy.ts", - "gen-protobuf": "bash src/BinaryNode/GenerateStatics.sh", + "gen-protobuf": "sh WAProto/GenerateStatics.sh", "browser-decode": "yarn ts-node src/BrowserMessageDecoding.ts", "lint": "eslint ./src --ext .js,.ts,.jsx,.tsx", "lint:fix": "eslint ./src --fix --ext .js,.ts,.jsx,.tsx" diff --git a/src/Utils/noise-handler.ts b/src/Utils/noise-handler.ts index def4be1..9df96ce 100644 --- a/src/Utils/noise-handler.ts +++ b/src/Utils/noise-handler.ts @@ -116,7 +116,7 @@ export const makeNoiseHandler = ({ public: publicKey, private: privateKey }: Key const certDecoded = decrypt(serverHello!.payload!) const { details: certDetails, signature: certSignature } = proto.NoiseCertificate.decode(certDecoded) - const { issuer: certIssuer, key: certKey } = proto.Details.decode(certDetails) + const { key: certKey } = proto.NoiseCertificateDetails.decode(certDetails) if(Buffer.compare(decStaticContent, certKey) !== 0) { throw new Boom('certification match failed', { statusCode: 400 })