Email campaign webhooks
Webhooks send your server what happens after an email campaign goes out: a recipient opens, clicks or unsubscribes, an address bounces. Your application receives these events as they come in and can update your CRM, feed a dashboard or remove an invalid address, without polling the API.
No API key is needed. All it takes is a URL that accepts a POST request, and ticking the events you care about.
This page covers email campaigns. SMS delivery receipts and replies have their own webhook, described in the SMS API documentation.
Enabling webhooks
The setting is in Account management > Webhooks Email.
- Turn on Enable Webhook.
- Enter the Url of your receiving page. It must be complete, protocol included:
https://www.your-site.com/webhooks/ediware. - Under Data to be sent, tick the events you want to receive.
- Click the green button at the bottom of the form. Its label is still in French in the English interface: Enregistrer.

Only events that occur after activation are sent: the history of your past campaigns is not.
Once the URL is saved, the Send a test webhook button sends a sample of each ticked event to your URL and displays your server’s response. Handy to check that your page answers before your next campaign goes out.
To pause notifications, turn off Enable Webhook and save. Your settings are kept.
Events sent
Each switch on the screen matches a value of the type_event field in the data you receive.
| Switch | type_event | What happened |
|---|---|---|
| Sendings | envoi | The email was sent to the recipient |
| Delivered | abouti | The recipient’s mail server accepted the email |
| Hard bounce | npai_hard | Permanent failure: address does not exist, invalid domain |
| Soft bounces | npai_soft | Temporary failure: mailbox full, server unavailable, one-off rejection |
| Openings | ouverture | The recipient opened the email |
| Clicks | clic | The recipient clicked a link |
| Unsubscriptions | desabo | The recipient unsubscribed |
| Complaints | plainte | The recipient reported the email as spam to their mailbox provider |
The type_event values are French and stay the same whatever the interface language.
On a large campaign, envoi and abouti events mean one line per recipient. Only tick them if your application really uses them: to track engagement, opens, clicks, unsubscribes and bounces are usually enough.
Data format
The platform sends a POST request with the Content-Type: application/json header. The body is an array of events: a single request often holds several, of different types.
[
{
"id": "1842207",
"fkey_user": "12345",
"email": "john.smith@example.com",
"fkey_ope": "902534",
"date_event": "2026-12-04 10:12:37",
"url": "",
"ip": "92.184.105.12",
"user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0 Safari/537.36",
"type_event": "ouverture",
"detail": null,
"date_sent": "2026-12-04 10:30:02"
},
{
"id": "1842215",
"fkey_user": "12345",
"email": "contact@example-company.com",
"fkey_ope": "902534",
"date_event": "2026-12-04 10:14:05",
"url": null,
"ip": null,
"user_agent": null,
"type_event": "npai_hard",
"detail": "bad-mailbox",
"date_sent": "2026-12-04 10:30:02"
}
]| Field | Content |
|---|---|
id | Unique event identifier. Keep it to discard duplicates |
fkey_user | Your account number |
email | The recipient’s address |
fkey_ope | Campaign number, the one shown in the campaign’s address in the interface (?id=902534) |
date_event | Date and time of the event, Paris time, formatted YYYY-MM-DD HH:MM:SS |
url | For a click: the address of the clicked link |
ip | For an open or a click: the recipient’s IP address |
user_agent | For an open or a click: the email client or browser used |
type_event | Event type, see the events table |
detail | Additional information depending on the event type, see below |
date_sent | Date and time the webhook was sent |
Fields that do not apply to the event are empty or null. Numbers are sent as strings: convert them if your code compares them with integers.
The detail field
For a click, detail is an object holding the recipient’s data in the campaign: nom (last name), prenom (first name) and the custom fields perso1 to perso24. You can link the click to a CRM record without going through the email address, provided you put your customer ID in one of these fields when importing.
{
"id": "1842230",
"email": "john.smith@example.com",
"fkey_ope": "902534",
"type_event": "clic",
"url": "https://www.your-site.com/winter-offer",
"detail": {
"nom": "Smith",
"prenom": "John",
"perso1": "CUS-004871",
"perso2": "London",
"perso3": ""
}
}The object also holds the same values under numeric keys ("0", "1", "2"…). Read the named keys, they are stable.
For a bounce (npai_hard, npai_soft), detail gives the rejection category when known, for example bad-mailbox for a mailbox that does not exist. For a delivered email, it holds the recipient server’s response, such as smtp;250 2.0.0 ... mail accepted for delivery.
When events arrive
Webhooks are not sent the moment the event happens. The platform groups events and sends them in batches, roughly every 10 minutes. Expect less than 20 minutes in most cases between an open and its arrival on your server.
A few rules to keep in mind when writing your handler:
- a batch holds at most 5,000 events. After a large send, events arrive in several successive requests;
- events in a batch are not sorted by date. If order matters to you, sort on
date_event; - each event is sent once, whether or not your server answers. There is no automatic retry on error;
- an event that could not be sent within 24 hours is no longer sent.
Monitoring and re-sending
The History tab, next to Settings, lists the last 100 deliveries: date, URL, HTTP status returned by your server and number of events in the batch.
The Details button shows the data sent and your server’s response. The Re-launch button sends the batch again as is: that is how you recover events lost while your server was down.
Writing the receiving page
Your page must answer fast. Store the data received, return a 200 status, and run the heavy processing (CRM update, calls to other services) later. A page that takes several seconds to answer slows down the delivery of all your events.
Plan for duplicates too. A batch re-launched from the history contains events you may already have received: keep the processed id values and ignore the ones you already know.
A minimal PHP example:
<?php
$events = json_decode(file_get_contents('php://input'), true);
if (!is_array($events)) {
http_response_code(400);
exit;
}
$pdo = new PDO('mysql:host=localhost;dbname=crm', 'user', 'password');
$insert = $pdo->prepare(
'INSERT IGNORE INTO webhook_events (id, email, campaign, type, date_event, payload)
VALUES (?, ?, ?, ?, ?, ?)'
);
foreach ($events as $event) {
$insert->execute([
$event['id'],
$event['email'],
$event['fkey_ope'],
$event['type_event'],
$event['date_event'],
json_encode($event),
]);
}
http_response_code(200);The primary key on id and the INSERT IGNORE discard duplicates. A separate script, run by a scheduled task, then processes the webhook_events table.
The receiving URL is not protected by the platform: anyone who knows it can post data to it. Choose an address that is hard to guess, for example with a token in the path (/webhooks/ediware/8f3a1c2e9b/), and use HTTPS.