Skip to main content

Convert to Date/Time

Command description

Converts text to a datetime object. When Use Custom Format is enabled, provide a format such as yyyy-MM-dd HH:mm:ss.

Command Input Parameters

input parametersInput parameter typeDescription
TextstrDate/time text to convert
Use Custom FormatboolWhether to use custom time format to parse text
Time FormatstrOnly required if using custom format is True, e.g. yyyy-MM-dd HH:mm:ss

Command Output Parameters

Output parametersOutput parameter typeDescription
Date/TimedatetimeConverted datetime object

Supported date and time text formats

When datetime parameters use text, the following formats are supported:

FormatExample
yyyy-MM-dd HH:mm:ss2026-06-20 12:30:00
yyyy/MM/dd HH:mm:ss2026/06/20 12:30:00
yyyy-MM-dd HH:mm2026-06-20 12:30
yyyy/MM/dd HH:mm2026/06/20 12:30
yyyy-MM-dd2026-06-20
yyyy/MM/dd2026/06/20
ISO format2026-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".

Supported time format placeholders

Custom time formats and output time formats support the following placeholders:

placeholdermeaningExample
yyyy or YYYY4 digit year2026
MM2 digit month06
dd or DD2 digit date20
HH or hh24-hour clock12
mm2 digit minutes30
ss2 digit seconds00

Commonly used formats: yyyy-MM-dd HH:mm:ss, yyyy/MM/dd HH:mm:ss, yyyy-MM-dd.

AI Workflow Generation Notes

  • Text must be a string; do not generate "time format" when custom formatting is not enabled.
  • The time format must be filled in when enabling custom formats; note that MM is the month and mm is the minute.