Webhook events
Every event shares the same format. What changes from one to another is the value of type and the detail block that comes with data.email.
Request format
Each event is a POST request with a JSON body:
POST /webhooks/mailiqo HTTP/1.1
Host: your-server.com
Content-Type: application/json
User-Agent: Mailiqo-Webhooks/1
webhook-id: evt_5f1c2a9e8b7d4c3fa2b1c0d9e8f7a6b5
webhook-timestamp: 1767263349
webhook-signature: v1,K5oZfzN95Z9UVu1EsfQmfVNQhnkZ2pj9o9NDN/H/pI4={
"id": "evt_5f1c2a9e8b7d4c3fa2b1c0d9e8f7a6b5",
"type": "email.delivered",
"timestamp": 1767263347,
"data": {
"email": {
"id": "msg_8c2db7094df247c4b03f6f1d2a9e5c10",
"send_id": "snd_ecbc059748234c9c9cbb0a1b2c3d4e5f",
"recipient_email": "[email protected]",
"recipient_type": "to",
"channel": "api",
"sending_domain": "yourdomain.com"
}
}
}The body arrives on a single line, with no spaces; it is formatted here for reading. The webhook-id, webhook-timestamp and webhook-signature headers are used to verify the signature.
Common fields
| Field | Type | Description |
|---|---|---|
id | string | Event identifier. It is the same on every delivery attempt and matches the webhook-id header |
type | string | Event type |
timestamp | integer | When the fact happened, in Unix seconds (UTC). It is not the delivery time |
data.email | object | The email the event refers to |
The data.email object
| Field | Type | Description |
|---|---|---|
id | string | Identifier of this recipient's email (msg_...). It is the same as sent_to[].id in the send response and the one used by GET /email-message/{id} |
send_id | string | Identifier of the send request (snd_...), shared by all its recipients. It is the one used by GET /email-request/{id} |
recipient_email | string | Recipient address |
recipient_type | string | to, cc or bcc |
channel | string | How it was sent: api or smtp |
sending_domain | string | Sending domain |
Each recipient produces its own events: a send to three addresses results in three email.delivered, each with its own id.
email.delivered
The recipient's mail server accepted the message. It carries no detail block: data only contains email.
Being accepted by the server does not say which folder it ends up in: the recipient's mail provider decides that.
email.bounced
The destination server returned the message. The bounce block says why:
{
"id": "evt_1b9d6c4e7a2f4d8e9c3b5a7f0e1d2c3b",
"type": "email.bounced",
"timestamp": 1767263352,
"data": {
"email": {
"id": "msg_8c2db7094df247c4b03f6f1d2a9e5c10",
"send_id": "snd_ecbc059748234c9c9cbb0a1b2c3d4e5f",
"recipient_email": "[email protected]",
"recipient_type": "to",
"channel": "api",
"sending_domain": "yourdomain.com"
},
"bounce": {
"type": "hard",
"category": "general",
"diagnostic": "smtp; 550 5.1.1 user unknown"
}
}
}| Field | Type | Description |
|---|---|---|
bounce.type | string | hard (permanent), soft (temporary) or undetermined (could not be classified) |
bounce.category | string | Reason within the type. See the table below |
bounce.diagnostic | string or null | Response from the destination server. It is informational and its text is not stable: decide with type and category |
What to do with each bounce
type | category | What happened | What to do |
|---|---|---|---|
hard | general | The address does not exist, or the server rejects it permanently | Stop sending to that address and mark it as invalid |
hard | suppressed | The address is on a suppression list because of earlier bounces or complaints: no delivery was attempted | Do not send to it again. If you know it is valid again, open a support ticket |
soft | general | Temporary failure at the destination server | You can send again later. If it keeps happening for several days, treat the address as invalid |
soft | mailbox_full | The recipient's mailbox is full | Send again after a few days. If nothing changes, stop sending |
soft | message_too_large | The message is larger than the destination server accepts | Reduce its size, usually the attachments, and send again |
soft | content_rejected | The destination server rejected the content | Review the content before sending again |
soft | attachment_rejected | The destination server rejected an attachment, because of its type or size | Remove or change the attachment and send again |
undetermined | general | The cause could not be determined | Check diagnostic. If it happens again with the same address, treat it as hard |
A soft bounce arrives once the delivery retries have run out: Mailiqo does not try again on its own. If you want to resend the message, make a new send.
New categories can be added. If you receive one you do not know, decide with type.
Notices that do not produce an event
A temporary notice that arrives when the message is already recorded as delivered — an out-of-office auto-reply, for example — does not produce email.bounced.
email.complained
The recipient marked the message as spam and their mail provider reported it. The rest of the event is the same; inside data comes the complaint block:
"complaint": {
"feedback_type": "abuse"
}| Field | Type | Description |
|---|---|---|
complaint.feedback_type | string or null | Kind of complaint reported by the recipient's provider: abuse, fraud, virus, not-spam, auth-failure or other. Many providers do not report it |
What to do: stop sending to that address. Complaints damage the reputation of your sending domain.
email.rejected
The message was discarded before being sent. It never left for the recipient, and sending it again unchanged will give the same result. Inside data comes the rejection block:
"rejection": {
"reason": "invalid_recipient",
"message": "The recipient address does not exist or cannot receive email."
}reason | What happened | What to do |
|---|---|---|
invalid_recipient | Recipient validation discarded the address | Fix the address or stop sending to it |
spam_content | The content was classified as spam | Review the content before sending again |
sending_policy | Mailiqo blocked the send under its sending policy: the risk of the message, or the reputation of the account or the domain | Check the domain status in the panel or open a support ticket |
provider_rejected | The sending service rejected the message, for example because it contained a virus | Review the content and the attachments |
rejection.message is a text with the detail, or null. It is informational and can change: decide with reason.
Recipients the API discards when it receives the request — those in rejected_recipients — do not produce an event: they already come back with their reason in the POST /send response.
email.failed
The message could not be sent because of a technical problem, and no further attempt will be made. Inside data comes the failure block:
"failure": {
"reason": "provider_error",
"message": "The email could not be sent after several temporary delivery problems."
}reason | What happened | What to do |
|---|---|---|
provider_error | Sending failed several times because of temporary problems and the retries ran out | You can send it again |
template_error | The content of the message could not be generated | Review the template and its variables before sending again |
internal_error | Internal Mailiqo error | Send it again. If it keeps happening, open a support ticket |
failure.message is a text with the detail, or null. Decide with reason.
endpoint.ping
It does not describe an email: it is used to check that your server receives and verifies the requests. It is only sent when you click Send ping in the panel, whatever the endpoint's event list is.
{
"id": "evt_0c9d4e1f7a2b4c6d8e0f1a2b3c4d5e6f",
"type": "endpoint.ping",
"timestamp": 1767263400,
"data": {
"endpoint": {
"sending_domain": "yourdomain.com",
"events": ["email.delivered", "email.bounced"]
}
}
}It has no data.email. It is signed like any other event. It is not retried and does not appear in the delivery log: the panel shows right away the status your server answered with, how long it took and the first bytes of the response. A successful ping also clears the endpoint's Failing since mark. Answer 2xx and do nothing else.
How events map to the email status
Each event is emitted when the email moves to one of these status values in GET /email-message/{id}:
| Event | status |
|---|---|
email.delivered | delivered |
email.bounced | bounced |
email.complained | complained |
email.rejected | rejected |
email.failed | failed or error |
The other statuses (processing, sent, opened, clicked and the rest) do not produce an event.
