Viewing campaigns
These methods read campaigns and their results. They change nothing.
They are all called with POST, with a JSON body that contains your api_key. Parameter tables do not repeat it. See the common rules.
campaign_list or campaigns_stats?
Both methods list campaigns, but not with the same scope:
campaign_list | campaigns_stats | |
|---|---|---|
| Campaigns | all, whatever their status | sent only |
| Period | full history | the last month |
| Accounts | the account only | the account and its direct sub-accounts |
| Statistics | no | yes (opens, clicks, bounces, unsubscribes) |
| Pagination | yes (limit, offset) | no |
| IP | declared IP required | any IP |
campaign_list is for managing your campaigns: finding a draft, following a status. campaigns_stats is for a dashboard of recent sends, especially for a reseller and its sub-accounts.
List campaigns
Access point: https://www.mdworks.fr/api_http/campaign_list
This method returns the account’s email campaigns, from the most recent to the oldest.
Parameters:
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
limit | integer | no | 50 | number of campaigns returned, from 1 to 500 |
offset | integer | no | 0 | number of campaigns to skip (pagination) |
status | text | no | all | draft, scheduled, partially_sent, sent or automatic (see statuses) |
Example of posted data:
{
"api_key": "YOUR_API_KEY",
"status": "draft",
"limit": 50
}Response:
{
"total": 87,
"limit": 50,
"offset": 0,
"campaigns": [
{
"id": 123456,
"reference": "November newsletter",
"subject": "What's new in November",
"status": "draft",
"created_at": "2026-11-28T00:38:05+01:00",
"sent_at": null,
"scheduled_at": null,
"recipients": 0
}
]
}| Field | Description |
|---|---|
total | number of campaigns matching the filter |
reference | internal name of the campaign, the one shown in the interface’s campaign list |
subject | subject of the message |
status | campaign status |
created_at, sent_at, scheduled_at | ISO 8601 dates, Paris time. sent_at is only filled for sent, scheduled_at only for scheduled |
recipients | number of recipients loaded |
To paginate, increase offset by the value of limit as long as offset stays below total. A/B test variants are excluded, as in the interface.
Errors:
| Message | Cause |
|---|---|
Error limit must be between 1 and 500 | |
Error offset must be 0 or more | |
Error status must be draft, scheduled, partially_sent, sent or automatic |
Retrieve a campaign’s details
Access point: https://www.mdworks.fr/api_http/campaign_get
This method returns the settings of a campaign. It is also used to read a campaign back after a campaign_update.
Only the account that created the campaign can access it: a parent account’s key does not see its sub-accounts’ campaigns.
Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
campaign_id | integer | yes | ID of the campaign |
Example of posted data:
{
"api_key": "YOUR_API_KEY",
"campaign_id": 123456
}Response:
{
"id": 123456,
"reference": "November newsletter",
"subject": "What's new in November",
"from_name": "Example Team",
"from_email": "contact@example.com",
"reply_to": "contact@example.com",
"recipient_name": "Dear customer",
"preheader": "Three new things to discover",
"status": "draft",
"created_at": "2026-11-28T00:38:05+01:00",
"sent_at": null,
"scheduled_at": null,
"recipients": 0,
"unsubscribe_link": 1,
"bounce_management": 0,
"language": "UK",
"folder_id": 0,
"charset": "iso-8859-1"
}Fields shared with campaign_list have the same meaning. The others:
| Field | Description |
|---|---|
from_name, from_email | sender name and email. With bounce_management set to 1, from_email is the full address, return domain included |
reply_to | reply-to email, empty if none |
recipient_name | name displayed for the recipient |
preheader | text shown below the subject by some mail clients, empty if none |
unsubscribe_link | 1 if the unsubscribe link is inserted |
bounce_management | 1 if automatic bounce handling is active (see campaign_create) |
language | footer language: DE, UK, AR, ES, FR, IT, PT, NL, PO, CZ or HU, as for the campaign_create parameter. Can be null |
folder_id | filing folder, 0 if none |
charset | character set of the campaign |
Errors:
| Message | Cause |
|---|---|
Error campaign_id is missing or is not numeric | |
Error this user don't have access to campaign_id | campaign does not exist or belongs to another account |
Statistics of sent campaigns
Access point: https://www.mdworks.fr/api_http_open/campaigns_stats
This method returns the campaigns sent over the last month by an account and its direct sub-accounts, with the statistics obtained. These figures are cached for up to one hour.
It is not restricted by IP, because no personal data is transmitted.
Parameters: none apart from api_key.
Example of posted data:
{"api_key": "YOUR_API_KEY"}Response: an array of objects.
[
{
"id": "688646",
"user_id": "1474",
"user": "account1",
"reference": "My test campaign",
"subject": "TEST SEND 19:20",
"sent": "2021-02-10 19:26:01.000000",
"volume": "1300",
"open_unique": "260",
"open": "340",
"click_unique": "25",
"click": 50,
"hard_bounce": 10,
"soft_bounce": 4,
"unsubscribe": 2
},
{
"id": "688644",
"user_id": "1478",
"user": "account2",
"reference": "My second test campaign",
"subject": "TEST SEND",
"sent": "2021-02-10 19:05:15.000000",
"volume": "4151",
"open_unique": "1230",
"open": "1340",
"click_unique": "47",
"click": 75,
"hard_bounce": 5,
"soft_bounce": 0,
"unsubscribe": 30
}
]| Field | Description |
|---|---|
id | ID of the campaign |
user_id, user | ID and login of the account that sent the campaign |
reference | internal name of the campaign |
subject | subject of the message |
sent | date and time of sending |
volume | number of emails sent |
open_unique, open | unique and total opens |
click_unique, click | unique and total clicks |
hard_bounce, soft_bounce | permanent and temporary bounces |
unsubscribe | unsubscribes |
Per-recipient sending results
Access point: https://www.mdworks.fr/api_http/campaign_results
This method returns the recipients of a sent campaign, with the sending status of each one. It is restricted to declared IPs.
30 days after sending, the sending history is archived and this information is no longer available.
Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
campaign_id | integer | yes | ID of the campaign |
Example of posted data:
{
"api_key": "YOUR_API_KEY",
"campaign_id": "234433"
}Response: an array of objects.
[
{
"email": "test@test.com",
"status": "clicked",
"bounceCat": "",
"dsnMta": "mx3.ovh.net (91.121.56.64)",
"dsnDiag": "smtp;250 2.0.0 Ok: queued as 4Stsl60YVKz1xxl",
"clicks": ["https://www.example.com/news"],
"timeLogged": "2023-10-22 15:01:18"
},
{
"email": "test3@test5.com",
"status": "hard_bounce",
"bounceCat": "bad-domain",
"dsnMta": "",
"dsnDiag": "bad destination system: no such domain",
"clicks": [],
"timeLogged": "2023-10-22 15:01:21"
}
]| Field | Description |
|---|---|
email | recipient address. For a masked (encrypted) address, its MD5 hash is returned |
status | sending status, see below |
bounceCat | bounce category, if rejected |
dsnMta | information about the recipient’s mail server |
dsnDiag | raw response from the recipient’s mail server |
clicks | list of clicked URLs, if any |
timeLogged | sending timestamp, if available |
Possible values for status:
status | Meaning |
|---|---|
empty | no information |
opened | email opened |
clicked | link clicked in the email (it can therefore be considered opened) |
unsub | unsubscribed |
soft_bounce | email temporarily rejected |
hard_bounce | undeliverable email address |
Errors:
| Message | Cause |
|---|---|
Error campaign_id is missing or is not numeric | |
Error this user don't have access to campaign_id | campaign does not exist or belongs to another account |
This campaign is in draft mode | the campaign has not been sent yet |
This campaign is archived | the send is more than 30 days old |