Contract for pending signal lifecycle events (open and close).
Emitted by signalEventSubject when a pending position is opened (action "opened") or closed (action "closed") during tick()/backtest() processing. Lets consumers track the active phase of a signal without subscribing to the full signal stream.
Covers every way a position opens (new signal, immediate entry, scheduled activation, user activation) and every way it closes (take_profit / stop_loss / time_expired / user-close / broker fill / order no longer pending).
Consumers:
action: "opened" | "closed"
Lifecycle action for the pending signal.
symbol: string
Trading pair symbol (e.g., "BTCUSDT"). Identifies which market this event belongs to.
strategyName: string
Strategy name that owns this pending signal.
exchangeName: string
Exchange name where this pending signal lives.
frameName: string
Frame name (timeframe / date range) for the run. Empty string in live mode.
Same value as the signal's frameName (data.frameName).
data: IPublicSignalRow
Complete pending signal row data in public form. Contains all signal information: id, position, priceOpen, priceTakeProfit, priceStopLoss, effective entry / trailing SL/TP, PnL, etc.
closeReason: StrategyCloseReason
Close reason. Present only when action === "closed":
Always undefined when action === "opened".
currentPrice: number
Current market price of the symbol at the time of the event. For "opened" this is the effective entry (priceOpen); for "closed" the close price.
backtest: boolean
Execution mode flag.
timestamp: number
Event timestamp in milliseconds since Unix epoch.
Timing semantics: