Closed DanielCaspers closed 5 years ago
I have confirmed this is not an issue with Mixpanel-C#. I was in fact sending a UtcDateTime
as shown in my screenshot above, which I assume at some layer was cast to string when it became JSON.
I am only left to assume that when Mixpanel sees it, it rejects it because of the incompatible data type since they expect ms from epoch.
https://developer.mixpanel.com/docs/http#section-special-properties-in-events
Problem I have performed tests locally that have led me to believe one of two things is happening.
1) When using
[MixpanelName(MixpanelProperty.Time)]
on some member of an event being tracked using the/track
endpoint, MixPanel C# is not appropriately setting the metadata to tell Mixpanel that this member corresponds to thetime
property as described by MixPanel's list of reserved or special propertiesor
2) The documentation should be improved to better explain how the
[MixpanelName(MixpanelProperty.Time)]
attribute works.Background I have a base class which all events sent to Mixpanel inherit from called
BaseMixpanelEvent
. I've omitted other properties for brevity.For the test, I have a timestamp I've edited to be in the past by appx. 5 hours. The screenshot below shows
TimeStamp
set to3/25/2019 10:30:00 UTC
as represented byUtcDateTime
class during theMixpanelClient.TrackAsync()
callIn MixPanel, the timestamp for the same event is assigned on the server, hence it says it happened only seconds ago. It's making the event instead tagged as something close to
3/25/2019 15:34:00 UTC