listenSignalClosed

declare function listenSignalClosed(fn: (event: IStrategyTickResultClosed) => void): () => void;

Subscribes to closed tick results (live + backtest).

Fires when a position closes. pnl, closeReason and closeTimestamp are guaranteed present on the narrowed type.

Parameter Description
fn Callback receiving closed events