Webhook gives me wrong TriggerTime

Hello!
Something strange happens when my webhook receives some data from Monday. It gives me the wrong Timestamp on the triggerTime variable. It’s off by excatly 60 minutes. Time here was 11:29 when I received the data, but on the data I get back it says “10:29”. I’ve tried it on different times and it always gives me the time with one hour shaved off.
I’m in Sweden which puts me in the timezone “GMT+01:00 Stockholm”. Can anybody give me a reason for that?
I need the correct time to be able to calculate what to do with the data.
Thanks! :slight_smile:

hi @Sina

I don’t think it is wrong, is shows:
triggerTime: '2022-02-03T10:54:35.434Z

The Z at the end indicates it is in “Zero” timezone (aka UTC or GMT). See also python - What exactly does the T and Z mean in timestamp? - Stack Overflow.

Oh. I didn’t know that. So there’s no way of getting it set to my timezone? Or must I always +1 in the calculations? Thanks for the quick answer!

The webhook always report in UTC. Also all dates and times stored in columns are stored in UTC. The TZ variable in the profile is used to convert the date / time you enter in a column to UTC, and visa versa when you view that date. I use date and time here because not only the time can be affected, also the date. If you are in Sweden I suggest you always test at 23.30 and 0.30 to make sure your TZ is handles correctly. As we are one hour off (or 2 hours in summer) when you enter a date at 0.30 on Wednesday the date is stored as Tuesday 23.30. You even need to think about months and years as the can be off too.

I recommend that your app always read any time from monday and interpret that as UTC. When you enter time in your app (e.g. in a text box) you need to use the TZ of the user by reading the user’s profile. If you calculate a time and store it in monday you need to use the TZ of the server calculating the time (in most cases Local) will do.

In NodeJS there is a very nice package that can do all of this for you, it’s called Luxon (see luxon - npm)