POST
/
send-message
/
poll
cURL
curl --request POST \
  --url https://api.crunchz.app/api/send-message/poll \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "contact_id": "xxx@c.us",
  "title": "Are you have a bachelor degree ?",
  "options": [
    "Yes",
    "No",
    "I don'\''t think so"
  ],
  "is_multiple_answer": false,
  "reply_to": "message_id_here"
}'
{
  "success": true,
  "message": "<string>",
  "data": {
    "status": "<string>",
    "message": "<string>",
    "timestamp": "<string>"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
contact_id
string
required

Message ID.

Example:

"xxx@c.us"

title
string
required

Polling title

Example:

"Are you have a bachelor degree ?"

options
string[]
required

Polling Name

Example:
["Yes", "No", "I don't think so"]
is_multiple_answer
boolean
required

Multiple Answer ( user can choose more than one answer )

Example:

false

reply_to
string

Message ID to reply to (optional)

Example:

"message_id_here"

Response

PollMessageResource

success
boolean
required

The success status of response.

message
string
required

The message of response.

data
object
required