Reporting Webhooks send real-time message activity events (e.g. sends, opens, clicks) as JSON in an HTTP POST. They’re useful in many cases, including analyzing message activity outside of Customer.io.
Log in and go to Data & Integrations > Integrations.
Find and select Reporting Webhooks.
Click Add Reporting Webhook.
Enter the Webhook Endpoint URL where you want to receive events. While the endpoint URL can be either HTTP or HTTPs, we recommend HTTPS to protect customer information.
Select the events you want to receive.
(Optional) Select the Send Frequency and Body Content options.
Send Frequency: This determines whether you receive events the first time they happen or every time they happen.
Body Content: Enable this to include message body content (and email headers) in all of the “Sent” events we send to you.
Choose Save and Enable Webhook at the bottom right of the page.
(Optional) Allowlist our IP addresses
If you have firewalls or rules in place that only allow connections from specific IPs, add Customer.io IP addresses to your allowlist so your systems can receive connections from us.
US Region
EU Region
35.188.196.183
34.76.143.229
104.198.177.219
34.78.91.47
104.154.232.87
34.77.94.252
130.211.229.195
35.187.188.242
104.198.221.24
34.78.122.90
104.197.27.15
35.195.137.235
35.194.9.154
130.211.108.156
104.154.144.51
104.199.50.18
104.197.210.12
34.78.44.80
35.225.6.73
35.205.31.154
Disabling webhooks
If you want to stop sending webhook events, you can disable the webhook.
Go to Data & Integrations > Integrations.
Go to Reporting Webhooks.
Select your webhook and click Disable.
You can also edit your webhook, change the state to disabled, and click Save.
Test a webhook
To inspect Webhook Events before pointing them at your own servers, use a service like webhook.site.
Warning
Enabling a webhook endpoint can cause you to send sensitive data to an external recipient. We recommend creating a test/sandbox workspace to test your webhooks so that you don’t inadvertently leak sensitive data to a potentially unsecured endpoint.
To send a test event, press Send Test while editing your Webhook Endpoint.
Events
The following events are available via webhook:
To only receive specific events, refine your selections within the nested list:
If you have a specific request for an event not listed here that you would like to be notified of, please contact us.
Webhook attributes
Attribute
Description
action_id
If the delivery was created as part of a Campaign or API Triggered Broadcast workflow, this is the ID for the unique workflow item that caused the delivery to be created. It can be used to retrieve full message details, including content, via the Campaign endpoint of our API.
broadcast_id
If applicable, the ID of the API Triggered Broadcast that generated the message. It can be used to retrieve message details, including the actions in your broadcast, via the Braodcast endpoint of our API.
campaign_id
If applicable, the ID of the Event-triggered, Segment-triggered, or Date-triggered Campaign that generated the message.
content
The body content of a sent message; if a message is an email, body content also contains headers. This can be useful if you want to display message content in your app. You must opt in to receiving content.
content_id
If the message was part of a newsletter split test, this is the ID of the split test variation.
customer_id
The ID of the person the webhook event represents. In a workspace supporting both email and id as identifiers, this value can be null. The value is empty if the person has been deleted. This field is generally considered deprecated. You should ignore this value and rely on the identifiers object.
identifiers
Contains identifiers for the person the webhook event is associated with. The object is empty if a person was deleted. If your workspace supports both email and ID as identifiers, this object contains id, email, and cio_id, and both id and email can be null. If your workspace only supports ID, this object only contains id.
delivery_id
The unique ID of the delivery record associated with the message.
device_id
Only on push-related events, the ID of the associated mobile device.
device_platform
Only on push-related events, the platform of the associated mobile device.
email_address
Only on customer_subscribed and customer_unsubscribed events, this is the email address of the person.
event_id
The unique ID of the reporting webhook event being sent. This can be useful for deduplicating purposes.
event_type
The type of event sent (e.g. email_sent, sms_drafted).
href
Only on “clicked” events, the fully rendered URL of the link that was clicked.
journey_id
The ID for the path a person went through in a Campaign or API Triggered Broadcast workflow. In our Data Warehouse Sync, this is referred to as subject_id.
link_id
Only on “clicked” events, the ID of the tracked link that was clicked.
newsletter_id
If applicable, the ID of the Newsletter that generated the message. It can be used to retrieve full message details via the Newsletters endpoint of our API.
recipient
The address of the message recipient. This could be an email address, a phone number, a mobile device ID, a Webhook URL, or a Slack username or channel.
subject
For email events, this is the subject of the email.
failure_message
If applicable, the reason a message failed to send.
timestamp
The timestamp at which the event being reported took place.
transactional_message_id
If a message is transactional, this is the unique identifier of the transactional message “template” that you sent (and referenced in the transactional message payload). If you send transactional messages without referencing transactional_message_id (by passing body, subject, and from values at send time), this value is 1.
tracked_response
Only available for in-app message “clicked” events, the tracked response value if Track Clicks is enabled for the in-app message action/component that a person clicked/tapped.
trigger_event_id
The id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
The identifiers object
Webhook payloads include an identifiers object. This object contains the unique identifiers for the person your event represents.
The items that the identifiers object can contain are defined by your workspace settings. If your workspace supports both email and id as identifiers, the identifiers block contains both (though either can be null if not set) and a cio_id—a unique, immutable identifier set by Customer.io to identify people canonically across changes to their other identifiers.
If your workspace uses ID as its only identifier, the identifiers object only contains the id.
Customer.io Webhooks are HTTP POST requests encoded in JSON. The requests have a User Agent header containing “Customer.io Web Hooks x.x” where “x.x” is the version number.
The JSON body contains a general top-level section included in all webhook requests, as well as a “data” attribute, which contains data specific to the type of event.
Below is an example of an HTTP request for an email-related event:
We have a 4 second timeout for calls to your webhook endpoint. If we don’t get a successful (2xx) response during those 4 seconds, we retry the webhook over a period of seven days with an exponential backoff. We backlog subsequent webhook calls and won’t continue processing them until the timed-out webhook call returns a successful response or the seven day retry period expires.
If your webhook server responds with any of the following status codes, we’ll wait for one hour before we retry the failed call. As with timeouts, we use the same exponential backoff for retries and we’ll backlog subsequent webhook calls until the failed call returns a successful response or the seven day retry period expires.
Error responses: EOF, server misbehaving, connect: connection refused, read: connection reset by peer, tls: failed to verify certificate: x509:
If you have issues with your webhook server and you want to temporarily block our servers, you can look up the current set of IP addresses we use via this API endpoint.
Securely verify requests
For security purposes, webhooks are delivered with an X-CIO-Signature header. This signature is generated by combining your webhook signing key with the body of webhook request using a standard HMAC-SHA256 hash.
To validate a signed request you’ll first need to retrieve the X-CIO-Timestamp header sent with the webhook request and the body of the request. Combine the version number, timestamp, and body—delimited by colons—to form a string like v0:<timestamp>:<body> (the version number is always v0). Using HMAC SHA256, hash the string using your webhook signing secret as the hash key. Compare this value to the value of the X-CIO-Signature header sent with the request to confirm that the request originated with Customer.io.
Important note:
Always use the request’s raw body when constructing the hash. Do not use any transformations such as JSON.stringify() (Node.js) or json.dumps() (Python) as there are subtle differences between parsing libraries.
Can webhooks contain the message body? Yes! We can send the message body for all channels, but you must opt in to this option during setup.
How can I secure webhooks? It’s possible to add basic authentication in the Webhook Endpoint URL field (e.g. http://username:password@example.com).
How do you identify each message that is going out? Each message sent from Customer.io has a delivery_id unique identifier that is also part of the default unsubscribe link:
https://track.customer.io/unsubscribe/MjYyMTI6Fs_YAmQAAnMAFeEaAU2YoV7tFRoYVh6HYAFzOjIyOTkwMQA=
To view a particular message in the UI, select Deliveries & Drafts from the left panel, click under the “Action” column for any message in the list, then replace the end of the URL in your browser with the delivery_id you’re interested in. For example:
The delivery_id is also displayed under the Metadata details in the right-hand column of the page.
Can I specify which campaign(s) get forwarded to an external webhook? No. If you need to monitor only a specific campaign, however, it’s possible to handle the logic on your end to filter out unwanted webhook events based on campaign_id.
Can I get a webhook when a customer gets added to a segment? No. But if you want to pull a list of people in a given segment, you can do so using the /segments/:id/membership endpoint of our API. Alternatively, you could create a segment-triggered campaign based on the segment you’re interested in, set the email inside to “Queue Draft” and then monitor the email_drafted events for that campaign_id.
Do you send an event for each click performed by a user? By default, only the first click event is sent. If you wish to have each click recorded, you can set the Send Frequency on your Webhook Endpoint accordingly:
Can Reporting Webhooks be rate limited? By default, we only send one event per action (sent, opened, clicked, etc.) to limit the output. No further rate limiting is available.
Is it possible to host a webhook endpoint in Customer.io? No. For incoming data, you’ll need to use our REST API or our Segment integration.
Send third-party delivery metrics to Customer.io
If you use outgoing webhooks to trigger messages from a third-party provider that is not natively integrated with Customer.io, you can send incoming calls to our Track metrics API to capture metrics in Customer.io. This allows you to see delivery metrics for all of your messages in one place.
The following steps assume you already have at least one campaign that uses a Send and Receive Data webhook action to send messages via a third party’s API. To send delivery metrics back to Customer.io:
Send the reporting webhook to a URL from your third-party service provider. The third-party provider can reference the X-CIO-Delivery-ID in the header of the message to uniquely identify that message.
From the third-party provider, you’ll send updates back via our Track API including delivery metrics (“delivered”, “bounced”, etc.).
You can view the metrics anywhere you can see them within your Customer.io account, such as Campaign Metrics, as well as data-out integrations. Note that the metrics will show as Webhook messages, since that was the type of delivery from your campaign.
Webhook event examples
We’ve moved webhook examples, including details about the schema for each individual webhook event, to our API documentation.
Customer event examples
{"data":{"customer_id":"0200102","identifiers":{"id":"0200102",},"email_address":"test@example.com"},"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"customer","metric":"subscribed","timestamp":1585250199}
{"data":{"customer_id":"0200102","identifiers":{"id":"0200102",},"email_address":"test@example.com"},"event_id":"01E4C4C6P79C12J5A6KPE6XNFD",//the id of the reporting webhook instance
"object_type":"customer","metric":"unsubscribed","timestamp":1585250179}
{"metric":"cio_subscription_preferences_changed","event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"delivery_type":"email","timestamp":1613063089,"data":{"content":"{\"topics\":{\"topic_1\":true}}","customer_id":"42","email_address":"test@example.com","identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"},"trigger_id":1,"delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","action_id":96,"broadcast_id":2,"journey_id":"01GW20GXAAXBKZD8J96M8FNV3R","parent_action_id":1}}
Email event examples
{"data":{"action_id":36,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgABcRhIBqSp7kiPekGBIeVh","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4C4G1S0AMNG0XVF2M7RPH5S",//the id of the reporting webhook instance
"object_type":"email","metric":"drafted","timestamp":1585250305}
{"data":{"action_id":36,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgABcRhIBqSp7kiPekGBIeVh","failure_message":"from address can't be blank","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4C4HDQ7GH7M19ZKS39BDB73",//the id of the reporting webhook instance
"object_type":"email","metric":"attempted","timestamp":1585250350}
{"data":{"action_id":36,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgABcRhIBqSp7kiPekGBIeVh","recipient":"test@example.com","subject":"hello","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4C8AY5K21N2QNRBD9YXJ13Z",//the id of the reporting webhook instance
"object_type":"email","metric":"sent","timestamp":1585254331}
{"data":{"action_id":12042,"campaign_id":1424,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"SA13dk35ja7s8d9kja3s2dASdasd==","recipient":"test@example.com","subject":"Thanks for joining!","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01ASDG7S9P6MAZPTJ78JND9GDC",//the id of the reporting webhook instance
"object_type":"email","metric":"delivered","timestamp":1234567890}
{"data":{"action_id":36,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgABcRhIBqSp7kiPekGBIeVh","recipient":"test@example.com","subject":"hello","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4C8BES586H0A5PFK1ARB9JW",//the id of the reporting webhook instance
"object_type":"email","metric":"opened","timestamp":1585254348}
{"data":{"action_id":36,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgABcRhIBqSp7kiPekGBIeVh","href":"http://google.com","link_id":1,"recipient":"test@example.com","subject":"hello","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4C8BES5XT87ZWRJFTB35YJ3",//the id of the reporting webhook instance
"object_type":"email","metric":"clicked","timestamp":1585254348}
{"data":{"action_id":12042,"campaign_id":1424,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"SA13dk35ja7s8d9kja3s2dASdasd==","recipient":"test@example.com","subject":"Thanks for joining!","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01ASDG7S9P6MYWPTJ78JND9GDC",//the id of the reporting webhook instance
"object_type":"email","metric":"converted","timestamp":1234567890}
{"data":{"action_id":37,"campaign_id":6,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RAECAAFxEqBRJ6UXtUdDSeFe_L8=","recipient":"test@example.com","subject":"hello","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4S9V7WSQK80RJZC6ATRQX8B",//the id of the reporting webhook instance
"object_type":"email","metric":"unsubscribed","timestamp":1585692122}
{"data":{"content_id":1146,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RMehBAAAAXE7r_ONUGXly9DBGkpq1JS31=","failure_message":"550 5.5.0 Requested action not taken: mailbox unavailable","newsletter_id":736,"recipient":"test@example.com","subject":"Thanks for joining!","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"12ASDG7S9P6MAZPTJ78DAND9GDC",//the id of the reporting webhook instance
"object_type":"email","metric":"bounced","timestamp":1234567890}
{"data":{"content_id":1146,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RMehBAAasdAAXE7r_ONUGXly9DBGkpq1JS31=","failure_message":"Not delivering to previously bounced address","newsletter_id":736,"recipient":"test@example.com","subject":"Thanks for joining!","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"31ASDG7S9P6MAZPTJ78DAND9GDC",//the id of the reporting webhook instance
"object_type":"email","metric":"dropped","timestamp":1234567890}
{"data":{"action_id":73,"campaign_id":52,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RObuBAXE4xnjV0vtJso_6xdRAas135","recipient":"test@example.com","subject":"Book now!","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"31ASDG7SU6HSJ78DAND9GDC",//the id of the reporting webhook instance
"object_type":"email","metric":"spammed","timestamp":1234567890}
{"data":{"action_id":73,"campaign_id":52,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"EFBAXE4xnjV0vtJso_6xdRAas135","failure_message":"Customer is unsubscribed","recipient":"test@example.com","subject":"Book for vacation now!","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"31ASDG7SU6JN78DAND9GDC",//the id of the reporting webhook instance
"object_type":"email","metric":"failed","timestamp":1234567890}
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"email","timestamp":1613063089,"metric":"undeliverable","data":{"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","action_id":96,"campaign_id":2,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"},"subject":"string","recipient":"test@example.com","failure_message":"Something went wrong!","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
}}
Push notification event examples
{"data":{"action_id":37,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgUBcRhIBqSfeiIwdIYJKxTY","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4C4G1S0HZ7C4220T6QNY8JX",//the id of the reporting webhook instance
"object_type":"push","metric":"drafted","timestamp":1585250305}
{"data":{"action_id":38,"campaign_id":6,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RAEABQFxN56fWzydfV4_EGvfobI=","failure_message":"NoDevicesSynced","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4VSX8SZ0T9AQMH4Q16NRB89",//the id of the reporting webhook instance
"object_type":"push","metric":"attempted","timestamp":1585776075}
A person can have multiple devices. When we send a push, we can try to send it to more than one device—but that doesn’t mean that each device will receive the message. If we can’t send a message to a device in the recipients array, we’ll include a failure_message for it.
{"data":{"action_id":37,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgUBcRhIBqSfeiIwdIYJKxTY","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"recipients":[{"device_id":"eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof","device_platform":"android","failure_message":"FCM_INVALID_TOKEN"}]},"event_id":"01E4C4HDQ7P1X9KTKF0ZX7PWHE",//the id of the reporting webhook instance
"object_type":"push","metric":"sent","timestamp":1585250350}
{"data":{"action_id":37,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgUBcRhIBqSfeiIwdIYJKxTY","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"recipients":[{"device_id":"eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof","device_platform":"android"}]},"event_id":"01E4C4HDQ7P1X9KTKF0ZX7PWHE",//the id of the reporting webhook instance
"object_type":"push","metric":"delivered","timestamp":1585250350}
Customer.io cannot track opened events for a push notification unless:
{"data":{"action_id":37,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgUBcRhIBqSfeiIwdIYJKxTY","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"recipients":[{"device_id":"eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof","device_platform":"android"}]},"event_id":"01E4C4V2B3FW52RKEKP4QF2P74",//the id of the reporting webhook instance
"object_type":"push","metric":"opened","timestamp":1585250665}
{"data":{"action_id":37,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgUBcRhIBqSfeiIwdIYJKxTY","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"href":"ciosas://product/2","link_id":1,"recipients":[{"device_id":"eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof","device_platform":"android"}]},"event_id":"01E4V2SBHYK4TNTG8WKMP39G9R",//the id of the reporting webhook instance
"object_type":"push","metric":"clicked","timestamp":1585751829}
{"data":{"action_id":37,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgUBcRiSO2rkbaiQ-5luSWXK","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"recipients":[{"device_id":"eeC2XC_NVPo:APA91bEYRSgmu-dAZcOWi7RzKBbT9gdY3WJACOpLQEMAmAOsChJMAZWirvSlSF3EuHxb7qdwlYeOyCWtbsnR14Vyx5nwBmg5J3SyPxfNn-ey1tNgXIj5UOq8IBk2VwzMApk-xzD4JJof","device_platform":"android"}]},"event_id":"01E4XWX0NB4DH73NWDRTT71NMT",//the id of the reporting webhook instance
"object_type":"push","metric":"converted","timestamp":1585846320}
{"data":{"action_id":38,"campaign_id":6,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RAEABQFxN55vrab8yVNNVNI2Hxc=","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"recipients":[{"device_id":"my_android_device_id","device_platform":"android","failure_message":"FCM_INVALID_TOKEN"}]},"event_id":"01E4VSWX38K3R96QJ3B9N37KJR",//the id of the reporting webhook instance
"object_type":"push","metric":"bounced","timestamp":1585776063}
{"data":{"action_id":40,"campaign_id":7,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RAECBQFxN6HHbPKYTzCT4XAS20Y=","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"recipients":[{"device_id":"my_android_device_id","device_platform":"android","failure_message":"FCM_INVALID_TOKEN"}]},"event_id":"01E4VT612DR9BX6J1HXCBAYA1N",//the id of the reporting webhook instance
"object_type":"push","metric":"dropped","timestamp":1585776361}
{"data":{"action_id":38,"campaign_id":6,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RAECAQFxNeUBx6LqfjqrN1j-BJc=","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"failure_message":"Variable 'customer.test' is missing"},"event_id":"01E4VSWX38K3R96QJ3B9N37KJR",//the id of the reporting webhook instance
"object_type":"push","metric":"failed","timestamp":1585747134}
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"push","timestamp":1613063089,"metric":"undeliverable","data":{"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","action_id":96,"broadcast_id":2,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"},"failure_message":"Something went wrong!"}}
In-App message event examples
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"in-app","timestamp":1613063089,"metric":"drafted","data":{"trigger_id":1,"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","action_id":96,"broadcast_id":2,"journey_id":"01GW20GXAAXBKZD8J96M8FNV3R","parent_action_id":1,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"}}}
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"in-app","timestamp":1613063089,"metric":"attempted","data":{"trigger_id":1,"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","action_id":96,"broadcast_id":2,"journey_id":"01GW20GXAAXBKZD8J96M8FNV3R","parent_action_id":1,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"},"failure_message":"Something went wrong!"}}
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"in-app","timestamp":1613063089,"metric":"sent","data":{"trigger_id":1,"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","action_id":96,"broadcast_id":2,"journey_id":"01GW20GXAAXBKZD8J96M8FNV3R","parent_action_id":1,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"},"content":"string","recipient":"test@example.com"}}
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"in-app","timestamp":1613063089,"metric":"opened","data":{"trigger_id":1,"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","action_id":96,"broadcast_id":2,"journey_id":"01GW20GXAAXBKZD8J96M8FNV3R","parent_action_id":1,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"}}}
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"in-app","timestamp":1613063089,"metric":"clicked","data":{"trigger_id":1,"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","action_id":96,"broadcast_id":2,"journey_id":"01GW20GXAAXBKZD8J96M8FNV3R","parent_action_id":1,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"},"recipient":"test@example.com","href":"https://www.customer.io","link_id":1,"tracked_response":"Response One"}}
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"in-app","timestamp":1613063089,"metric":"converted","data":{"trigger_id":1,"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","action_id":96,"broadcast_id":2,"journey_id":"01GW20GXAAXBKZD8J96M8FNV3R","parent_action_id":1,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"},"recipient":"test@example.com"}}
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"in-app","timestamp":1613063089,"metric":"failed","data":{"trigger_id":1,"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","action_id":96,"broadcast_id":2,"journey_id":"01GW20GXAAXBKZD8J96M8FNV3R","parent_action_id":1,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"},"failure_message":"Something went wrong!"}}
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"in-app","timestamp":1613063089,"metric":"undeliverable","data":{"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","action_id":96,"broadcast_id":2,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"},"failure_message":"Something went wrong!"}}
SMS event examples
{"data":{"action_id":38,"broadcast_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgIBcRhIBqSZNqzgZVFoivwW"},"event_id":"01E4C4G1S02P8D0G2JMY88KAFN",//the id of the reporting webhook instance
"object_type":"sms","metric":"drafted","timestamp":1585250305}
{"data":{"action_id":41,"campaign_id":7,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"ROk1AAIBcR4iT6mueuxiDtzO8HXv","failure_message":"Twilio Error 21408: Permission to send an SMS has not been enabled for the region indicated by the 'To' number: +18008675309.","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4F3DCS83P8HT7R3E6DWQN1X",//the id of the reporting webhook instance
"object_type":"sms","metric":"attempted","timestamp":1234567890}
{"data":{"action_id":38,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgIBcRhIBqSZNqzgZVFoivwW","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"recipient":"+18008675309"},"event_id":"01E4C4HDQ7KZF7AFPG6N2YQDJ0",//the id of the reporting webhook instance
"object_type":"sms","metric":"sent","timestamp":1585250350}
{"data":{"action_id":38,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgIBcRh6qzHz-8gKvscP2UZa","recipient":"+18008675309","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4XXG43MDMG47Z43V3090AW5",//the id of the reporting webhook instance
"object_type":"sms","metric":"delivered","timestamp":1585846946}
{"data":{"action_id":38,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgIBcRh6qzHz-8gKvscP2UZa","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"href":"https://app.com/verify","link_id":1,"recipient":"+18008675309"},"event_id":"01E4XXPN42JDF4B1ATQKTZ8WHV",//the id of the reporting webhook instance
"object_type":"sms","metric":"clicked","timestamp":1585847161}
{"data":{"action_id":38,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgIBcRh6qzHz-8gKvscP2UZa","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"recipient":"+18008675309"},"event_id":"01E4XXPN42JDF4B1ATQKTZ8WHV",//the id of the reporting webhook instance
"object_type":"sms","metric":"converted","timestamp":1585847161}
{"data":{"action_id":38,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgIBcRhIBqSZNqzgZVFoivwW","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"failure_message":"Twilio error code: 21704","recipient":"+18008675309"},"event_id":"01E4C4HENVDANXW94RQHHQYYDM",//the id of the reporting webhook instance
"object_type":"sms","metric":"bounced","timestamp":1585250351}
{"data":{"action_id":41,"campaign_id":7,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"ROk1AAIBcR4iT6mueuxiDtzO8HXv","failure_message":"Twilio Error 21408: Permission to send an SMS has not been enabled for the region indicated by the 'To' number: +18008675309.","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4F3DCS83P8HT7R3E6DWQN1X",//the id of the reporting webhook instance
"object_type":"sms","metric":"failed","timestamp":1234567890}
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"sms","timestamp":1613063089,"metric":"undeliverable","data":{"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"action_id":96,"campaign_id":2,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"},"failure_message":"Something went wrong!"}}
Slack event examples
{"data":{"action_id":39,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgQBcRhIBqRiZAc0fyQiLvkC","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4C4G1S0T3Y4V8W7F6MNFA8S",//the id of the reporting webhook instance
"object_type":"slack","metric":"drafted","timestamp":1585250305}
{"data":{"action_id":38,"campaign_id":6,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RAECAQFxNeUBx6LqfjqrN1j-BJc=","failure_message":"Variable 'customer.test' is missing","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4TYA2KA9T0XGHCRJ784B774",//the id of the reporting webhook instance
"object_type":"slack","metric":"attempted","timestamp":1585747134}
{"data":{"action_id":39,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgQBcRhNAufb0s30bmz5HD7Y","recipient":"#signups","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4C4TQKD6KJ274870J5DE2HB",//the id of the reporting webhook instance
"object_type":"slack","metric":"sent","timestamp":1585250655}
{"data":{"action_id":39,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgQBcRhocpCJE3mFfwvRzNe6","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"href":"http://bing.com","link_id":1,"recipient":"#signups"},"event_id":"01E4C6HJTBNDX18XC4B88M3Y2G",//the id of the reporting webhook instance
"object_type":"slack","metric":"clicked","timestamp":1585252451}
{"data":{"action_id":39,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgQBcRhIBqRiZAc0fyQiLvkC","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"failure_message":"value passed for channel was invalid",},"event_id":"01E4C4HDQ77BCN0X23Z3WBE764",//the id of the reporting webhook instance
"object_type":"slack","metric":"failed","timestamp":1585250350}
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"slack","timestamp":1613063089,"metric":"undeliverable","data":{"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"action_id":96,"campaign_id":2,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"},"failure_message":"Something went wrong!"}}
Webhook example events
{"data":{"action_id":40,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgEBcRhIBqSrYcXDr2ks6Pj9","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC"//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
},"event_id":"01E4C4G1S04QCV1NASF4NWMQNR",//the id of the reporting webhook instance
"object_type":"webhook","metric":"drafted","timestamp":1585250305}
{"data":{"action_id":38,"campaign_id":6,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RAECAQFxNeUBx6LqgjqrN1j-BJc=","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"failure_message":"Variable 'customer.test' is missing"},"event_id":"01E4TYA2KA9T0XGHCRJ784B774",//the id of the reporting webhook instance
"object_type":"webhook","metric":"attempted","timestamp":1585747134}
{"data":{"action_id":40,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgEBcRhNAufr2aU82jtDZEh6","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"recipient":"https://test.example.com/process"},"event_id":"01E4C6EP0HCKRHKFARMZ5XEH7A",//the id of the reporting webhook instance
"object_type":"webhook","metric":"sent","timestamp":1585252357}
{"data":{"action_id":40,"campaign_id":9,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RPILAgEBcRhNAufr2aU82jtDZEh6","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"href":"http://bing.com","link_id":1,"recipient":"https://test.example.com/process"},"event_id":"01E4C6F5N1Y54TVGJTN64Y1ZS9",//the id of the reporting webhook instance
"object_type":"webhook","metric":"clicked","timestamp":1585252373}
{"data":{"action_id":38,"campaign_id":6,"customer_id":"0200102","identifiers":{"id":"0200102",},"delivery_id":"RAECAQFxNeK3bC4SYqhQqFGBQrQ=","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"failure_message":"HTTP 404 Not Found []"},"event_id":"01E4TY5FVB0ZQ4KVDKRME0XSYZ",//the id of the reporting webhook instance
"object_type":"webhook","metric":"failed","timestamp":1585746984}
{"event_id":"01E4C4CT6YDC7Y5M7FE1GWWPQJ",//the id of the reporting webhook instance
"object_type":"webhook","timestamp":1613063089,"metric":"undeliverable","data":{"customer_id":"42","delivery_id":"ZAIAAVTJVG0QcCok0-0ZKj6yiQ==","trigger_event_id":"21E4C3CT6YDC7Y4N7FE1GWWABC",//the id of the event that triggered an event-triggered campaign (not an API-triggered broadcast)
"action_id":96,"campaign_id":2,"identifiers":{"id":"42","email":"test@example.com","cio_id":"d9c106000001"},"failure_message":"Something went wrong!"}}
Legacy email webhook format
On April 8, 2020, we streamlined our email webhook payloads, removing unneeded data in order to improve our processing speed and reliability.
If you had Reporting Webhooks enabled before April 8, 2020, the old email webhook payload remains unchanged.
The example below covers any of the email-related activity:
User-Agent:Customer.ioWebHooks1.0Host:webhook.siteContent-Type:application/jsonAccept-Encoding:gzipCf-Connecting-Ip:167.114.157.9X-Request-Id:7e6f46cd-480e-4354-93ce-74b770015c7fConnect-Time:1Content-Length:1100Cf-Visitor:{"scheme":"http"}Total-Route-Time:0Cf-Ipcountry:CACf-Ray:2b62237a83a12507-ORDConnection:closeVia:1.1vegurRAWBODY{"data":{"campaign_id":"1000002","campaign_name":"Upgrade to Premium","customer_id":"98513","email_address":"customer@example.com","email_id":"NTE4MzE6FwGLxwJkAAJkABcBIfcaAVVvdGukFUsYV2hY6QFlOjQ4YTZhODljLTM3MjktMTFlNi04MDQwLTYzNGY3NzAzM2NhNjozNDMwMzEA","message_id":"1000013","message_name":"First Upgrade Email","subject":"Have any doubts?","template_id":"343031","variables":{"attachments":null,"customer":{"created_at":1466453747,"email":"customer@example.com","id":98513,"name":"John Doe","plan_name":"free"},"email_id":"NTE4MzE6FwGLxwJkAAJkABcBIfcaAVVvdGukFUsYV2hY6QFlOjQ4YTZhODljLTM3MjktMTFlNi04MDQwLTYzNGY3NzAzM2NhNjozNDMwMzEA","event":{"page":"https://customer.io/pricing/"},"event_id":"48a6a89c-3729-11e6-8040-634f77033ca6","event_name":"viewed_pricing_page","from_address":null,"recipient":null,"reply_to":null}},"event_id":"b50cb221c60f87cdf06e","event_type":"email_drafted","timestamp":1466456299}
customer_id: user id (can be retrieved from the person profile). Only present if the person is still active (not included if the person has been deleted).
email_address: “To” email address
email_id: unique message id (each individual message sent from Customer.io has a different “email_id”); can also be found in the unsubscribe link URL
event: specific to event-triggered campaigns; includes all the event attributes
event_id (data section): specific to event-triggered campaigns; id of the event that generated the message (not visible in the UI)
event_id: internal attribute; id associated with the email_type action
event_name: specific to event-triggered campaigns; name of the event that powers the campaign
event_type: type of event (“email_drafted”, “email_sent”, etc.)
from_address: from_address set via the event
href and link_id: specific to “email_clicked” events
href: first URL clicked by the user
link_id: internal attribute (not visible in the UI)