Pure per-event session field computation.
Summary
Functions
Returns true when a session meets the GA4 engaged-session thresholds.
Builds the attrs for a brand-new session's first event.
Computes field changes for a subsequent event on a live session.
Functions
@spec engaged?(GoodAnalytics.Core.Sessions.Session.t() | map()) :: boolean()
Returns true when a session meets the GA4 engaged-session thresholds.
@spec new_session_attrs(String.t(), map(), DateTime.t()) :: map()
Builds the attrs for a brand-new session's first event.
@spec update_session_attrs( GoodAnalytics.Core.Sessions.Session.t(), String.t(), map(), DateTime.t() ) :: map()
Computes field changes for a subsequent event on a live session.