Emails
Authorization
bearer In: header
Path Parameters
Header Parameters
Replay-safe for 24 hours: a retry with the same key returns the original result instead of sending again. Past that, the key is forgotten and the same request sends a new email. If a request with the same key is still being processed, you get a 409 — retry shortly instead of assuming it failed.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "https://example.com/projects/string/emails" \ -H "Content-Type: application/json" \ -d '{ "to": [ "recipient@example.com" ], "from": "hello@yourdomain.com", "subject": "Welcome, {{first_name}}!" }'{ "id": "string", "messageId": "string", "status": "SENT"}Authorization
bearer In: header
Path Parameters
Header Parameters
Replay-safe for 24 hours: a retry with the same key returns the original batch result instead of resending it. Past that, the key is forgotten and the same request sends the batch again. If a request with the same key is still being processed, you get a 409 — retry shortly instead of assuming it failed.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "https://example.com/projects/string/emails/batch" \ -H "Content-Type: application/json" \ -d '{ "emails": [ { "to": [ "recipient@example.com" ], "from": "hello@yourdomain.com", "subject": "Welcome, {{first_name}}!" } ] }'{ "data": [ { "id": "string", "messageId": "string", "status": "SENT", "error": "string" } ]}Authorization
bearer In: header
Path Parameters
Response Body
application/json
curl -X GET "https://example.com/projects/string/emails/logs/string"{ "id": "string", "status": "QUEUED", "messageId": "string", "subject": "string", "from": "string", "deliveredAt": "2019-08-24T14:15:22Z", "openedAt": "2019-08-24T14:15:22Z", "clickedAt": "2019-08-24T14:15:22Z", "bouncedAt": "2019-08-24T14:15:22Z", "complainedAt": "2019-08-24T14:15:22Z", "createdAt": "2019-08-24T14:15:22Z", "contact": { "id": "string", "email": "string" }, "webhookEvents": [ { "id": "string", "type": "Delivery", "createdAt": "2019-08-24T14:15:22Z" } ]}Authorization
bearer In: header
Path Parameters
Query Parameters
Response Body
application/json
curl -X GET "https://example.com/projects/string/emails/logs?status=string&q=string"{ "data": [ { "id": "string", "status": "QUEUED", "messageId": "string", "subject": "string", "from": "string", "deliveredAt": "2019-08-24T14:15:22Z", "openedAt": "2019-08-24T14:15:22Z", "clickedAt": "2019-08-24T14:15:22Z", "bouncedAt": "2019-08-24T14:15:22Z", "complainedAt": "2019-08-24T14:15:22Z", "createdAt": "2019-08-24T14:15:22Z", "contact": { "id": "string", "email": "string" } } ], "total": 0, "page": 0, "pages": 0}