POST
/
v1
/
emails
/
batch
curl --request POST \
  --url https://app.unsend.dev/api/v1/emails/batch \
  --header 'Content-Type: application/json' \
  --data '[
  {
    "to": "[email protected]",
    "from": "[email protected]",
    "subject": "<string>",
    "templateId": "<string>",
    "variables": {},
    "replyTo": "[email protected]",
    "cc": "[email protected]",
    "bcc": "[email protected]",
    "text": "<string>",
    "html": "<string>",
    "attachments": [
      {
        "filename": "<string>",
        "content": "<string>"
      }
    ],
    "scheduledAt": "2023-11-07T05:31:56Z"
  }
]'
{
  "data": [
    {
      "emailId": "<string>"
    }
  ]
}

Send up to 100 emails in a single request.

Body

application/json · object[]
to
required
from
string
required
subject
string

Optional when templateId is provided

Minimum length: 1
templateId
string

ID of a template from the dashboard

variables
object
replyTo
cc
bcc
text
string | null
Minimum length: 1
html
string | null
Minimum length: 1
attachments
object[]
scheduledAt
string

Response

200 - application/json
List of successfully created email IDs
data
object[]
required