Chats
Vote in Poll
POST
/api/v1/chat/poll/voteVote in a poll.
Parameters
- ChatstringRequired
The chat id: a person (…@s.whatsapp.net or …@lid) or a group (…@g.us).
- SenderstringRequired
Who created the poll.
- IdstringRequired
The poll message id.
- FromMebooleanRequired
true if you created the poll.
- OptionsarrayRequired
The exact option names you pick. An empty list removes your vote.
| Name | Type | Required | Description |
|---|---|---|---|
| Chat | string | Yes | The chat id: a person (…@s.whatsapp.net or …@lid) or a group (…@g.us). |
| Sender | string | Yes | Who created the poll. |
| Id | string | Yes | The poll message id. |
| FromMe | boolean | Yes | true if you created the poll. |
| Options | array | Yes | The exact option names you pick. An empty list removes your vote. |
Code Examples
cURL
curl -X POST "https://orvachat.com/api/v1/chat/poll/vote" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"Chat": "[email protected]",
"Sender": "[email protected]",
"Id": "3EB0ABCDEF1234567890",
"FromMe": false,
"Options": [
"Saturday"
]
}'