Send Poll / Vote
Body Required
-
The WhatsApp phone number to send the poll to, including the '@s.whatsapp.net' suffix.
-
The question for the poll.
-
The options for the poll.
-
The maximum number of answers allowed for the poll.
POST
/send/poll
curl \
-X POST http://localhost:3000/send/poll \
-H "Content-Type: application/json" \
-d '{"phone":"6289685024421@s.whatsapp.net","question":"Siapa Nama Avatar The Last Air Bender?","options":["Zuko","Aang","Katara"],"max_answer":2}'
Request examples
{
"phone": "6289685024421@s.whatsapp.net",
"question": "Siapa Nama Avatar The Last Air Bender?",
"options": [
"Zuko",
"Aang",
"Katara"
],
"max_answer": 2
}
Response examples (200)
{
"code": "SUCCESS",
"message": "Success",
"results": {
"message_id": "3EB0B430B6F8F1D0E053AC120E0A9E5C",
"status": "<feature> success ...."
}
}
Response examples (400)
{
"code": 400,
"message": "field cannot be blank",
"results": {}
}
Response examples (500)
{
"code": "INTERNAL_SERVER_ERROR",
"message": "you are not loggin",
"results": {}
}