Trade execution result.
Contains the outcome of a trade execution attempt, including success status, order details, and error information if applicable.
// Successful tradeconst success: TradeResult = { success: true, orderId: 'ORD123456', symbol: 'AAPL.US', side: 'buy', volume: 100, price: 150.25};// Failed tradeconst failure: TradeResult = { success: false, symbol: 'INVALID', side: 'buy', error: 'Symbol not found'}; Copy
// Successful tradeconst success: TradeResult = { success: true, orderId: 'ORD123456', symbol: 'AAPL.US', side: 'buy', volume: 100, price: 150.25};// Failed tradeconst failure: TradeResult = { success: false, symbol: 'INVALID', side: 'buy', error: 'Symbol not found'};
Optional
Error message if trade failed
Order ID if trade was successful
Execution price
Trade side (buy/sell)
Whether trade was executed successfully
Symbol that was traded
Volume traded
Trade execution result.
Contains the outcome of a trade execution attempt, including success status, order details, and error information if applicable.
Example