{
"type": "message.complained",
"webhook_id": "abe11757-2886-4b55-96f1-0e0afc95795a",
"timestamp": "2024-05-06T10:30:16.687031577Z",
"data": {
"account_id": "4cdd7bdd-294e-4762-892f-83d40abf5a87",
"event": "on_complained",
"from": "Example News <news@example.com>",
"recipient": "recipient@example.com",
"subject": "Our October news",
"message_id_header": "<message-id-12345@localhost>",
"id": "019a0c3e-7c3e-7b2a-9d4e-5f6a7b8c9d0e",
"is_bot": false,
"complaint": {
"feedback_type": "abuse",
"reporter": "yahoo"
},
"campaign_id": "8b0f4c2e-5d1a-4f6b-9c3e-2a7d1e9f0b44",
"list_id": "c3e1a9d2-7f4b-4e8a-b5c6-1d2e3f4a5b6c",
"segment_id": null
}
}Message Events
message.complained Webhook Event
The message.complained webhook fires when a mailbox provider reports an AhaSend campaign email as spam. The payload holds the feedback type and reporter.
WEBHOOK
message.complained
{
"type": "message.complained",
"webhook_id": "abe11757-2886-4b55-96f1-0e0afc95795a",
"timestamp": "2024-05-06T10:30:16.687031577Z",
"data": {
"account_id": "4cdd7bdd-294e-4762-892f-83d40abf5a87",
"event": "on_complained",
"from": "Example News <news@example.com>",
"recipient": "recipient@example.com",
"subject": "Our October news",
"message_id_header": "<message-id-12345@localhost>",
"id": "019a0c3e-7c3e-7b2a-9d4e-5f6a7b8c9d0e",
"is_bot": false,
"complaint": {
"feedback_type": "abuse",
"reporter": "yahoo"
},
"campaign_id": "8b0f4c2e-5d1a-4f6b-9c3e-2a7d1e9f0b44",
"list_id": "c3e1a9d2-7f4b-4e8a-b5c6-1d2e3f4a5b6c",
"segment_id": null
}
}AhaSend sends this event when the recipient’s mailbox provider reports your campaign email as spam through its feedback loop. This event is sent for campaign email only. A spam complaint about a transactional email suppresses the address and sends
suppression.created.
data.complaint.feedback_type is the feedback type of the report, abuse or fraud. data.complaint.reporter is the feedback loop that sent the report. AhaSend can add feedback loops at any time, so keep a fallback for a value you do not know. data.campaign_id, data.list_id and data.segment_id say which campaign sent the email and how it reached the recipient.
Repeats: AhaSend sends this event for every complaint report that it matches to the message, also when the recipient is already unsubscribed. Drop the repeats by type and data.id. The contact events of the same report are sent only when the report changes something, except for a campaign sent to a segment.
Setting: on_complained (Message Reported as Spam in the dashboard).
When it’s sent: When AhaSend receives a spam complaint report and matches it to the message.
Related Guides
- API authentication, Permission scopes, Webhook setup.
- Event reference, Webhook CLI, Local webhook testing.
- Signature verification, Retry policy, API errors.
- API rate limits, Contacts API, Suppression durations.
Body
application/json
The webhook ID (the same ID as returned by the Create Webhook API)
Response
Webhook received successfully

