mirror of
https://github.com/NoFxAiOS/nofx.git
synced 2026-07-09 14:00:57 +08:00
feat: upgrade Binance to Algo Order API and improve trading flow
- Upgrade go-binance to v2.8.9 with new Algo Order API - Migrate SetStopLoss/SetTakeProfit to use AlgoOrderTypeStopMarket/TakeProfitMarket - Update cancel functions to handle both legacy and Algo orders - Fix Lighter stop orders using correct order types (type=2/4) with TriggerPrice - Add CancelAllOrders before opening positions for Bybit and Lighter - Fix decision limit selector in API handler - Add stop_loss/take_profit/confidence fields to DecisionAction - Store decisions array in database with proper serialization - Redesign DecisionCard with beautiful entry/SL/TP display
This commit is contained in:
@@ -46,11 +46,14 @@ export interface DecisionAction {
|
||||
quantity: number
|
||||
leverage: number
|
||||
price: number
|
||||
stop_loss?: number // Stop loss price
|
||||
take_profit?: number // Take profit price
|
||||
confidence?: number // AI confidence (0-100)
|
||||
reasoning?: string // Brief reasoning
|
||||
order_id: number
|
||||
timestamp: string
|
||||
success: boolean
|
||||
error?: string
|
||||
reasoning?: string
|
||||
}
|
||||
|
||||
export interface AccountSnapshot {
|
||||
|
||||
Reference in New Issue
Block a user