Send up to 500 completely different emails in a single API call.
Batch sending where each email can have:
- Different recipient
- Different subject
- Different content
- Different settings
- File attachments
- Calendar invites
Perfect for sending multiple transactional emails at once (order confirmations, password resets, etc.).
Limits:
- Maximum 500 emails per batch
- Each email validated independently
- Failed emails don't affect successful ones
Use cases:
- Sending different transactional emails simultaneously
- Mixed email types in one API call
- High-volume transactional sending
Not for: Newsletter-style emails with same content → Use /api/bulk-send instead
Idempotent retries: Pass an Idempotency-Key header (or idempotency_key body field) so a retried batch is not sent twice. Retrying with the same key within 24 hours replays the original response (X-Idempotent-Replay: true) instead of re-sending the batch. A retry while the original is still processing returns 409 Conflict. Keys are scoped to your account.
Optional campaign identifier for grouping related emails and tracking bounce rates.
Auto-pause protection: If bounce rate exceeds thresholds, the campaign will be automatically paused to protect IP reputation.
Best practice: Provide this when sending related batches (e.g., "daily-digest", "order-notifications-batch").
If not provided, system auto-generates: batch-{timestamp}-{customer_id}
- US Data Centerhttps://api.mailerlogic.net/api/v1/batch
- EU Data Center (coming soon)https://eu-api.mailerlogic.net/api/v1/batch
curl -i -X POST \
https://api.mailerlogic.net/api/v1/batch \
-H 'Content-Type: application/json' \
-H 'Idempotency-Key: batch-2026-07-08-run-1' \
-H 'X-API-Key: YOUR_API_KEY_HERE' \
-d '{
"emails": [
{
"to": "user1@example.com",
"subject": "Order #12345 Confirmed",
"html": "<h1>Thanks for your order!</h1><p>Order #12345</p>",
"text": "Thanks for your order! Order #12345",
"tag": "order-confirmation",
"stream_type": "transactional",
"metadata": {
"order_id": "12345"
}
},
{
"to": "user2@example.com",
"subject": "Password Reset Request",
"html": "<h1>Reset Password</h1><p><a href='\''https://...'\''>Click here</a></p>",
"text": "Reset your password: https://...",
"tag": "password-reset",
"stream_type": "transactional"
},
{
"to": "user3@example.com",
"from": "welcome@mail.yourdomain.com",
"from_name": "Welcome Team",
"subject": "Welcome to our platform!",
"html": "<h1>Welcome!</h1>",
"text": "Welcome!",
"tag": "welcome",
"stream_type": "transactional"
}
]
}'- All emails queued
- Partial success (some failed).
{ "total": 2, "queued": 2, "failed": 0, "results": [ { … }, { … } ] }