jaggedsoft / node-binance-api

Node Binance API is an asynchronous node.js library for the Binance API designed to be easy to use.
MIT License
1.58k stars 768 forks source link

how can i close futures order #622

Open leimin78 opened 3 years ago

leimin78 commented 3 years ago

hi i'm new here , when i using below api can create open long and open short console.info( await binance.futuresBuy( 'TRXUSDT', 100, 0.0870 ) ); console.info( await binance.futuresSell( 'TRXUSDT', 100, 0.0880 ) );

how can i close the order by limit ?

leimin78 commented 3 years ago

let r1 = await binance.futuresOrder( 'BUY', 'TRXUSDT', 100, false, { type: 'TAKE_PROFIT', stopPrice: 0.08845, symbol: 'TRXUSDT', closePosition: true } );

when i try with this get error response as below: { code: -1128, msg: 'Combination of optional parameters invalid.' }

FireFoxII commented 3 years ago

+1

matheuscabralkk commented 3 years ago

+1