Time Information

AdjustTimestamp

Adjusts a Unix timestamp.

  • AdjustTimestamp([ unix ], [ addSeconds ], [ addMinutes ], [ addHours ], [ addDays ], [ addMonths ], [ addYears ])

Returns the new Unix timestamp.

Return Type: Number

Parameter Name

Parameter Type

Required

Suggested

unix

Number

False

Input, Number, SessionGet

addSeconds

Number

False

Input, Number, SessionGet

addMinutes

Number

False

Input, Number, SessionGet

addHours

Number

False

Input, Number, SessionGet

addDays

Number

False

Input, Number, SessionGet

addMonths

Number

False

Input, Number, SessionGet

addYears

Number

False

Input, Number, SessionGet

CreateTimestamp

Creates a Unix timestamp from the specified value.

  • CreateTimestamp([ year ], [ month ], [ day ], [ hour ], [ minute ], [ second ])

Returns the Unix timestamp.

Return Type: Number

Parameter Name

Parameter Type

Required

Suggested

year

Number

False

Input, Number, SessionGet

month

Number

False

Input, Number, SessionGet

day

Number

False

Input, Number, SessionGet

hour

Number

False

Input, Number, SessionGet

minute

Number

False

Input, Number, SessionGet

second

Number

False

Input, Number, SessionGet

CurrentDate

Gets the date of the month of the current time or requested time. Based on UTC.

  • CurrentDate([ unix ])

Returns the date of the month value. A number from 1 to 31.

Return Type: Number

Parameter Name

Parameter Type

Required

Suggested

unix

Number

False

Input, Number, SessionGet

CurrentDay

Gets the day of the week of the current time or requested time. Based on UTC.

  • CurrentDay([ unix ])

Returns the day of the week value. A number from 1 to 7, starting on Sunday.

Return Type: Number

Parameter Name

Parameter Type

Required

Suggested

unix

Number

False

Input, Number, SessionGet

CurrentHour

Gets the hour the current time or requested time. Based on UTC.

  • CurrentHour([ unix ])

Returns the hour value. A number from 0 to 23.

Return Type: Number

Parameter Name

Parameter Type

Required

Suggested

unix

Number

False

Input, Number, SessionGet

CurrentMinute

Gets the minute the current time or requested time. Based on UTC.

  • CurrentMinute([ unix ])

Returns the minute value. A number from 0 to 59.

Return Type: Number

Parameter Name

Parameter Type

Required

Suggested

unix

Number

False

Input, Number, SessionGet

CurrentMonth

Gets the month of the year of the current time or requested time. Based on UTC.

  • CurrentMonth([ unix ])

Returns the month of the year value. A number from 1 to 12.

Return Type: Number

Parameter Name

Parameter Type

Required

Suggested

unix

Number

False

Input, Number, SessionGet

CurrentSecond

Gets the second the current time or requested time. Based on UTC.

  • CurrentSecond([ unix ])

Returns the second value. A number from 0 to 59.

Return Type: Number

Parameter Name

Parameter Type

Required

Suggested

unix

Number

False

Input, Number, SessionGet

CurrentWeek

Gets the week of the year of the current time or requested time. Based on UTC.

  • CurrentWeek([ unix ])

Returns the week of the year value. A number from 1 to 53.

Return Type: Number

Parameter Name

Parameter Type

Required

Suggested

unix

Number

False

Input, Number, SessionGet

CurrentYear

Gets the year the current time or requested time. Based on UTC.

  • CurrentYear([ unix ])

Returns the year.

Return Type: Number

Parameter Name

Parameter Type

Required

Suggested

unix

Number

False

Input, Number, SessionGet

MinutesTillCandleClose

Calculates the number of minutes before a new candle opens.

  • MinutesTillCandleClose(interval)

Returns the number of minutes before a new candle opens.

Return Type: Number

Parameter Name

Parameter Type

Required

Suggested

interval

Number

True

InputInterval, Number, CurrentInterval

Time

Gets the current unix timestamp. Based on UTC.

  • Time()

Returns the current unix timestamp.

Return Type: Number

Last updated