Code-based Actions: Send email to multiple recipients
Use cloud code to send email to multiple recipients.
Send email to 1 recipient
The following example shows you how to send an email to a single recipient:
async payload => {
// Send an email
toolbelt.email({
to: 'email1@yourdomain.com',
subject: 'Report needed',
message: 'If only you knew the power of the dark side.'
})
}
Send email to multiple recipients
The following example allows you to send an email to multiple recipients by creating an array:
async payload => {
// Send an email
toolbelt.email({
to: ['email1@yourdomain.com','email2@yourdomain.com'],
subject: 'Report needed',
message: 'If only you knew the power of the dark side.'
})
}
Updated about 1 year ago