v46

latestOpenAPI 3.0.3raw.githubusercontent.com2025-05-151340367.2 KB
Message Controller

Send Poll

Send Poll

post/message/sendPoll/{instance}

Path parameters

instancestring required

Name of the instance

Request body

numberstring required

{{remoteJid}}

namestring required

Main text of the poll

selectableCountnumber required

Ex: 1

valuesstring[] required

Values for question

delayinteger

Presence time in milliseconds before sending message

linkPreviewboolean

Shows a preview of the target website if there's a link within the message

mentionsEveryOneboolean

Mentioned everyone when the message send

mentionedstring[]

Numbers to mention

Response

Created

messageTimestampstring

The timestamp of the message, represented as a string.

statusstring

The status of the message, such as sent, received, or pending.

Example response

{
  "key": {
    "remoteJid": "553198296801@s.whatsapp.net",
    "fromMe": true,
    "id": "BAE53EC8D8E1FD8A"
  },
  "message": {
    "messageContextInfo": {
      "messageSecret": "lX/+cLHHNfnTTKZi+88mrhoyi6KNuUzWjgfaB0bTfOY="
    },
    "pollCreationMessage": {
      "name": "Poll Name",
      "options": [
        {
          "optionName": "Option 1"
        },
        {
          "optionName": "Option 2"
        },
        {
          "optionName": "Option 3"
        }
      ],
      "selectableOptionsCount": 1
    }
  },
  "messageTimestamp": "1717781848",
  "status": "PENDING"
}