Time in Variable

Is there a context (or any other) variable that can add trigger times to a variable?
I know I can create separate rules but I’m wondering I this is possible in a single rule


variable is X then set Y (add time triggered)
Else If
variable is Y then set Z (add time triggered)

Not officially. There’s an undocumented $context.event.timestamp variable, but it’s in UTC so I don’t think it would be useful in the way many people would want to use it.

Feel free to create a feature request! When we originally built out the context variables concept, we bounced around the idea of time related data, but we weren’t sure what the use-cases were… and we figured there would be other requirements (eg. display format, which timezone, etc) but hadn’t heard any requests for it, so we prioritized other requested features.

You can use time within IF conditions, so you could accomplish what you’re looking for in your example rule.

Since we know the triggers are 6PM and 9PM, we can use a time condition that checks if it’s before or after some time between the two triggers. In other words: if it’s before 7PM then it’s our 6PM trigger, otherwise it’s after 7PM so it’s our 9PM trigger


Thanks Josh, maybe $context.event.timestamp variable could be good enough for record purposes, is it available ? How can I get it ? Thanks.
UPDATE: I had found how do it my friend. I will try !..thanks.

Set {{$context.event.timestamp}} to a text variable …

1 Like


I think the “USER LOGs Creation” feature request could include this, for each record, user can add timestamp… but has 0 votes … :pensive:

Thanks for the update and glad you got it working.

While they perhaps could work very well together, I still see the request for Timestamp related features as its own distinct request. As mentioned above, it’s still not clear what the requirements for a Timestamp feature request would be, but I suspect there might be a need for formatting timestamps, converting timezones, etc… :slight_smile:

1 Like