Gets the current timestamp from execution context.
In backtest mode: returns the current timeframe timestamp being processed In live mode: returns current real-time timestamp
Promise resolving to current execution context timestamp in milliseconds
const timestamp = await getTimestamp();console.log(timestamp); // 1700000000000 Copy
const timestamp = await getTimestamp();console.log(timestamp); // 1700000000000
Gets the current timestamp from execution context.
In backtest mode: returns the current timeframe timestamp being processed In live mode: returns current real-time timestamp