Retrieve the profile picture URL for a WhatsApp user or group.Authentication
Basic authentication credentials (username:password in base64)
Device identifier for multi-device support. Required when multiple devices are registered. If only one device is registered, it will be used as the default.
Query Parameters
Whether to fetch a preview (lower resolution) of the avatarExample: true
Whether to fetch a community avatarExample: false
Response
Response code indicating success or failureExample: SUCCESS
Human-readable response messageExample: Success
Avatar informationDirect URL to the profile pictureExample: https://pps.whatsapp.net/v/t61.24694-24/181358562_385581386633509_6230178822944778044_n.jpg?ccb=11-4&oh=df36c5b990497b8a5758a0f1ad8118a8&oe=620AA726
Unique identifier for the avatar imageExample: 1635239861
Media type of the avatarExample: image
Example Request
curl -X GET 'http://localhost:3000/user/[email protected]&is_preview=true' \
-u 'username:password' \
-H 'X-Device-Id: my-device-id'
Response Example
{
"code": "SUCCESS",
"message": "Success",
"results": {
"url": "https://pps.whatsapp.net/v/t61.24694-24/181358562_385581386633509_6230178822944778044_n.jpg?ccb=11-4&oh=df36c5b990497b8a5758a0f1ad8118a8&oe=620AA726",
"id": "1635239861",
"type": "image"
}
}
Update your own WhatsApp profile picture.Authentication
Basic authentication credentials (username:password in base64)
Device identifier for multi-device support. Required when multiple devices are registered. If only one device is registered, it will be used as the default.
Request Body
Image file to use as your profile picture (binary data)Supported formats: JPEG, PNG, WebP
Response
Response code indicating success or failureExample: SUCCESS
Human-readable response messageExample: Success
Additional result data (typically null)Example: null
Example Request
curl -X POST 'http://localhost:3000/user/avatar' \
-u 'username:password' \
-H 'X-Device-Id: my-device-id' \
-F 'avatar=@/path/to/image.jpg'
Response Example
{
"code": "SUCCESS",
"message": "Success",
"results": null
}