Class: Message
Defined in: WAProto/index.d.ts:17012
Represents a Message.
Implements
Constructors
new Message()
new Message(
properties
?):Message
Defined in: WAProto/index.d.ts:17018
Constructs a new Message.
Parameters
properties?
Properties to set
Returns
Properties
albumMessage?
optional
albumMessage:null
|IAlbumMessage
Defined in: WAProto/index.d.ts:17225
Message albumMessage.
Implementation of
associatedChildMessage?
optional
associatedChildMessage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17243
Message associatedChildMessage.
Implementation of
IMessage
.associatedChildMessage
audioMessage?
optional
audioMessage:null
|IAudioMessage
Defined in: WAProto/index.d.ts:17042
Message audioMessage.
Implementation of
bcallMessage?
optional
bcallMessage:null
|IBCallMessage
Defined in: WAProto/index.d.ts:17201
Message bcallMessage.
Implementation of
botInvokeMessage?
optional
botInvokeMessage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17189
Message botInvokeMessage.
Implementation of
buttonsMessage?
optional
buttonsMessage:null
|IButtonsMessage
Defined in: WAProto/index.d.ts:17120
Message buttonsMessage.
Implementation of
buttonsResponseMessage?
optional
buttonsResponseMessage:null
|IButtonsResponseMessage
Defined in: WAProto/index.d.ts:17123
Message buttonsResponseMessage.
Implementation of
IMessage
.buttonsResponseMessage
call?
optional
call:null
|ICall
Defined in: WAProto/index.d.ts:17048
Message call.
Implementation of
callLogMesssage?
optional
callLogMesssage:null
|ICallLogMessage
Defined in: WAProto/index.d.ts:17192
Message callLogMesssage.
Implementation of
cancelPaymentRequestMessage?
optional
cancelPaymentRequestMessage:null
|ICancelPaymentRequestMessage
Defined in: WAProto/index.d.ts:17078
Message cancelPaymentRequestMessage.
Implementation of
IMessage
.cancelPaymentRequestMessage
chat?
optional
chat:null
|IChat
Defined in: WAProto/index.d.ts:17051
Message chat.
Implementation of
commentMessage?
optional
commentMessage:null
|ICommentMessage
Defined in: WAProto/index.d.ts:17213
Message commentMessage.
Implementation of
contactMessage?
optional
contactMessage:null
|IContactMessage
Defined in: WAProto/index.d.ts:17030
Message contactMessage.
Implementation of
contactsArrayMessage?
optional
contactsArrayMessage:null
|IContactsArrayMessage
Defined in: WAProto/index.d.ts:17057
Message contactsArrayMessage.
Implementation of
conversation?
optional
conversation:null
|string
Defined in: WAProto/index.d.ts:17021
Message conversation.
Implementation of
declinePaymentRequestMessage?
optional
declinePaymentRequestMessage:null
|IDeclinePaymentRequestMessage
Defined in: WAProto/index.d.ts:17075
Message declinePaymentRequestMessage.
Implementation of
IMessage
.declinePaymentRequestMessage
deviceSentMessage?
optional
deviceSentMessage:null
|IDeviceSentMessage
Defined in: WAProto/index.d.ts:17096
Message deviceSentMessage.
Implementation of
documentMessage?
optional
documentMessage:null
|IDocumentMessage
Defined in: WAProto/index.d.ts:17039
Message documentMessage.
Implementation of
documentWithCaptionMessage?
optional
documentWithCaptionMessage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17150
Message documentWithCaptionMessage.
Implementation of
IMessage
.documentWithCaptionMessage
editedMessage?
optional
editedMessage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17162
Message editedMessage.
Implementation of
encCommentMessage?
optional
encCommentMessage:null
|IEncCommentMessage
Defined in: WAProto/index.d.ts:17198
Message encCommentMessage.
Implementation of
encEventResponseMessage?
optional
encEventResponseMessage:null
|IEncEventResponseMessage
Defined in: WAProto/index.d.ts:17210
Message encEventResponseMessage.
Implementation of
IMessage
.encEventResponseMessage
encReactionMessage?
optional
encReactionMessage:null
|IEncReactionMessage
Defined in: WAProto/index.d.ts:17159
Message encReactionMessage.
Implementation of
ephemeralMessage?
optional
ephemeralMessage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17114
Message ephemeralMessage.
Implementation of
eventCoverImage?
optional
eventCoverImage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17228
Message eventCoverImage.
Implementation of
eventMessage?
optional
eventMessage:null
|IEventMessage
Defined in: WAProto/index.d.ts:17207
Message eventMessage.
Implementation of
extendedTextMessage?
optional
extendedTextMessage:null
|IExtendedTextMessage
Defined in: WAProto/index.d.ts:17036
Message extendedTextMessage.
Implementation of
fastRatchetKeySenderKeyDistributionMessage?
optional
fastRatchetKeySenderKeyDistributionMessage:null
|ISenderKeyDistributionMessage
Defined in: WAProto/index.d.ts:17063
Message fastRatchetKeySenderKeyDistributionMessage.
Implementation of
IMessage
.fastRatchetKeySenderKeyDistributionMessage
groupInviteMessage?
optional
groupInviteMessage:null
|IGroupInviteMessage
Defined in: WAProto/index.d.ts:17087
Message groupInviteMessage.
Implementation of
groupMentionedMessage?
optional
groupMentionedMessage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17174
Message groupMentionedMessage.
Implementation of
IMessage
.groupMentionedMessage
groupStatusMentionMessage?
optional
groupStatusMentionMessage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17246
Message groupStatusMentionMessage.
Implementation of
IMessage
.groupStatusMentionMessage
groupStatusMessage?
optional
groupStatusMessage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17258
Message groupStatusMessage.
Implementation of
highlyStructuredMessage?
optional
highlyStructuredMessage:null
|IHighlyStructuredMessage
Defined in: WAProto/index.d.ts:17060
Message highlyStructuredMessage.
Implementation of
IMessage
.highlyStructuredMessage
imageMessage?
optional
imageMessage:null
|IImageMessage
Defined in: WAProto/index.d.ts:17027
Message imageMessage.
Implementation of
interactiveMessage?
optional
interactiveMessage:null
|IInteractiveMessage
Defined in: WAProto/index.d.ts:17129
Message interactiveMessage.
Implementation of
interactiveResponseMessage?
optional
interactiveResponseMessage:null
|IInteractiveResponseMessage
Defined in: WAProto/index.d.ts:17138
Message interactiveResponseMessage.
Implementation of
IMessage
.interactiveResponseMessage
invoiceMessage?
optional
invoiceMessage:null
|IInvoiceMessage
Defined in: WAProto/index.d.ts:17117
Message invoiceMessage.
Implementation of
keepInChatMessage?
optional
keepInChatMessage:null
|IKeepInChatMessage
Defined in: WAProto/index.d.ts:17147
Message keepInChatMessage.
Implementation of
listMessage?
optional
listMessage:null
|IListMessage
Defined in: WAProto/index.d.ts:17102
Message listMessage.
Implementation of
listResponseMessage?
optional
listResponseMessage:null
|IListResponseMessage
Defined in: WAProto/index.d.ts:17111
Message listResponseMessage.
Implementation of
liveLocationMessage?
optional
liveLocationMessage:null
|ILiveLocationMessage
Defined in: WAProto/index.d.ts:17069
Message liveLocationMessage.
Implementation of
locationMessage?
optional
locationMessage:null
|ILocationMessage
Defined in: WAProto/index.d.ts:17033
Message locationMessage.
Implementation of
lottieStickerMessage?
optional
lottieStickerMessage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17204
Message lottieStickerMessage.
Implementation of
messageContextInfo?
optional
messageContextInfo:null
|IMessageContextInfo
Defined in: WAProto/index.d.ts:17099
Message messageContextInfo.
Implementation of
messageHistoryBundle?
optional
messageHistoryBundle:null
|IMessageHistoryBundle
Defined in: WAProto/index.d.ts:17195
Message messageHistoryBundle.
Implementation of
newsletterAdminInviteMessage?
optional
newsletterAdminInviteMessage:null
|INewsletterAdminInviteMessage
Defined in: WAProto/index.d.ts:17216
Message newsletterAdminInviteMessage.
Implementation of
IMessage
.newsletterAdminInviteMessage
orderMessage?
optional
orderMessage:null
|IOrderMessage
Defined in: WAProto/index.d.ts:17108
Message orderMessage.
Implementation of
paymentInviteMessage?
optional
paymentInviteMessage:null
|IPaymentInviteMessage
Defined in: WAProto/index.d.ts:17126
Message paymentInviteMessage.
Implementation of
pinInChatMessage?
optional
pinInChatMessage:null
|IPinInChatMessage
Defined in: WAProto/index.d.ts:17177
Message pinInChatMessage.
Implementation of
placeholderMessage?
optional
placeholderMessage:null
|IPlaceholderMessage
Defined in: WAProto/index.d.ts:17219
Message placeholderMessage.
Implementation of
pollCreationMessage?
optional
pollCreationMessage:null
|IPollCreationMessage
Defined in: WAProto/index.d.ts:17141
Message pollCreationMessage.
Implementation of
pollCreationMessageV2?
optional
pollCreationMessageV2:null
|IPollCreationMessage
Defined in: WAProto/index.d.ts:17168
Message pollCreationMessageV2.
Implementation of
IMessage
.pollCreationMessageV2
pollCreationMessageV3?
optional
pollCreationMessageV3:null
|IPollCreationMessage
Defined in: WAProto/index.d.ts:17180
Message pollCreationMessageV3.
Implementation of
IMessage
.pollCreationMessageV3
pollCreationMessageV4?
optional
pollCreationMessageV4:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17249
Message pollCreationMessageV4.
Implementation of
IMessage
.pollCreationMessageV4
pollCreationMessageV5?
optional
pollCreationMessageV5:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17252
Message pollCreationMessageV5.
Implementation of
IMessage
.pollCreationMessageV5
pollCreationOptionImageMessage?
optional
pollCreationOptionImageMessage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17240
Message pollCreationOptionImageMessage.
Implementation of
IMessage
.pollCreationOptionImageMessage
pollResultSnapshotMessage?
optional
pollResultSnapshotMessage:null
|IPollResultSnapshotMessage
Defined in: WAProto/index.d.ts:17237
Message pollResultSnapshotMessage.
Implementation of
IMessage
.pollResultSnapshotMessage
pollUpdateMessage?
optional
pollUpdateMessage:null
|IPollUpdateMessage
Defined in: WAProto/index.d.ts:17144
Message pollUpdateMessage.
Implementation of
productMessage?
optional
productMessage:null
|IProductMessage
Defined in: WAProto/index.d.ts:17093
Message productMessage.
Implementation of
protocolMessage?
optional
protocolMessage:null
|IProtocolMessage
Defined in: WAProto/index.d.ts:17054
Message protocolMessage.
Implementation of
ptvMessage?
optional
ptvMessage:null
|IVideoMessage
Defined in: WAProto/index.d.ts:17186
Message ptvMessage.
Implementation of
reactionMessage?
optional
reactionMessage:null
|IReactionMessage
Defined in: WAProto/index.d.ts:17132
Message reactionMessage.
Implementation of
requestPaymentMessage?
optional
requestPaymentMessage:null
|IRequestPaymentMessage
Defined in: WAProto/index.d.ts:17072
Message requestPaymentMessage.
Implementation of
IMessage
.requestPaymentMessage
requestPhoneNumberMessage?
optional
requestPhoneNumberMessage:null
|IRequestPhoneNumberMessage
Defined in: WAProto/index.d.ts:17153
Message requestPhoneNumberMessage.
Implementation of
IMessage
.requestPhoneNumberMessage
richResponseMessage?
optional
richResponseMessage:null
|IAIRichResponseMessage
Defined in: WAProto/index.d.ts:17261
Message richResponseMessage.
Implementation of
scheduledCallCreationMessage?
optional
scheduledCallCreationMessage:null
|IScheduledCallCreationMessage
Defined in: WAProto/index.d.ts:17171
Message scheduledCallCreationMessage.
Implementation of
IMessage
.scheduledCallCreationMessage
scheduledCallEditMessage?
optional
scheduledCallEditMessage:null
|IScheduledCallEditMessage
Defined in: WAProto/index.d.ts:17183
Message scheduledCallEditMessage.
Implementation of
IMessage
.scheduledCallEditMessage
secretEncryptedMessage?
optional
secretEncryptedMessage:null
|ISecretEncryptedMessage
Defined in: WAProto/index.d.ts:17222
Message secretEncryptedMessage.
Implementation of
IMessage
.secretEncryptedMessage
senderKeyDistributionMessage?
optional
senderKeyDistributionMessage:null
|ISenderKeyDistributionMessage
Defined in: WAProto/index.d.ts:17024
Message senderKeyDistributionMessage.
Implementation of
IMessage
.senderKeyDistributionMessage
sendPaymentMessage?
optional
sendPaymentMessage:null
|ISendPaymentMessage
Defined in: WAProto/index.d.ts:17066
Message sendPaymentMessage.
Implementation of
statusAddYours?
optional
statusAddYours:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17255
Message statusAddYours.
Implementation of
statusMentionMessage?
optional
statusMentionMessage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17234
Message statusMentionMessage.
Implementation of
statusNotificationMessage?
optional
statusNotificationMessage:null
|IStatusNotificationMessage
Defined in: WAProto/index.d.ts:17264
Message statusNotificationMessage.
Implementation of
IMessage
.statusNotificationMessage
stickerMessage?
optional
stickerMessage:null
|IStickerMessage
Defined in: WAProto/index.d.ts:17084
Message stickerMessage.
Implementation of
stickerPackMessage?
optional
stickerPackMessage:null
|IStickerPackMessage
Defined in: WAProto/index.d.ts:17231
Message stickerPackMessage.
Implementation of
stickerSyncRmrMessage?
optional
stickerSyncRmrMessage:null
|IStickerSyncRMRMessage
Defined in: WAProto/index.d.ts:17135
Message stickerSyncRmrMessage.
Implementation of
IMessage
.stickerSyncRmrMessage
templateButtonReplyMessage?
optional
templateButtonReplyMessage:null
|ITemplateButtonReplyMessage
Defined in: WAProto/index.d.ts:17090
Message templateButtonReplyMessage.
Implementation of
IMessage
.templateButtonReplyMessage
templateMessage?
optional
templateMessage:null
|ITemplateMessage
Defined in: WAProto/index.d.ts:17081
Message templateMessage.
Implementation of
videoMessage?
optional
videoMessage:null
|IVideoMessage
Defined in: WAProto/index.d.ts:17045
Message videoMessage.
Implementation of
viewOnceMessage?
optional
viewOnceMessage:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17105
Message viewOnceMessage.
Implementation of
viewOnceMessageV2?
optional
viewOnceMessageV2:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17156
Message viewOnceMessageV2.
Implementation of
viewOnceMessageV2Extension?
optional
viewOnceMessageV2Extension:null
|IFutureProofMessage
Defined in: WAProto/index.d.ts:17165
Message viewOnceMessageV2Extension.
Implementation of
IMessage
.viewOnceMessageV2Extension
Methods
toJSON()
toJSON():
object
Defined in: WAProto/index.d.ts:17334
Converts this Message to JSON.
Returns
object
JSON object
create()
static
create(properties
?):Message
Defined in: WAProto/index.d.ts:17271
Creates a new Message instance using the specified properties.
Parameters
properties?
Properties to set
Returns
Message instance
decode()
static
decode(reader
,length
?):Message
Defined in: WAProto/index.d.ts:17297
Decodes a Message message from the specified reader or buffer.
Parameters
reader
Reader or buffer to decode from
Uint8Array
<ArrayBufferLike
> | Reader
length?
number
Message length if known beforehand
Returns
Message
Throws
If the payload is not a reader or valid buffer
Throws
If required fields are missing
decodeDelimited()
static
decodeDelimited(reader
):Message
Defined in: WAProto/index.d.ts:17306
Decodes a Message message from the specified reader or buffer, length delimited.
Parameters
reader
Reader or buffer to decode from
Uint8Array
<ArrayBufferLike
> | Reader
Returns
Message
Throws
If the payload is not a reader or valid buffer
Throws
If required fields are missing
encode()
static
encode(message
,writer
?):Writer
Defined in: WAProto/index.d.ts:17279
Encodes the specified Message message. Does not implicitly verify messages.
Parameters
message
Message message or plain object to encode
writer?
Writer
Writer to encode to
Returns
Writer
Writer
encodeDelimited()
static
encodeDelimited(message
,writer
?):Writer
Defined in: WAProto/index.d.ts:17287
Encodes the specified Message message, length delimited. Does not implicitly verify messages.
Parameters
message
Message message or plain object to encode
writer?
Writer
Writer to encode to
Returns
Writer
Writer
fromObject()
static
fromObject(object
):Message
Defined in: WAProto/index.d.ts:17320
Creates a Message message from a plain object. Also converts values to their respective internal types.
Parameters
object
Plain object
Returns
Message
getTypeUrl()
static
getTypeUrl(typeUrlPrefix
?):string
Defined in: WAProto/index.d.ts:17341
Gets the default type url for Message
Parameters
typeUrlPrefix?
string
your custom typeUrlPrefix(default "type.googleapis.com")
Returns
string
The default type url
toObject()
static
toObject(message
,options
?):object
Defined in: WAProto/index.d.ts:17328
Creates a plain object from a Message message. Also converts values to other types if specified.
Parameters
message
Message
options?
IConversionOptions
Conversion options
Returns
object
Plain object
verify()
static
verify(message
):null
|string
Defined in: WAProto/index.d.ts:17313
Verifies a Message message.
Parameters
message
Plain object to verify
Returns
null
| string
null
if valid, otherwise the reason why it is not