ingest_newsletter_events
Take events from the newsletter provider (unsubscribed, subscribed, delivered, opened, clicked, bounced) and apply them. AN UNSUBSCRIBE BECOMES A WITHDRAWAL and from then on blocks every send path in CallPilotAI, because the send gate reads the same table. A spam complaint counts as an unsubscribe. A subscribe does NOT lift an existing withdrawal — the stricter side always wins, even when the subscribe is newer. A bounce does not block: an undeliverable address is a technical finding, not a person's objection. Events whose email cannot be found are reported, not guessed. The same tool serves ANY external preference source — pass purpose (e.g. 'spenden' for a fundraising system) and the withdrawal is recorded for that purpose. A consent is always for ONE purpose, so the purpose has to travel with the event.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"events": "<events>"
},
"name": "ingest_newsletter_events"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| events | Yes | Provider payloads. Each needs an event/type and an email somewhere. | |
| source | No | Which provider — appears in the history entry. | |
| purpose | No | Which processing purpose these preferences are about. Default 'newsletter'. A fundraising system's objection belongs under its own purpose (e.g. 'spenden') — a withdrawal for donations is not a withdrawal for invoices. |