fix: align identity events with mParticle batch schema#88
Merged
khushi1033 merged 2 commits intodevelopmentfrom Apr 16, 2026
Merged
fix: align identity events with mParticle batch schema#88khushi1033 merged 2 commits intodevelopmentfrom
khushi1033 merged 2 commits intodevelopmentfrom
Conversation
rmi22186
approved these changes
Apr 16, 2026
github-actions Bot
pushed a commit
that referenced
this pull request
Apr 16, 2026
## [1.24.1](v1.24.0...v1.24.1) (2026-04-16) ### Bug Fixes * align identity events with mParticle batch schema ([#88](#88)) ([ddcfa61](ddcfa61))
Collaborator
|
🎉 This PR is included in version 1.24.1 🎉 The release is available on:
Your semantic-release bot 📦🚀 |
jamesnrokt
added a commit
that referenced
this pull request
Apr 16, 2026
Resolves conflict between DRY refactor (handleIdentityComplete) and the identity event schema fix (#88) by using RoktIdentityEventType enum constants in the shared helper. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary##
Refactors identity events to use the mParticle batch event schema format (
{ event_type, data })Event types are mapped per the Rokt Brain Data Model:
onLoginComplete→loginonLogoutComplete→logoutonModifyComplete→modify_useronUserIdentified→identifyMPIDandUserIdentitiesare removed from individual events — they're already on the batch envelope (batch.mpid,batch.user_identities) and don't need to be duplicated per-event.EventDataTypeandEventCategoryare dropped as mParticle SDK internals with no Rokt equivalent.Before:
{ "EventName": "login", "EventDataType": 14, "EventCategory": 0, "Timestamp": 1775491325250, "MPID": "861148", "SessionId": "1EA1DFD3", "UserIdentities": { "email": "jenny@rokt.com" } }After:
{ "mpid": "8611485194723014758", "user_identities": { "customer_id": "2caa7a4d007b44139e0e17b7a23ac7fb", "email": "jenny.smith@rokt.com", "other_id_6": "CDID1.9.8921.1744745313237" }, // ... rest of batch payload (user_attributes, consent_state, device_info, etc.) "events": [ { "event_type": "login", "data": { "timestamp_unixtime_ms": 1775491325250, "session_uuid": "1EA1DFD3-0FBA-42F5-9FA9-6301AA4FC784", "mpid": "8611485194723014758" } } ] }Testing Plan
event_type,data.timestamp_unixtime_ms)event_typeper callback, merge into outgoing batches, queue flush on kit init, and queue cleared after send