Adjust Date/Time
Command description
Add or subtract a period of time from the specified date and time. When the original date and time is empty, the current system date and time is used.
Command Input Parameters
| input parameters | Input parameter type | Description |
|---|---|---|
| Original Date/Time | datetime or str | Optional, the date and time or parsable date and time text as the basis for calculation, such as 2026-06-20 12:30:00, 2026/06/20; when empty, the current date and time is used |
| Adjustment Method | enum | Add, Subtract |
| Duration | number or str | Amount to add or subtract, expressed in the selected time unit |
| Time Unit | enum | Second, Minute, Hour, Day, Month, Year |
| Text Type | bool | When True, it outputs text, when it is False, it outputs a datetime object. |
Command Output Parameters
| Output parameters | Output parameter type | Description |
|---|---|---|
| New Date/Time | datetime or str | Adjusted date and time; text when text type is enabled |
Supported date and time text formats
When datetime parameters use text, the following formats are supported:
| Format | Example |
|---|---|
| yyyy-MM-dd HH:mm:ss | 2026-06-20 12:30:00 |
| yyyy/MM/dd HH:mm:ss | 2026/06/20 12:30:00 |
| yyyy-MM-dd HH:mm | 2026-06-20 12:30 |
| yyyy/MM/dd HH:mm | 2026/06/20 12:30 |
| yyyy-MM-dd | 2026-06-20 |
| yyyy/MM/dd | 2026/06/20 |
| ISO format | 2026-06-20T12:30:00, 2026-06-20T12:30:00.123456, 2026-06-20T12:30:00+08:00 |
For AI-generated workflows, prefer yyyy-MM-dd HH:mm:ss and avoid unsupported formats such as "June 20, 2026".
AI Workflow Generation Notes
- The original date and time can be left blank. When left blank, None will be passed at runtime and the current time will be used.
- The original date and time can be datetime or parsable date and time text, such as
2026-06-20 12:30:00,2026/06/20; the time length must be a number or a numeric expression. - Time units in seconds, minutes, hours, and days support decimals; time units in months and years will be treated as integers.
- When Text Type is True, the output is a string in
yyyy-MM-dd HH:mm:ssformat. For other formats, return a datetime and use Convert Date/Time to Text.