Campaigns
Authorization
bearer In: header
Path Parameters
Response Body
application/json
curl -X GET "https://example.com/projects/string/campaigns"[ { "id": "string", "name": "string", "subject": "string", "fromEmail": "contact@mail.exemple.com", "fromName": "string", "previewText": "string", "status": "DRAFT", "scheduledAt": "2019-08-24T14:15:22Z", "sentAt": "2019-08-24T14:15:22Z", "templateId": "string", "domainId": "string", "audienceId": "string", "appId": "string", "abTestEnabled": true, "abTestSamplePercent": 0, "abTestMetric": "OPEN_RATE", "abTestDurationMinutes": 0, "abTestStartedAt": "2019-08-24T14:15:22Z", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z" }]Authorization
bearer In: header
Path Parameters
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/campaigns" \ -H "Content-Type: application/json" \ -d '{ "name": "Summer Newsletter", "subject": "Our summer deals are here 🌞", "fromEmail": "hello@yourdomain.com", "templateId": "tpl_abc123", "domainId": "dom_abc123", "audienceId": "aud_abc123" }'{ "id": "string", "name": "string", "subject": "string", "fromEmail": "contact@mail.exemple.com", "fromName": "string", "previewText": "string", "status": "DRAFT", "scheduledAt": "2019-08-24T14:15:22Z", "sentAt": "2019-08-24T14:15:22Z", "templateId": "string", "domainId": "string", "audienceId": "string", "appId": "string", "abTestEnabled": true, "abTestSamplePercent": 0, "abTestMetric": "OPEN_RATE", "abTestDurationMinutes": 0, "abTestStartedAt": "2019-08-24T14:15:22Z", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z"}Authorization
bearer In: header
Path Parameters
Response Body
application/json
curl -X GET "https://example.com/projects/string/campaigns/string"{ "id": "string", "name": "string", "subject": "string", "fromEmail": "contact@mail.exemple.com", "fromName": "string", "previewText": "string", "status": "DRAFT", "scheduledAt": "2019-08-24T14:15:22Z", "sentAt": "2019-08-24T14:15:22Z", "templateId": "string", "domainId": "string", "audienceId": "string", "appId": "string", "abTestEnabled": true, "abTestSamplePercent": 0, "abTestMetric": "OPEN_RATE", "abTestDurationMinutes": 0, "abTestStartedAt": "2019-08-24T14:15:22Z", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "variants": [ { "id": "string", "campaignId": "string", "name": "string", "subject": "string", "templateId": "string", "weight": 0, "isWinner": true, "createdAt": "2019-08-24T14:15:22Z", "stats": { "sent": 0, "opened": 0, "clicked": 0, "openRate": 0, "clickRate": 0 } } ], "stats": { "total": 0, "delivered": 0, "opened": 0, "clicked": 0, "bounced": 0 }}Authorization
bearer In: header
Path Parameters
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X PATCH "https://example.com/projects/string/campaigns/string" \ -H "Content-Type: application/json" \ -d '{}'{ "id": "string", "name": "string", "subject": "string", "fromEmail": "contact@mail.exemple.com", "fromName": "string", "previewText": "string", "status": "DRAFT", "scheduledAt": "2019-08-24T14:15:22Z", "sentAt": "2019-08-24T14:15:22Z", "templateId": "string", "domainId": "string", "audienceId": "string", "appId": "string", "abTestEnabled": true, "abTestSamplePercent": 0, "abTestMetric": "OPEN_RATE", "abTestDurationMinutes": 0, "abTestStartedAt": "2019-08-24T14:15:22Z", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z"}Authorization
bearer In: header
Path Parameters
Response Body
application/json
curl -X DELETE "https://example.com/projects/string/campaigns/string"{ "deleted": true}Authorization
bearer In: header
Path Parameters
Response Body
application/json
curl -X POST "https://example.com/projects/string/campaigns/string/cancel"{ "id": "string", "name": "string", "subject": "string", "fromEmail": "contact@mail.exemple.com", "fromName": "string", "previewText": "string", "status": "DRAFT", "scheduledAt": "2019-08-24T14:15:22Z", "sentAt": "2019-08-24T14:15:22Z", "templateId": "string", "domainId": "string", "audienceId": "string", "appId": "string", "abTestEnabled": true, "abTestSamplePercent": 0, "abTestMetric": "OPEN_RATE", "abTestDurationMinutes": 0, "abTestStartedAt": "2019-08-24T14:15:22Z", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z"}Authorization
bearer In: header
Path Parameters
Response Body
application/json
curl -X POST "https://example.com/projects/string/campaigns/string/ab-test/cancel"{ "id": "string", "name": "string", "subject": "string", "fromEmail": "contact@mail.exemple.com", "fromName": "string", "previewText": "string", "status": "DRAFT", "scheduledAt": "2019-08-24T14:15:22Z", "sentAt": "2019-08-24T14:15:22Z", "templateId": "string", "domainId": "string", "audienceId": "string", "appId": "string", "abTestEnabled": true, "abTestSamplePercent": 0, "abTestMetric": "OPEN_RATE", "abTestDurationMinutes": 0, "abTestStartedAt": "2019-08-24T14:15:22Z", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z"}Authorization
bearer In: header
Path Parameters
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/campaigns/string/ab-test/select-winner" \ -H "Content-Type: application/json" \ -d '{ "variantId": "clx1234567890" }'{ "id": "string", "name": "string", "subject": "string", "fromEmail": "contact@mail.exemple.com", "fromName": "string", "previewText": "string", "status": "DRAFT", "scheduledAt": "2019-08-24T14:15:22Z", "sentAt": "2019-08-24T14:15:22Z", "templateId": "string", "domainId": "string", "audienceId": "string", "appId": "string", "abTestEnabled": true, "abTestSamplePercent": 0, "abTestMetric": "OPEN_RATE", "abTestDurationMinutes": 0, "abTestStartedAt": "2019-08-24T14:15:22Z", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z"}Authorization
bearer In: header
Path Parameters
Response Body
application/json
curl -X POST "https://example.com/projects/string/campaigns/string/send"{ "success": true}Authorization
bearer In: header
Path Parameters
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/campaigns/string/test" \ -H "Content-Type: application/json" \ -d '{ "to": "test@exemple.com" }'{ "success": true, "sent": 0}Authorization
bearer In: header
Path Parameters
Response Body
application/json
curl -X POST "https://example.com/projects/string/campaigns/string/test-seed-list"{ "success": true, "sent": 0}Authorization
bearer In: header
Path Parameters
Response Body
application/json
curl -X POST "https://example.com/projects/string/campaigns/string/duplicate"{ "id": "string", "name": "string", "subject": "string", "fromEmail": "contact@mail.exemple.com", "fromName": "string", "previewText": "string", "status": "DRAFT", "scheduledAt": "2019-08-24T14:15:22Z", "sentAt": "2019-08-24T14:15:22Z", "templateId": "string", "domainId": "string", "audienceId": "string", "appId": "string", "abTestEnabled": true, "abTestSamplePercent": 0, "abTestMetric": "OPEN_RATE", "abTestDurationMinutes": 0, "abTestStartedAt": "2019-08-24T14:15:22Z", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z"}Authorization
bearer In: header
Path Parameters
Response Body
text/csv
curl -X GET "https://example.com/projects/string/campaigns/string/sends/export""string"Authorization
bearer In: header
Path Parameters
Query Parameters
Response Body
application/json
curl -X GET "https://example.com/projects/string/campaigns/string/sends?status=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}