Create a new broadcast campaign. Add contacts after creation, then send.
curl --request POST \
--url https://api.zavu.dev/v1/broadcasts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "Black Friday Sale",
"channel": "sms",
"text": "Hi {{name}}, check out our Black Friday deals! Use code FRIDAY20 for 20% off."
}
'{
"broadcast": {
"id": "brd_abc123",
"name": "<string>",
"status": "draft",
"channel": "smart",
"messageType": "text",
"totalContacts": 123,
"createdAt": "2023-11-07T05:31:56Z",
"text": "<string>",
"content": {
"mediaUrl": "<string>",
"mediaId": "<string>",
"mimeType": "<string>",
"filename": "<string>",
"templateId": "<string>",
"templateVariables": {}
},
"senderId": "<string>",
"emailSubject": "<string>",
"pendingCount": 123,
"sendingCount": 123,
"deliveredCount": 123,
"failedCount": 123,
"estimatedCost": 123,
"reservedAmount": 123,
"actualCost": 123,
"scheduledAt": "2023-11-07T05:31:56Z",
"startedAt": "2023-11-07T05:31:56Z",
"completedAt": "2023-11-07T05:31:56Z",
"metadata": {},
"updatedAt": "2023-11-07T05:31:56Z",
"reviewResult": {
"score": 123,
"categories": [
"<string>"
],
"reasoning": "<string>",
"reviewedAt": "2023-11-07T05:31:56Z",
"flaggedContent": [
"<string>"
]
},
"reviewAttempts": 123
}
}Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Name of the broadcast campaign.
"Black Friday Sale"
Broadcast delivery channel. Use 'smart' for per-contact intelligent routing.
smart, sms, sms_oneway, whatsapp, telegram, email, instagram, voice Type of message for broadcast.
text, image, video, audio, document, template Text content or caption. Supports template variables: {{name}}, {{1}}, etc.
"Hi {{name}}, check out our Black Friday deals!"
Content for non-text broadcast message types.
Show child attributes
Sender profile ID. Uses default sender if omitted.
Email subject line. Required for email broadcasts.
HTML body for email broadcasts.
Schedule the broadcast for future delivery.
Show child attributes
Idempotency key to prevent duplicate broadcasts.
Broadcast created.
Show child attributes
curl --request POST \
--url https://api.zavu.dev/v1/broadcasts \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "Black Friday Sale",
"channel": "sms",
"text": "Hi {{name}}, check out our Black Friday deals! Use code FRIDAY20 for 20% off."
}
'{
"broadcast": {
"id": "brd_abc123",
"name": "<string>",
"status": "draft",
"channel": "smart",
"messageType": "text",
"totalContacts": 123,
"createdAt": "2023-11-07T05:31:56Z",
"text": "<string>",
"content": {
"mediaUrl": "<string>",
"mediaId": "<string>",
"mimeType": "<string>",
"filename": "<string>",
"templateId": "<string>",
"templateVariables": {}
},
"senderId": "<string>",
"emailSubject": "<string>",
"pendingCount": 123,
"sendingCount": 123,
"deliveredCount": 123,
"failedCount": 123,
"estimatedCost": 123,
"reservedAmount": 123,
"actualCost": 123,
"scheduledAt": "2023-11-07T05:31:56Z",
"startedAt": "2023-11-07T05:31:56Z",
"completedAt": "2023-11-07T05:31:56Z",
"metadata": {},
"updatedAt": "2023-11-07T05:31:56Z",
"reviewResult": {
"score": 123,
"categories": [
"<string>"
],
"reasoning": "<string>",
"reviewedAt": "2023-11-07T05:31:56Z",
"flaggedContent": [
"<string>"
]
},
"reviewAttempts": 123
}
}