Campaign and channel events
Describes delivery, engagement, disengagement, and reachability events your channel app can send to Optimizely Data Platform (ODP) as well as events that you can use for attribution modeling.
Channel apps send delivery, engagement, disengagement, and reachability events to Optimizely Data Platform (ODP) to track the performance of campaigns. These events allow ODP to build performance reports and attribute conversions to campaigns. Through reports, ODP users can see how their campaigns are performing and make adjustments to improve performance. ODP users can also use channel events in any other ODP feature, such as audiences, segments, and more.
Each channel supports different events, and you do not have to send all the events listed below. For example, if your channel does not report if a message was delivered, do not send the delivery
event. Similarly, if your channel does not allow clicks, do not send click
events.
Note
Optimizely Connect Platform (OCP) automatically generates
sent
events, so you do not have to send them in your channel app.
Send channel events to ODP
OCP sends channel events using the Node SDK event method, for example:
import {z} from '@zaiusinc/node-sdk';
var deliveryReport;
/* ... */
await z.event({
identifiers: {
phone: deliveryReport.to
},
type: 'sms',
action: 'delivery',
data: {
target_address: deliveryReport.to,
ts: deliveryReport.message.time
}
});
You can send events a variety of ways depending on your channel:
- From the channel implementation class. For example, send a
delivery
event from thedeliver
method
after receiving a delivery report from your channel. - From a function webhook. For example, send a
click
event from a webhook that receives a click report from your channel. - For a job. For example, retrieve delivery or click reports from your channel API and send events to ODP.
Events
Below is a list of events that you can send to ODP. For more information on the action
and type
attributes of ODP events, see ODP's developer documentation on events.
Delivery events
Delivery events record events along the delivery pipeline. Minimally, these consist of sent
events. The event type (type
) for these events is the channel.type
that you specify in the app.yml
file. The available delivery event actions are:
sent
– Records when a send occurrs; Optimizely generates this event.delivery
– Records when a message delivery occurs successfully.delivery_unknown
– Records when it is unknown whether a message delivery occurs successfully or unsuccessfully; typically only whendelivery
events are also possible.
Engagement events
Engagement events record when a message recipient has a positive interaction with the message. The event type (type
) for these events is the channel.type
that you specify in the app.yml
file. The available engagement event actions are:
open
– Records when a recipient opens a message.click
– Records when a recipient clicks a message.engage
– Records when a recipient generically engages with a message; use this when the engagement action does not cleanly fit into another action option.
Disengagement events
Disengagement events record when a message recipient has a negative interaction with the message.
Event type (type ) | Event action (action ) | Reachability update type (reachability_update_type ) | List ID (list_id ) |
---|---|---|---|
content | opt-out | ||
reachability | unreachable | spam_report | |
list | unsubscribe | [list_id] | |
[channel.type] | disengage |
Reachability events
Reachability events record when a message could not be delivered.
Event type (type ) | Event action (action ) | Reachability update type (reachability_update_type ) | Description |
---|---|---|---|
reachability | unreachable | hard_bounce | Records that a message could not be delivered for a permanent reason (for example, email address does not exist). |
[channel.type] | soft_bounce | Records that a message could not be delivered for an temporary reason (for example, mailbox is full). |
Note
You can only retrieve reachability events for messaging identifiers. For more information about identifiers in ODP, see the ODP developer documentation.
Attribution
Attributable actions are used in Optimizely's attribution model to determine which campaigns get credit for a conversion. These often, but not always, mirror engagement event actions. For more information on the ODP attribution model, see Campaign attribution.
Below is the list of event actions that you can use in ODP for attribution modeling:
open
– Indicates that you can attribute conversions toopen
events.click
– Indicates that you can attribute conversions toclick
events.engage
– Indicates that you can attribute conversions toengage
events.delivery
– Indicates that you can attribute conversions todelivery
events.
Updated 18 days ago