I am submitting a Custom Activity around a survey completion including the date the survey was responded to. My Custom Activity data submits, but there are some timezone inconsistencies I'd really like some answers on:
1. I submit this data:
{
"leadId": 6417012,
"activityDate": "2021-11-11T15:43:16.000Z",
"activityTypeId": 100001,
"primaryAttributeValue": "Quarterly Survey",
"attributes": [
{
"apiName": "surveySentDate",
"value": "2021-11-11T13:00:15.000Z"
},
{
"apiName": "surveyResponseDate",
"value": "2021-11-11T15:43:16.000Z"
}
]
}
The result shows:
Activity Date: Nov 11, 2021 10:43AM
Survey Sent Date: 2021-11-11 07:00:15
Survey Response Date: 2021-11-11 09:43:16
I see it's 5 hours off, and I'm in EST, so I adjust to add the TZ difference based on the docs:
{
"leadId": 6417012,
"activityDate": "2021-11-11T15:43:16-05:00",
"activityTypeId": 100001,
"primaryAttributeValue": "Quarterly Survey",
"attributes": [
{
"apiName": "surveySentDate",
"value": "2021-11-11T13:00:15-05:00"
},
{
"apiName": "surveyResponseDate",
"value": "2021-11-11T15:43:16-05:00"
}
]
}
The result shows:
Activity Date: Nov 11, 2021 3:43PM (correct)
Survey Sent Date: 2021-11-11 12:00:15
Survey Response Date: 2021-11-11 14:43:16
Why are these times off by an hour?
Daylight savings?
The dates are post-DST change and within 3 hours of each other, so I don't believe that plays into this. Solid idea based on the time of year though.
I felt the same--I don't have to do this in the bulk activity/lead exports.
TZ in the admin is EST. The actual activity log shows EST. Clicking into the activity to view the other custom activity data shows CST times.
Bump
Off to support we go!
So you never got an answer to this? Because I am seeing something similar.
My instance is set at EDT when I look in the admin and being that we are in June we are definitely in Eastern Daylight time
I am passing 2022-06-26T21:00:00.000Z
in the custom activity I am seeing 2022-06-26 16:00:00
but that is CDT or EST
I thought it might just be a display issue but when I pull the data through the API I see the following response
"activityDate": "2022-06-26T00:36:24Z", "attributes": [
{
"name": "Event Date",
"value": "2022-06-26 16:00:00"
}
...
]
Event Date is set as a datetime field in the custom activity but it doesn't appear to be stored as an date actual UTC date (like the activityDate is stored)
So this means no matter how I pull it out I am going to be an hour off. And because I have no way of changing Marketo servers, I cannot test if this is a DST error until November when we return to ST.
I started a new thread https://nation.marketo.com/t5/product-discussions/custom-activity-datetime-attributes/m-p/326440/hig... if you would like to follow there in case it gets any answers
I started another discussion in hopes of resurrecting the conversation in case you want to follow there if answers arise.
https://nation.marketo.com/t5/product-discussions/custom-activity-datetime-attributes/m-p/326440/hig...