(deprecated) Contact Avatar#
Notification is temporarily not working
Incoming notifications of this type contain information about the contact's avatar based on the requested phone number.
Webhook#
Webhook parameters#
Parameter | Type | Description |
---|---|---|
typeWebhook | string | Incoming webhook type. For webhooks of this type the parameter takes on the value deviceInfo |
instanceData | object | Instance data |
timestamp | integer | Event timestamp in UNIX format |
deviceData | object | Device data |
instanceData
object parameters
Parameter | Type | Description |
---|---|---|
idInstance | integer | Instance Id. The size of the integer is int64. Values range include from 1 to 10 digits |
wid | string | Account Id in WhatsApp format |
typeInstance | string | Instance messenger type |
avatarInfo
object parameters
Parameter | Type | Description |
---|---|---|
chatId | string | Identifier of the chat for which the contact's avatar was received. |
urlAvatar | string | Link to the correspondent's or group chat's avatar. This parameter is empty if no avatar is set |
reason | string | The reason why the avatar was not checked. It is present when the check fails, with possible values: |
bad request data - Incorrect phone number format. The phone number should contain 11 or 12 digits. Or chat identifier. | ||
get avatar timeout limit exceeded - Exceeded the avatar retrieval timeout limit. |
Webhook-example-body#
{
"typeWebhook": "deviceInfo",
"instanceData": {
"idInstance": 1234,
"wid": "11001234567@c.us",
"typeInstance": "whatsapp"
},
"timestamp": 1586700802,
"avatarInfo": {
"chatId": "79001234560@c.us",
"urlAvatar": "https://pps.whatsapp.net/v/t61.24694-24/180589560_n.jpg?ccb=11-4&oh=f3fb1&oe=615A60EB"
}
}