Managing Behavioral Intelligence with Data Events
Behavioral intelligence data events are real-time records of actions users take - such as clicking a button, completing a purchase, or reaching the end of a page. By tracking these activities, you can trigger automated campaigns and build dynamic segments based on exactly how people engage (or fail to engage).
How do behavioral intelligence events works?
While a Custom Field represents persistent information you know about a person (like their Last Purchase or First Visit Location), an Event represents point-in-time data about an action a person took.
In our APIs and SDKs, you use the sendEvent JavaScript API to record these actions or the track events REST API.
Events can trigger automations, set goals, or define segment criteria - ensuring you respond instantly to exactly what people are doing on your website or in your app.
Anatomy of an Event
Every event you send consists of two core components:
- DailyStory Unique Id: This is the unique identifier of the associated DailyStory contact.
- Event Name: This is the unique identifier (e.g.,
whitepaper_download) used to target specific behaviors in your automation workflows. - Event Data: This is the metadata associated with the action. You can reference this information to personalize messages, or use it to filter segment criteria.
What types of tracked events are available?
DailyStory supports reserved events, such as conversions and page visits, but also allows customers to create custom tracked events that start automations.
- Custom event tracking: Instantly launch a "Welcome" or "Re-engagement" automation when a specific event is received.
- Conversion tracking: Measure the success of your marketing by marking a goal as "Achieved" once a user performs a specific action that is related back to a conversion funnel. Conversion tracking is a built-in event that is integrated with the conversion funnel.
- Page visit tracking: Track pages that contacts visit and run automations. For example, when a contact visits the licensing and pricing page. Page visit tracking is a built-in event that is integrated throughout DailyStory.
Conversion tracking and page visit tracking are both dedicated event type that are natively integrated with conversions funnels.
Using data events in automations
A data event can reach an automation in three ways. Together they let an automation respond to what a contact did — and, just as importantly, to what they never did.
- Start an automation — the When an event is received trigger enrolls a contact the moment the event arrives.
- Wait for an event — the Wait for an event condition holds a contact at a step until the event arrives, or until the time you allow runs out, then branches Yes or No.
- Exit an automation — an exit goal removes a contact from the automation as soon as the event is recorded, wherever they had reached.
Waiting for an event before continuing
Most nurture sequences send on a timer regardless of whether the contact is making progress. The Wait for an event condition replaces that timer with a question: did this contact do the thing yet?
Select the event to wait for and how long to wait. The contact continues down the Yes branch as soon as the event is recorded — they do not sit at the step for the rest of the window. If the window closes without it, they continue down the No branch.
By default only events recorded after the contact reaches the step count. Use the Also count the event if it happened option to look back before the step — for example when a contact may have acted while an earlier step was still running.
Example: a free trial sequence
Send your trial emails only to the people still worth emailing. Track an event such as verification_submitted when a trial completes a setup step, then gate the sequence on it:
- Send the welcome email.
- Add a Wait for an event condition for
verification_submittedwith a 48 hour window. - On Yes, carry on with the rest of the trial sequence.
- On No, stop — a trial that has not verified in 48 hours is unlikely to convert, and the remaining emails are wasted on them.
The same pattern works in reverse. If an event tells you a trial is succeeding — they configured email marketing, say — set that event as an exit goal so they leave the nurture sequence instead of being sold something they have already adopted.
ImportantEvent names are matched exactly, ignoring case. The name you select in the automation must be the same name your application sends to the track events API.
Event name and data
While event data is highly flexible and can take any structure, we recommend maintaining a consistent data schema for events sharing the same name. Consistency ensures that your automation logic remains reliable and your reporting stays clean.
Below are some recommended patterns.
Recommended naming patterns for events
- [category]:[item] - For example,
new_user:sign_up_button. This let's us know that the sign_up_button was clicked on the new user page. - Descriptive name - For example,
new_user_sign_up_button. Similar to the event name above.
You can leverage this data to display personalized information in your messages, or use it in segments to filter users who performed the same action but with different values (such as filtering by a specific product category or price point).
Accessing Event Data
Depending on your integration - whether via JavaScript or the REST API - the method for sending data may vary slightly. However, you can always access nested event data within your campaigns and segments using standard JSON dot notation.
Best Practices
- Consistency is Key: If the
purchaseevent includesorder_idas a string once, keep it as a string for all future logs to prevent segment errors. - Flatten When Possible: While we support nested JSON, keeping your most important data points at the "top level" of your
event_valuemakes it even faster to query in the dashboard. - Type Awareness: Remember that our segment builder treats
100(number) and"100"(string) differently. Ensure your SDK sends the correct data type for accurate filtering.