Skip to main content

Date and time

27 commands. Toolkit id ooa.datetime.

CommandWhat it does
Add to dateAdd (or subtract, with a negative amount) a duration to a date.
Add working daysMove a date by a number of working days, skipping the weekend and holidays of a business calendar; a negative number moves back. The start date itself is not counted (1 from Friday is Monday) and 0 keeps the date. The time of day is kept.
Convert time zoneShow a date as the time in another time zone, as text with its offset (2026-11-10T14:30+05:30).
Count working daysCount the working days between two dates in a business calendar: the days after the start up to and including the end (the start too, when chosen). The count is negative when the end is before the start.
Date is afterTrue when the first date is later than the second.
Date is beforeTrue when the first date is earlier than the second.
Date is betweenTrue when the date lies between two dates, both included.
Dates are equalTrue when both dates are the same moment, or the same day when the time is not included.
Difference between datesReturn end minus start in the chosen unit (may be fractional).
End of periodReturn the last second (23:59:59) of the day, week (Sunday), month or year containing a date.
Format dateFormat a date as text in a time zone, using a pattern such as dd/MM/yyyy HH:mm.
Get current date and timeThe date and time now. Show it in your time zone with Format date (Local, the runner's own, for new steps).
Get part of dateReturn one part of a date, such as the year, month, day of week, week of year or quarter, in a time zone.
Is afterCheck whether the first date is later than the second.
Is beforeCheck whether the first date is earlier than the second.
Is equalCheck whether two dates are the same moment.
Is leap yearCheck whether the year of a date, or a year number, is a leap year.
Is weekendTrue when the date falls on Saturday or Sunday in the given time zone.
Is working dayCheck whether a date is a working day in a business calendar: not on its weekend and not one of its holidays.
Is working dayTrue when the date is a working day in a business calendar: not on its weekend and not one of its holidays.
Next working dayReturn the first working day after a date in a business calendar, or the date itself when it is a working day and same_day is on. The time of day is kept.
Previous working dayReturn the last working day before a date in a business calendar, or the date itself when it is a working day and same_day is on. The time of day is kept.
Start of periodReturn midnight at the start of the day, week (Monday), month or year containing a date.
Subtract from dateSubtract an amount of time from a date.
Text is a valid dateTrue when the text can be read as a date with the pattern.
Text to dateRead a date from text with a pattern such as dd/MM/yyyy, in the time zone the text is written in (Local, the runner's own, for new steps).
Within business hoursTrue between the start and end hours in the time zone, on weekdays (or every day).