lumail.emails.batch

SDK 2.1.0 · API v2 · POST /api/v2/emails/batch

MethodPOST
/api/v2/emails/batch

[email protected] · lumail.emails

emails.batch(emails: SendEmailParams[], options?: { idempotencyKey?: string }): Promise<LumailResult<{ data: { id: string }[] }>>

Up to 100 sends. Each item matches emails.send. HTTP body is the JSON array.

Body Parameters

NameTypeDescription
emailsSendEmailParams[]Required. First argument. Array of send payloads. Max 100. Each item: from, to, subject, and exactly one of html, tiptap, or markdown. Also accepts text, reply_to, cc, bcc, headers, tags, preview.

Options

NameTypeDescription
idempotencyKeystringSecond-argument option. Mapped to the Idempotency-Key header. The server suffixes :index per item.

Response Fields

FieldTypeDescription
data{ id: string }[]Queued email ids, same order as the request.

data is { data: [{ id }] }. Failures return { data: null, error: { name, message, statusCode } }.