Send a batch of emails
/emails/batchQueues up to 100 emails in one request. x-batch-validation: strict (default) rejects the whole batch when one item is invalid; permissive sends the valid items and returns errors[] with the index of each rejected one.
Authorization
apiKey A project API key: Authorization: Bearer s0_…
In: header
Header Parameters
1 <= length <= 256Value in
- "strict"
- "permissive"
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
1 <= items <= 100Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/emails/batch" \ -H "Content-Type: application/json" \ -d '[ { "to": "string" } ]'{ "data": [ { "id": "string" } ], "errors": [ { "index": 0, "message": "string" } ]}Send an email POST
Queues one email for sending through SES in your AWS account. Accepts `scheduled_at` (ISO 8601 or natural language, up to 30 days ahead) and an `Idempotency-Key` header. The `from` domain must be a verified domain of the project with sending enabled. With `template: { id, variables }` (a published template by id or alias) the body comes from the template; `html` and `text` may then not be set, and `from`, `subject` and `reply_to` override the template defaults.
Retrieve an email GET
One sent email with its last event. `html` and `text` are read back from your S3 bucket and are null when they cannot be read.