tony-ho / binance-oco

A command line tool for placing conditional stop-limit, limit, and OCO (One-Cancels-the-Other) sell orders on Binance cryptocurrency exchange.
https://www.npmjs.com/package/binance-oco
MIT License
29 stars 12 forks source link

Is this valid for Margin Trading? #28

Closed afanjul closed 2 years ago

afanjul commented 3 years ago

Is this code valid for trading in margin account? or futures? otherwise could you add this feature using a environment variable or something ? thanks

tony-ho commented 3 years ago

@afanjul Unfortunately this won't work for margin or futures trading as those use a different Binance API.

I haven't considered adding Futures support as Binance Futures has TP/SL and Reduce orders, so there is less of a use case for a script like this when using Futures.

I don't use margin myself but will leave this issue open in case anyone else is after this functionality, or wants to add it.