gorgeous-dream-88338
06/16/2023, 3:22 AMGroup Analytics paid add-on. Whenever we send a group call via RS, it overwrites the user’s location details in MP with RudderStack’s server location because the <http://mixpanel.com/engage|mixpanel.com/engage> API request is incredibly stripped down - namely it lacks the user’s $ip.
Is there any way we can customize this request? Failing that, what other options do we have? Thanksmillions-activity-52391
06/16/2023, 3:22 AMquiet-wolf-72320
06/16/2023, 12:23 PMgorgeous-dream-88338
06/19/2023, 2:07 AMgorgeous-dream-88338
08/07/2023, 6:12 AMquiet-wolf-72320
08/07/2023, 9:11 AMgorgeous-dream-88338
08/07/2023, 10:49 AMgroup call is sent.
Some findings which may or may not help:
• Sending window.rudderanalytics.group('test') and using groupId as the key results in two requests to Mixpanel:
◦ /engage presumably to update or set the user's groupId property on their profile - live events to Mixpanel shows:
"JSON_ARRAY": {
"batch": [
{
"$token": "redacted",
"$distinct_id": "test-id-123",
"$set": {
"groupId": [
"test"
]
}
}
]
}
◦ /groups presumably to update or create the group
"JSON_ARRAY": {
"batch": [
{
"$token": "87454b28224e9f6be63124a50208a790",
"$group_key": "groupId",
"$group_id": "test",
"$set": {}
}
]
}
◦ Note the lack of $ip in the call to /engage in this instance.
• Sending window.rudderanalytics.group('test', { workspace_id: 'test' }) with any trait (in this case I've also added workspace_id as a valid group key) results in these two requests to Mixpanel:
◦ /engage - there is now an $ip property, but it's only part of the second $set object along with the user's and group's traits. I am 10/10 on refreshes and it always results in Virginia, US. I'm not sure what this suggests, whether it's how Mixpanel processes the order of batched $sets or otherwise, but hopefully helpful to know?
"JSON_ARRAY": {
"batch": [
{
"$token": "redacted",
"$distinct_id": "test-id-123",
"$set": {
"groupId": [
"test"
]
}
},
{
"$set": {
"$email": "<mailto:test-1691403582189@test.com|test-1691403582189@test.com>",
"$name": "Test 1691403582189",
"$screen_height": 1080,
"$screen_width": 1920,
"$initial_referrer": "$direct",
"workspace_id": "test",
"$browser": "Chrome",
"$browser_version": "115.0.0.0"
},
"$token": "redacted",
"$distinct_id": "test-id-123",
"$ip": "redacted",
"$time": 1691403583
}
]
}
◦ /group does not change.
I'm not sure if there are any special conditions we need to set or values we need to send in order to make this work as expected?millions-activity-52391
08/07/2023, 10:52 AMgorgeous-dream-88338
08/07/2023, 11:09 AM$ip against both $set objects it works as needed -- hopefully that's all to then get this working properly 🙏
const options = {
method: 'POST',
headers: {accept: 'text/plain', 'content-type': 'application/json'},
body: JSON.stringify([
{
$token: 'redacted',
$distinct_id: 'test-id-123',
$set: {groupId: 'test'},
$ip: 'redacted'
},
{
$token: 'redacted',
$distinct_id: 'test-id-123',
$set: {other: 'key'},
$ip: 'redacted'
}
])
};gorgeous-dream-88338
11/13/2023, 5:23 AMgroup call resulting in users still being tagged as US Virginia. Any updates?millions-activity-52391
11/13/2023, 4:07 PMmillions-activity-52391
11/20/2023, 4:20 PM