-
Notifications
You must be signed in to change notification settings - Fork 198
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Summary
The AmplitudeSessionPlugin currently emits session_start and session_end track events in addition to enriching all events with session_id.
According to Amplitude's documentation, the session_id property is the primary
mechanism for session tracking, while the start/end events are optional. Amplitude staff has
confirmed that sessions work correctly without these events.
For high-volume applications, these events can represent a big chunk of total Segment API calls. I'd like the ability to disable the event emission while retaining session_id enrichment.
Proposed Solution
Add a disableSessionEvents configuration option:
interface AmplitudeSessionPluginConfig {
/**
* When true, suppresses 'session_start' and 'session_end' track events.
* The session_id will still be attached to all events via integrations.
*
* @default false
*/
disableSessionEvents?: boolean;
}
// Usage
segmentClient.add({
plugin: new AmplitudeSessionPlugin({ disableSessionEvents: true })
});Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request