Custom Command
FunctionsDate Functions

$timeToDate

Convert a Unix timestamp (milliseconds since January 1, 1970 UTC) into a formatted date string. This function respects the timezone configured via the $timeZone function.

Usage

$timeToDate[Timestamp;Format (optional)]

Parameters:

  • Timestamp: The Unix timestamp in milliseconds you want to convert.
  • Format (optional): A string defining the desired date and time format. If omitted, a default format will be applied.

Example:

This example converts the current timestamp (obtained using $timeStamp) to a YYYY-MM-DD format.

Member
9/5/2026

!!exec $timeToDate[$timeStamp;%y%-%m%-%d%]

Custom Command
APP
9/5/2026

2022-03-12

Accepted Time Formats

For a comprehensive list of accepted time format specifiers, refer to this reference. These specifiers allow you to customize the output to display the date and time in various formats.

On this page