Broadcasts
A broadcast is one newsletter sent to every subscribed contact in an audience. This page covers writing one, the checks it must pass, test sends, and sending it now or on a schedule.
How a broadcast moves
Every broadcast has a status:
| Status | Meaning |
|---|---|
draft | Being written. Only drafts can be edited or sent. |
scheduled | Waiting for its scheduled_at. Cancel it to edit it again. |
sending | Sendfern is creating one email per recipient. |
sent | Every recipient's email has been created. Each one then has its own status and events. |
Editing anything but a draft is 400 not_editable. A broadcast that cannot go out when it is due goes back to draft with the reason in error; see Due but blocked.
Create a broadcast
Write the content as HTML and plain text yourself, or as a list of blocks that Sendfern turns into email-safe HTML and text for you. Both start as a draft.
POST/v1/broadcasts
Body
audience_idstringrequired- The audience to send to.
fromstringrequirednews@acme.comorAcme <news@acme.com>. Live sends need a verified domain for this address.subjectstringrequired- No line breaks. Variables are allowed.
namestring- Optional. Only you see it, in the dashboard and in lists.
reply_tostring | string[]- Optional. One address or a list.
htmlstring- The HTML body. Ignored when you send
blocks. textstring- The plain-text body. Ignored when you send
blocks. You can save a draft with onlyhtmlor onlytext, but sending needs a plain-text version. blocksarray | null- Content as blocks. See Write it with blocks.
nullmeans the broadcast is written as raw HTML. preview_textstring- Optional, up to 200 characters, no line breaks. The short line inboxes show after the subject. Used only with
blocks.
Write it as HTML and text
curl https://api.sendfern.com/v1/broadcasts \
-H "Authorization: Bearer $SENDFERN_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "December update",
"audience_id": "aud_3hX9kQpL2vNcR8tYwB4mZe",
"from": "Acme <news@acme.com>",
"reply_to": "support@acme.com",
"subject": "What is new at Acme, {{first_name}}",
"html": "<p>Hi {{first_name}},</p><p>Here is what we shipped.</p><p><a href=\"{{unsubscribe_url}}\">Unsubscribe</a></p>",
"text": "Hi {{first_name}},\n\nHere is what we shipped.\n\nUnsubscribe: {{unsubscribe_url}}"
}'{
"id": "bc_5Tn8wQ2mLx7VcK4pRz9HbE",
"name": "December update",
"audience_id": "aud_3hX9kQpL2vNcR8tYwB4mZe",
"from": "Acme <news@acme.com>",
"reply_to": ["support@acme.com"],
"subject": "What is new at Acme, {{first_name}}",
"preview_text": "",
"blocks": null,
"html": "<p>Hi {{first_name}},</p>...",
"text": "Hi {{first_name}},...",
"status": "draft",
"scheduled_at": null,
"error": "",
"recipient_count": 0,
"sent_at": null,
"created_at": "2026-11-28T10:19:04Z"
}If the HTML or the text has no {{unsubscribe_url}}, Sendfern adds an Unsubscribe link at the end of it, so every copy can be unsubscribed from. Place the link yourself to control where it goes.
Use variables
The subject, HTML and text can use these variables. Each recipient gets their own values:
| Variable | Value |
|---|---|
{{first_name}} | The contact's first name, or empty. |
{{last_name}} | The contact's last name, or empty. |
{{email}} | The contact's address. |
{{unsubscribe_url}} | A link that unsubscribes this contact from this audience. See Unsubscribe. |
Values are HTML-escaped in the HTML body. A variable Sendfern does not know is left exactly as written, so check a test send before you send.
Write it with blocks
Send blocks instead of html and text, and Sendfern renders table-based email HTML and a plain-text version from them every time you save. Any html or text in the same request is ignored. This is what the newsletter builder in the dashboard uses.
curl https://api.sendfern.com/v1/broadcasts \
-H "Authorization: Bearer $SENDFERN_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "December update",
"audience_id": "aud_3hX9kQpL2vNcR8tYwB4mZe",
"from": "Acme <news@acme.com>",
"subject": "What is coming in December",
"preview_text": "A first look at the new dashboard",
"blocks": [
{"type": "heading", "text": "What is coming in December", "level": 1},
{"type": "text", "text": "Hi {{first_name}}, here is a first look."},
{"type": "image", "url": "https://acme.com/img/dashboard.png", "alt": "The new dashboard"},
{"type": "button", "label": "Try it early", "url": "https://acme.com/early", "align": "left"},
{"type": "divider"},
{"type": "footer", "text": "You get this because you signed up at acme.com.", "address": "Acme Inc, 1 Main St"}
]
}'There are eight block types. Each is an object with a type and the fields below:
| Type | Fields |
|---|---|
heading | text (required, up to 200 characters), level (1 or 2) |
text | text (required, up to 5,000 characters) |
image | url (required), alt (up to 300 characters), link (a URL or null) |
button | label (required, up to 100 characters), url (required), color (6-digit hex such as #2a64e0), align (left, center or full), radius (0 to 24) |
columns | columns (required): exactly two objects, each with a heading (up to 200 characters) and text (up to 2,000) |
divider | No fields. |
spacer | height in pixels, 4 to 120 |
footer | text (up to 1,000 characters), address (up to 300) |
- At most 60 blocks. An unknown
typeor an unknown field is 400. - URLs must start with
http://orhttps://and cannot contain variables. Variables work intext,label,headingand the footer'stext. - All text is escaped, so it shows exactly as you wrote it. Blocks cannot contain raw HTML.
- A
footerblock always gets the unsubscribe link. Without one, a standard footer with the link is added. - A bad block is 400
invalid_parameterwithparampointing at it, for exampleblocks[3].url.
Upload images
Image blocks need a public URL. To host an image with Sendfern, upload it as multipart/form-data in the file field and use the url from the response. PNG, JPEG and GIF are accepted, up to 2 MB. The type is read from the file's contents, not its name. Anything else is 400 with param: "file". The SDKs have no upload method yet, so use cURL or any HTTP client that can send a multipart form.
POST/v1/assets
curl https://api.sendfern.com/v1/assets \
-H "Authorization: Bearer $SENDFERN_API_KEY" \
-F "file=@dashboard.png"{
"id": "ast_8Kq2nVx5LmP9cR3tWz7YbD",
"url": "https://..."
}Edit, list and delete
PATCH /v1/broadcasts/{id} changes a draft. GET /v1/broadcasts lists your broadcasts, newest first, and takes the optional filters status, audience_id and q (text in the name or subject). DELETE /v1/broadcasts/{id} deletes one.
Check before you send
POST /v1/broadcasts/{id}/checks runs the same checks as sending, changes nothing, and tells you how many people would get the broadcast. The dashboard shows it as the "Before you send" list.
curl -X POST https://api.sendfern.com/v1/broadcasts/bc_5Tn8wQ2mLx7VcK4pRz9HbE/checks \
-H "Authorization: Bearer $SENDFERN_API_KEY"{
"checks": [
{"id": "unsubscribe_link", "ok": true, "level": "error"},
{"id": "domain_verified", "ok": true, "level": "error"},
{"id": "text_version", "ok": true, "level": "error"},
{"id": "image_alt_text", "ok": false, "level": "warning", "message": "1 image has no alt text"}
],
"recipient_count": 1180,
"skipped": {"unsubscribed": 24, "suppressed": 6}
}| Check | Level | Passes when |
|---|---|---|
unsubscribe_link | error | The HTML and text both contain the unsubscribe link. |
domain_verified | error | The From address uses a verified domain. Live mode only. |
text_version | error | There is a plain-text version. Blocks broadcasts always have one. |
account_active | error | Shown only when your account cannot send live email, for example while it is in review. |
image_alt_text | warning | Every image has alt text. |
Sending is refused with 400 checks_failed while any error check fails. Warnings never block a send. recipient_count is the number of emails the send would create: subscribed contacts minus suppressed addresses. skipped says how many contacts are left out and why. Suppressed addresses are counted in live mode only.
Send a test
Send one copy to yourself to see how it looks. It works in any status and does not change the broadcast.
POST/v1/broadcasts/{id}/test
curl https://api.sendfern.com/v1/broadcasts/bc_5Tn8wQ2mLx7VcK4pRz9HbE/test \
-H "Authorization: Bearer $SENDFERN_API_KEY" \
-H "Content-Type: application/json" \
-d '{"to": "user@example.com"}'- The response is 201 with the email it created. It is not linked to the broadcast (
broadcast_idisnull, with the tagbroadcast_testset to the broadcast id), so it never counts in the broadcast's stats. - Variables get sample values:
Jane,Doe, and the test address for{{email}}. - The unsubscribe link opens a page that says it is a test and changes nothing. See Unsubscribe.
- It is sent in the broadcast's mode, so a live test needs an active account and a verified domain, and is skipped if the address is on your suppression list.
Send or schedule
POST /v1/broadcasts/{id}/send with no body sends now: the status becomes sending, then sent. With scheduled_at (ISO 8601, in the future, at most 30 days ahead) the status becomes scheduled, and the broadcast goes out within a minute of that time.
# Send now
curl -X POST https://api.sendfern.com/v1/broadcasts/bc_5Tn8wQ2mLx7VcK4pRz9HbE/send \
-H "Authorization: Bearer $SENDFERN_API_KEY"
# Or schedule it
curl https://api.sendfern.com/v1/broadcasts/bc_5Tn8wQ2mLx7VcK4pRz9HbE/send \
-H "Authorization: Bearer $SENDFERN_API_KEY" \
-H "Content-Type: application/json" \
-d '{"scheduled_at": "2026-12-01T09:00:00Z"}'The response is the broadcast. Before anything changes, Sendfern checks that:
- The broadcast is a draft. Otherwise 400
already_sent; cancel a scheduled broadcast first. - For live mode, your account is active (403
account_not_active) and the From domain is verified (403domain_not_verified). - The whole audience fits in your remaining monthly quota. A broadcast never goes out halfway, so if
recipient_countis more than you have left, nothing is sent: 403quota_exceeded. See Rate limits and quotas. - Every
errorcheck passes. Otherwise 400checks_failed.
Each recipient gets their own email with their own id, status and events, and the broadcast_id set. Find them with GET /v1/emails?broadcast_id=bc_.... Unsubscribed contacts are skipped, and suppressed addresses are skipped when each email is sent. Contacts added after the send starts are not included.
Cancel a scheduled broadcast
POST /v1/broadcasts/{id}/cancel puts a scheduled broadcast back to draft and clears scheduled_at, so you can edit it and send it again. Anything that is not scheduled is 400 not_cancelable.
curl -X POST https://api.sendfern.com/v1/broadcasts/bc_5Tn8wQ2mLx7VcK4pRz9HbE/cancel \
-H "Authorization: Bearer $SENDFERN_API_KEY"Due but blocked
When a broadcast is about to go out, whether you sent it now or it was scheduled, Sendfern checks again that your account can send, the From domain is still verified, and the audience fits in your quota. If not, nothing is sent: the status goes back to draft, scheduled_at is cleared, and error says why. Fix the cause and send it again; the next send clears error.
If sending stops being allowed while a large broadcast is part way through, it stays sending, error starts with "Stopped partway", and it carries on from where it stopped once sending is allowed again. Nobody gets the broadcast twice.
Stats
GET /v1/broadcasts/{id} adds stats to the broadcast (the list does not).
curl https://api.sendfern.com/v1/broadcasts/bc_5Tn8wQ2mLx7VcK4pRz9HbE \
-H "Authorization: Bearer $SENDFERN_API_KEY"{
"id": "bc_5Tn8wQ2mLx7VcK4pRz9HbE",
"status": "sent",
"recipient_count": 1180,
"sent_at": "2026-12-01T09:00:41Z",
...
"stats": {
"sent": 1180,
"delivered": 1171,
"opened": 612,
"clicked": 148,
"bounced": 9,
"complained": 1,
"unsubscribed": 7
}
}sent counts the broadcast's emails that were handed to the mail servers. Every other number counts emails with at least one event of that kind, so an email opened three times counts once in opened. unsubscribed counts people who used this broadcast's unsubscribe link or marked it as spam. Opens and clicks need tracking to be on for the domain. For counts over time, use GET /v1/stats?broadcast_id=.
Test mode
A test key creates and sees only test broadcasts, and a live broadcast is 404 to it, so a test key can never send a live newsletter. A test broadcast goes through every step but sends nothing: each recipient's email gets a simulated outcome from its address, as described in Test mode. The audience is the same in both modes. Uploading images needs a live key.
Next steps
Build the list in Audiences and contacts, read how people leave it in Unsubscribe, and get per-email events with webhooks. Every field is in the API reference.