Skip to Content

Batch send

Send up to 100 emails in one request with POST /emails/batch.

Endpoint

POST /emails/batch
Authorization: Bearer pb_…
Content-Type: application/json

Body

Send a JSON array of email objects. Each element accepts the same fields as Send email, with these restrictions:

  • Maximum 100 messages per request
  • No attachments
  • No scheduled_at
curl -X POST https://api.postbound.app/emails/batch \
  -H "Authorization: Bearer pb_…" \
  -H "Content-Type: application/json" \
  -d '[
    {
      "from": "[email protected]",
      "to": ["[email protected]"],
      "subject": "Hello one",
      "html": "<p>One</p>"
    },
    {
      "from": "[email protected]",
      "to": ["[email protected]"],
      "subject": "Hello two",
      "html": "<p>Two</p>"
    }
  ]'

Response

A list of created ids (same order as the request). Failed validation of the batch returns an error without partially creating messages when the payload cannot be accepted; treat the whole call as transactional from the client’s point of view and use per-message sends if you need independent failure handling.

When to use batch vs single

Prefer batchPrefer single POST /emails
Many small transactional messagesAttachments or scheduling
Fan-out with shared template vars computed client-sideNeed per-message idempotency keys

On this page