Custom Activity DateTime shows different times for same input | Community
Skip to main content
New Participant
November 11, 2021
Question

Custom Activity DateTime shows different times for same input

  • November 11, 2021
  • 2 replies
  • 4002 views

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?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

2 replies

SanfordWhiteman
New Participant
November 12, 2021
There's no reason to be doing manual offsets. The data is only stored one way, in UTC.

What is the time zone set in Admin? And when you say "the result" you mean the Activity Log tab?
New Participant
November 15, 2021

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.

 

New Participant
November 16, 2021

Bump

Jo_Pitts1
Community Manager
November 12, 2021

Daylight savings?

New Participant
November 15, 2021

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.