Date & Time HelpersThe Date & Time helpers allow you to manipulate date and time values of various formats from connectors and triggers.
The Date & Time helpers allow you to manipulate date and time values of various formats from connectors and triggers. These are commonly used for tasks such as converting date/time values to different formats, or finding the difference between two date & time values.
In this example, we'll be getting the current day of the week. The first thing we need to do is establish the current date and time.
Start by dragging the
Date & Time Helpers helper to a workflow and select
Get current timestamp from the operation dropdown.
We'll use the default timezone (UTC) but you could select any timezone from the dropdown combo based on your own requirements.
Next, we'll use the current date and time from step 1 to get the current day of the week.
Date & Time Helpers helper to the workflow and select
Get day of week from the operation dropdown.
Now connect the
Date & time input of the
Get day of week operation to the output of step 1 by using the Connector Snake.
Get day of week operation will take the current date and time from step 1 and work out the day of the week. Again, select the Timezone that you wish to work in. We are keeping everything in UTC for this example.
You should now have a workflow that looks like this with the Date & time populated with the json path of the step 1 output
All we need to do now is run the worflow...
Once the workflow has executed, you will be able to see the input and output of the
Get day of week operation in the debug panel.
As you can see, the date/time and timezone were passed as inputs and the operation calculated the day of the week as
Wednesday for the operation output.