Skip to main content
POST
/
v1
/
broadcasts
Create Broadcast
curl --request POST \
  --url https://api.example.com/v1/broadcasts \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "audience_id": "<string>",
  "from": "<string>",
  "subject": "<string>",
  "html": "<string>",
  "text": "<string>"
}
'
name
string
required
The name of the broadcast.
audience_id
string
required
The ID of the audience to send to.
from
string
required
Sender email address.
subject
string
required
Email subject line.
html
string
HTML content of the email.
text
string
Plain text content.

Request

cURL
curl -X POST https://www.unosend.co/api/v1/broadcasts \
  -H "Authorization: Bearer un_xxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "January Newsletter",
    "audience_id": "aud_123",
    "from": "[email protected]",
    "subject": "January Updates",
    "html": "<h1>Happy New Year!</h1>"
  }'

Response

200
{
  "id": "bc_123",
  "name": "January Newsletter",
  "status": "draft",
  "created_at": "2024-01-15T10:30:00.000Z"
}