Every API here is available over the APIs.io API and to AI agents over MCP.
openapi: 3.2.0
info:
version: 2.1.1
title: Email Campaigns API
description: 'Create, manage, and report on email campaigns. Use this API to create standard
and split-test campaigns, update campaign content and settings, copy campaigns,
and delete campaigns. Send campaigns immediately, schedule them for a future
time, or use time-optimised sending. Retrieve reporting data including opens,
clicks, page views, replies, ROI, social bookmark views, bounce data, and
aggregate metrics filtered by date range. Supports split-test result retrieval
and custom from-address management.'
servers:
- url: https://{region}-api.dotdigital.com
variables:
region:
default: r1
enum:
- r1
- r2
- r3
description: The Dotdigital region id your account belongs to
security:
- basicAuth: []
tags:
- name: Email Campaigns
paths:
/v2/campaigns:
parameters:
- in: header
name: x-ddg-integration-token
required: false
description: If you are a partner of Dotdigital and have a [verified integration](https://developer.dotdigital.com/docs/partner-integration-verification) then include your [integration tracking token](https://developer.dotdigital.co/docs/verified-integration-tracking) here.
schema:
type: string
pattern: /^(?:\{{0,1}(?:[0-9a-fA-F]){8}-(?:[0-9a-fA-F]){4}-(?:[0-9a-fA-F]){4}-(?:[0-9a-fA-F]){4}-(?:[0-9a-fA-F]){12}\}{0,1})$/
example: 5a96bc79-19a7-4544-973b-e2da0c9136f9
post:
summary: Create campaign
deprecated: false
description: Creates a campaign
operationId: create-campaign
tags:
- Email Campaigns
parameters: []
requestBody:
content:
application/json:
schema:
type: object
required:
- name
- subject
- fromName
- htmlContent
- plainTextContent
properties:
name:
type: string
description: The name of the campaign being created
maxLength: 255
subject:
type: string
description: The email subject line of the campaign
fromName:
type: string
description: The from name of the campaign
fromAddress:
type: object
description: 'The registered custom from address you wish to use. Note: Specify either email or id and if not specified, the default fromAddress for the account is used.'
properties:
email:
type: string
description: The registered sender to use by email address
id:
type: integer
description: The registered sender to use by id
format: int32
htmlContent:
type: string
description: The HTML content of the campaign.
plainTextContent:
type: string
description: The plain text content of the campaign
replyAction:
type: string
description: The required action to be taken when a reply to the campaign is sent by the recipient
replyToAddress:
type: string
description: The email address that you would like replies to be forwarded to
type:
type: string
description: Choose a campaign type. Options are "Standard" or "Triggered". Omitting or adding any abnormal value defaults to Standard.
default: Standard
responses:
'200':
description: '200'
content:
application/json:
schema:
type: object
properties: {}
examples:
Result:
summary: Result
value: '{
"id": 6302600,
"name": "New product promotion 2",
"subject": "New product!",
"fromName": "Company name",
"fromAddress": {
"id": 133618,
"email": "products@mycompany.com"
},
"htmlContent": "\r\n<!-- Easy Editor -->\r\n<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" style=\"table-layout: auto;\" class=\"ee_resizable ee_mobiletemplate\" data-dmtmp=\"true\">\r\n <tbody>\r\n <tr>\r\n <td align=\"center\" bgcolor=\"#ffffff\" cellpadding=\"0\" cellspacing=\"0\">\r\n <table width=\"600\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" style=\"table-layout: auto;\" class=\"eem_mainouterzone\">\r\n <tbody>\r\n <tr>\r\n <td bgcolor=\"#ffffff\" class=\"ee_dropzone\" style=\"padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px;\" align=\"left\">\r\n <table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" style=\"width: 600px; background-color: rgb(255, 255, 255); table-layout: auto;\" class=\"ee_element\" bgcolor=\"#ffffff\">\r\n <tbody>\r\n <tr>\r\n <td align=\"left\" style=\"padding: 0px; width: 600px;\" class=\"\"><div class=\"ee_editable\"><font style=\"font-family: ''trebuchet ms'', verdana, arial, sans-serif; font-size: 13px;\"><a href=\"http://$UNSUB$\" style=\"color: black;\"> Unsubscribe from this newsletter</a></font> </div></td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n </td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n </td>\r\n </tr>\r\n </tbody>\r\n</table>",
"plainTextContent": "\r\n\r\n---\r\nWant to unsubscribe? $UNSUB$",
"replyAction": "Unset",
"replyToAddress": "",
"isSplitTest": false,
"status": "Unsent"
"type": "Standard"
}'
get:
summary: Get all campaigns
deprecated: true
description: Gets all campaigns
operationId: get-all-campaigns
tags:
- Email Campaigns
parameters:
- name: select
in: query
description: The number of records to select between 1 and 1000 to retrieve.
required: false
schema:
type: integer
format: int32
minimum: 1
maximum: 1000
default: 1000
- name: skip
in: query
description: The numbers of records to skip in the result set.
required: false
schema:
type: integer
minimum: 1
format: int32
responses:
'200':
description: '200'
content:
application/json:
schema:
type: array
items:
type: object
properties:
id:
type: integer
default: 0
examples:
- 2
name:
type: string
examples:
- Financial update
subject:
type: string
examples:
- Financial update
fromName:
type: string
examples:
- Company name
fromAddress:
type: object
properties:
id:
type: integer
default: 0
examples:
- 2
email:
type: string
examples:
- demo@apiconnector.com
htmlContent: {}
plainTextContent: {}
replyAction:
type: string
examples:
- Unset
replyToAddress: {}
isSplitTest:
type: boolean
default: true
examples:
- false
status:
type: string
examples:
- Unsent
examples:
Result:
summary: Result
value:
- id: 2
name: Financial update
subject: Financial update
fromName: Company name
fromAddress:
id: 2
email: demo@apiconnector.com
htmlContent: null
plainTextContent: null
replyAction: Unset
replyToAddress: null
isSplitTest: false
status: Unsent
- id: 4
name: New product promotion
subject: New product!
fromName: Company name
fromAddress:
id: 1
email: demo@apiconnector.com
htmlContent: null
plainTextContent: null
replyAction: WebMailForward
replyToAddress: demo@apiconnector.com
isSplitTest: false
status: Sent
/v2/campaigns/split-test:
parameters:
- in: header
name: x-ddg-integration-token
required: false
description: If you are a partner of Dotdigital and have a [verified integration](https://developer.dotdigital.com/docs/partner-integration-verification) then include your [integration tracking token](https://developer.dotdigital.co/docs/verified-integration-tracking) here.
schema:
type: string
pattern: /^(?:\{{0,1}(?:[0-9a-fA-F]){8}-(?:[0-9a-fA-F]){4}-(?:[0-9a-fA-F]){4}-(?:[0-9a-fA-F]){4}-(?:[0-9a-fA-F]){12}\}{0,1})$/
example: 5a96bc79-19a7-4544-973b-e2da0c9136f9
post:
summary: Create split test campaign
deprecated: false
description: Creates a split test campaign
operationId: create-split-test-campaign
tags:
- Email Campaigns
parameters: []
requestBody:
content:
application/json:
schema:
type: object
required:
- name
properties:
name:
type: string
description: The name of the campaign being created
subjects:
type: array
description: The name of the split test campaign being created
items:
type: string
fromNames:
type: array
description: The from names to be split tested on
items:
type: string
fromAddresses:
type: array
description: The emails of existing custom from addresses to be split tested on
items:
properties:
email:
type: string
description: The from email address
required:
- email
type: object
htmlContents:
type: array
description: The HTML contents of the campaign that lies between the opening <body> and the closing </body> only (the <body> tags themselves should not be used), to be split tested on
items:
type: string
plainTextContents:
type: array
description: The plain text contents of the campaign, to be split tested on
items:
type: string
replyAction:
type: string
description: The required action to be taken when a reply to the campaign is sent by the recipient
enum:
- Unset
- WebMailForward
- Webmail
- Delete
replyToAddress:
type: string
description: The email address that you would like replies to be forwarded to
examples:
Request Example:
value:
name: Split Test Campaign
subjects:
- My subject variation A
- My subject variation B
- My subject variation C
fromNames:
- My name variation A
- My name variation B
- My name variation C
fromAddresses:
- email: hello@my-domain.com
- email: hello@my-other-domain.com
- email: hello@my-experimental-domain.com
htmlContents:
- '
<!-- Easy Editor -->
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="ee_resizable ee_mobiletemplate" data-dmtmp="true">
<tbody>
<tr>
<td align="center" bgcolor="#ffffff" cellpadding="0" cellspacing="0">
<table width="600" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="eem_mainouterzone">
<tbody>
<tr>
<td bgcolor="#ffffff" class="ee_dropzone" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px;" align="left">
<table width="100%" cellpadding="0" cellspacing="0" style="width: 600px; background-color: rgb(255, 255, 255); table-layout: auto;" class="ee_element" bgcolor="#ffffff">
<tbody>
<tr>
<td align="left" style="padding: 0px; width: 600px;" class=""><div class="ee_editable"><font style="font-family: ''trebuchet ms'', verdana, arial, sans-serif; font-size: 13px;"><a href="http://$UNSUB$" style="color: black;"> Unsubscribe from this newsletter</a></font> </div></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>'
- '
<!-- Easy Editor -->
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="ee_resizable ee_mobiletemplate" data-dmtmp="true">
<tbody>
<tr>
<td align="center" bgcolor="#ffffff" cellpadding="0" cellspacing="0">
<table width="600" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="eem_mainouterzone">
<tbody>
<tr>
<td bgcolor="#ffffff" class="ee_dropzone" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px;" align="left">
<table width="100%" cellpadding="0" cellspacing="0" style="width: 600px; background-color: rgb(255, 255, 255); table-layout: auto;" class="ee_element" bgcolor="#ffffff">
<tbody>
<tr>
<td align="left" style="padding: 0px; width: 600px;" class=""><div class="ee_editable"><font style="font-family: ''trebuchet ms'', verdana, arial, sans-serif; font-size: 13px;"><a href="http://$UNSUB$" style="color: black;"> Don''t want to hear from us?</a></font> </div></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>'
- '
<!-- Easy Editor -->
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="ee_resizable ee_mobiletemplate" data-dmtmp="true">
<tbody>
<tr>
<td align="center" bgcolor="#ffffff" cellpadding="0" cellspacing="0">
<table width="600" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="eem_mainouterzone">
<tbody>
<tr>
<td bgcolor="#ffffff" class="ee_dropzone" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px;" align="left">
<table width="100%" cellpadding="0" cellspacing="0" style="width: 600px; background-color: rgb(255, 255, 255); table-layout: auto;" class="ee_element" bgcolor="#ffffff">
<tbody>
<tr>
<td align="left" style="padding: 0px; width: 600px;" class=""><div class="ee_editable"><font style="font-family: ''trebuchet ms'', verdana, arial, sans-serif; font-size: 13px;"><a href="http://$UNSUB$" style="color: black;"> Remove me from this list</a></font> </div></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>'
plainTextContents:
- '
---
Want to unsubscribe? $UNSUB$'
- '
---
Don''t want to hear from us? $UNSUB$'
- '
---
Remove me from this list $UNSUB$'
summary: Request Example
responses:
'200':
description: '200'
content:
application/json:
schema:
type: object
properties:
id:
type: integer
default: 0
examples:
- 1
name:
type: string
examples:
- Split Test Campaign
subjects:
type: array
items:
type: string
examples:
- My subject variation A
fromNames:
type: array
items:
type: string
examples:
- My name variation A
fromAddresses:
type: array
items:
type: object
properties:
id:
type: integer
default: 0
examples:
- 1
email:
type: string
examples:
- hello@my-domain.com
htmlContents:
type: array
items:
type: string
examples:
- '
<!-- Easy Editor -->
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="ee_resizable ee_mobiletemplate" data-dmtmp="true">
<tbody>
<tr>
<td align="center" bgcolor="#ffffff" cellpadding="0" cellspacing="0">
<table width="600" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="eem_mainouterzone">
<tbody>
<tr>
<td bgcolor="#ffffff" class="ee_dropzone" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px;" align="left">
<table width="100%" cellpadding="0" cellspacing="0" style="width: 600px; background-color: rgb(255, 255, 255); table-layout: auto;" class="ee_element" bgcolor="#ffffff">
<tbody>
<tr>
<td align="left" style="padding: 0px; width: 600px;" class=""><div class="ee_editable"><font style="font-family: ''trebuchet ms'', verdana, arial, sans-serif; font-size: 13px;"><a href="http://$UNSUB$" style="color: black;"> Unsubscribe from this newsletter</a></font> </div></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>'
plainTextContents:
type: array
items:
type: string
examples:
- '
---
Want to unsubscribe? $UNSUB$'
replyAction:
type: string
examples:
- Unset
replyToAddress:
type: string
examples:
- ''
status:
type: string
examples:
- Unsent
examples:
Result:
summary: Result
value:
id: 1
name: Split Test Campaign
subjects:
- My subject variation A
- My subject variation B
- My subject variation C
fromNames:
- My name variation A
- My name variation B
- My name variation C
fromAddresses:
- id: 1
email: hello@my-domain.com
- id: 2
email: hello@my-other-domain.com
- id: 3
email: hello@my-experimental-domain.com
htmlContents:
- '
<!-- Easy Editor -->
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="ee_resizable ee_mobiletemplate" data-dmtmp="true">
<tbody>
<tr>
<td align="center" bgcolor="#ffffff" cellpadding="0" cellspacing="0">
<table width="600" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="eem_mainouterzone">
<tbody>
<tr>
<td bgcolor="#ffffff" class="ee_dropzone" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px;" align="left">
<table width="100%" cellpadding="0" cellspacing="0" style="width: 600px; background-color: rgb(255, 255, 255); table-layout: auto;" class="ee_element" bgcolor="#ffffff">
<tbody>
<tr>
<td align="left" style="padding: 0px; width: 600px;" class=""><div class="ee_editable"><font style="font-family: ''trebuchet ms'', verdana, arial, sans-serif; font-size: 13px;"><a href="http://$UNSUB$" style="color: black;"> Unsubscribe from this newsletter</a></font> </div></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>'
- '
<!-- Easy Editor -->
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="ee_resizable ee_mobiletemplate" data-dmtmp="true">
<tbody>
<tr>
<td align="center" bgcolor="#ffffff" cellpadding="0" cellspacing="0">
<table width="600" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="eem_mainouterzone">
<tbody>
<tr>
<td bgcolor="#ffffff" class="ee_dropzone" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px;" align="left">
<table width="100%" cellpadding="0" cellspacing="0" style="width: 600px; background-color: rgb(255, 255, 255); table-layout: auto;" class="ee_element" bgcolor="#ffffff">
<tbody>
<tr>
<td align="left" style="padding: 0px; width: 600px;" class=""><div class="ee_editable"><font style="font-family: ''trebuchet ms'', verdana, arial, sans-serif; font-size: 13px;"><a href="http://$UNSUB$" style="color: black;"> Don''t want to hear from us?</a></font> </div></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>'
- '
<!-- Easy Editor -->
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="ee_resizable ee_mobiletemplate" data-dmtmp="true">
<tbody>
<tr>
<td align="center" bgcolor="#ffffff" cellpadding="0" cellspacing="0">
<table width="600" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="eem_mainouterzone">
<tbody>
<tr>
<td bgcolor="#ffffff" class="ee_dropzone" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px;" align="left">
<table width="100%" cellpadding="0" cellspacing="0" style="width: 600px; background-color: rgb(255, 255, 255); table-layout: auto;" class="ee_element" bgcolor="#ffffff">
<tbody>
<tr>
<td align="left" style="padding: 0px; width: 600px;" class=""><div class="ee_editable"><font style="font-family: ''trebuchet ms'', verdana, arial, sans-serif; font-size: 13px;"><a href="http://$UNSUB$" style="color: black;"> Remove me from this list</a></font> </div></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>'
plainTextContents:
- '
---
Want to unsubscribe? $UNSUB$'
- '
---
Don''t want to hear from us? $UNSUB$'
- '
---
Remove me from this list $UNSUB$'
replyAction: Unset
replyToAddress: ''
status: Unsent
/v2/campaigns/{id}:
parameters:
- in: header
name: x-ddg-integration-token
required: false
description: If you are a partner of Dotdigital and have a [verified integration](https://developer.dotdigital.com/docs/partner-integration-verification) then include your [integration tracking token](https://developer.dotdigital.co/docs/verified-integration-tracking) here.
schema:
type: string
pattern: /^(?:\{{0,1}(?:[0-9a-fA-F]){8}-(?:[0-9a-fA-F]){4}-(?:[0-9a-fA-F]){4}-(?:[0-9a-fA-F]){4}-(?:[0-9a-fA-F]){12}\}{0,1})$/
example: 5a96bc79-19a7-4544-973b-e2da0c9136f9
put:
summary: Update campaign
deprecated: false
description: Updates a given campaign
operationId: update-campaign
tags:
- Email Campaigns
parameters:
- name: id
in: path
description: The ID of the campaign to be updated
required: true
examples:
default:
value: 0
schema:
type: integer
format: int32
requestBody:
content:
application/json:
schema:
type: object
properties:
name:
type: string
description: The name of the campaign being created
subject:
type: string
description: The email subject line of the campaign
fromName:
type: string
description: The from name of the campaign
htmlContent:
type: string
description: The HTML content of the campaign that lies between the opening <body> and the closing </body> only (the <body> tags themselves should not be used)
plainTextContent:
type: string
description: The plain text content of the campaign
examples:
Request Example:
value:
name: New product promotion 2
subject: Check out our newest product!
fromName: Company name
htmlContent: '
<!-- Easy Editor -->
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="ee_resizable ee_mobiletemplate" data-dmtmp="true">
<tbody>
<tr>
<td align="center" bgcolor="#ffffff" cellpadding="0" cellspacing="0">
<table width="600" border="0" cellspacing="0" cellpadding="0" style="table-layout: auto;" class="eem_mainouterzone">
<tbody>
<tr>
<td bgcolor="#ffffff" class="ee_dropzone" style="padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px;" align="left">
<table width="100%" cellpadding="0" cellspacing="0" style="width: 600px; background-color: rgb(255, 255, 255); table-layout: auto;" class="ee_element" bgcolor="#ffffff">
<tbody>
<tr>
<td align="left" style="padding: 0px; width: 600px;" class=""><div class="ee_editable"><font style="font-family: ''trebuchet ms'', verdana, arial, sans-serif; font-size: 13px;"><a href="http://$UNSUB$" style="color: black;"> Unsubscribe from this newsletter</a></font> </div></td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>'
plainTextContent: '
---
Want to unsubscribe? $UNSUB$'
summary: Request Example
responses:
'200':
description: '200'
content:
# --- truncated at 32 KB (216 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/dotdigital/refs/heads/main/openapi/dotdigital-email-campaigns-api-openapi.yml