Skip to content

Deleted message#

This section describes messageData object incoming webhook format for incoming deleted message. For a description of the general format of incoming webhooks, refer to Incoming messages section.

To get incoming webhooks of this type, three conditions must be true:

typeWebhook = incomingMessageReceived

deletedMessageWebhook = Yes

messageData.typeMessage = deletedMessage

Configuring an instance

To receive incoming notifications about extended text messages, you need to enable the settings using one of the following options:

  1. Through console enable the setting Get notifications about incoming messages and files and deletedMessageWebhook.

  2. Through the SetSettings method enable the setting incomingWebhook and deletedMessageWebhook.

Webhook#

Webhook parameters#

messageData object parameters

Parameter Type Description
typeMessage string Received message type. For messages of this type, the parameter takes on the value deletedMessage
deletedMessageData object Deleted message data object

deletedMessageData object parameters

Parameter Type Description
stanzaId string Deleted message id

The rest of the fields are filled depending on the type of the quoted message and are identical to the fields of incoming messages described in Incoming messages section

Webhook body example#

{
  "typeWebhook": "incomingMessageReceived",
  "instanceData": {
    "idInstance": 1101000001,
    "wid": "71231234567@c.us",
    "typeInstance": "whatsapp"
  },
  "timestamp": 1733146115,
  "idMessage": "10ECA1E0D26FAB972C24C56C8285ACAB",
  "senderData": {
    "chatId": "71234567890@c.us",
    "chatName": "Ivan",
    "sender": "71234567890@c.us",
    "senderName": "Ivan",
    "senderContactName": "Ivan Vasilivich"
  },
  "messageData": {
    "typeMessage": "deletedMessage",
    "deletedMessageData": {
      "stanzaId": "84514217EF972039FC3F68A53C196306" // id deleted message
    }
  }
}