PATCH
/
broadcasts
/
:id
import { Resend } from 'resend';

const resend = new Resend('re_xxxxxxxxx');

await resend.broadcasts.update({
  id: '49a3999c-0ce1-4ea6-ab68-afcd6dc2e794',
  html: 'Hi {{{FIRST_NAME|there}}}, you can unsubscribe here: {{{RESEND_UNSUBSCRIBE_URL}}}',
});
{
  "id": "49a3999c-0ce1-4ea6-ab68-afcd6dc2e794"
}
You can update broadcasts only if they were created via the API.

Path Parameters

id
string
required
The ID of the broadcast you want to update.

Body Parameters

audience_id
string
The ID of the audience you want to send to.
from
string
Sender email address.To include a friendly name, use the format "Your Name <sender@domain.com>".
subject
string
Email subject.
reply_to
string | string[]
Reply-to email address. For multiple addresses, send as an array of strings.
html
string
The HTML version of the message.
text
string
The plain text version of the message.
react
React.ReactNode
The React component used to write the message. Only available in the Node.js SDK.
name
string
The friendly name of the broadcast. Only used for internal reference.