Skip to main content
April 3, 2023
Solved

How is timezone handled when using a custom field with datetime type

  • April 3, 2023
  • 1 reply
  • 141 views

We are looking to build some custom fields with datetime values.  When we insert them as variables into a message are they timezone aware?

 

The person asking me about this is creating a template and wants to insert a custom field of datetime and wants to know when the message based on the template is sent how will the datetime values show?

 

Thanks

    Best answer by jason

    Hi Tom,

    Yes - the Message Template should render the datetime in a timezone-aware way, presenting the timestamp with a timezone indicator. The datetime value itself is stored as a unix timestamp, so its timezone-agnostic. 

    Below are some screenshots showing the same Message Template reply (including an Account datetime custom field) to the same recipient from two different timezones:

    View from Australian Eastern timezone

     

    View from US Pacific timezone

     

    1 reply

    jason
    jasonAnswer
    Fronteer
    April 3, 2023

    Hi Tom,

    Yes - the Message Template should render the datetime in a timezone-aware way, presenting the timestamp with a timezone indicator. The datetime value itself is stored as a unix timestamp, so its timezone-agnostic. 

    Below are some screenshots showing the same Message Template reply (including an Account datetime custom field) to the same recipient from two different timezones:

    View from Australian Eastern timezone

     

    View from US Pacific timezone