Closed DutchTowel closed 1 year ago
Got it to work like this: print('Sending:', data['symbol'], data['type'], data['side'], data['amount'], data['reduce_only']) order = exchange.create_order(data['symbol'], data['type'], data['side'], data['amount'], params={'reduce_only': data['reduce_only'], 'stop_loss': data['stop_loss']})
Hello, first of all thanks for all the time and effort you put in to creating this. I have the following issue: i am not familiar with python. And after trying all sorts of things for a week with changing tradingview alerts and the actions.py to get my problem solved. i just cant get it to work.
So i use bybit in hedge mode (both shorts and longs can be open at same time). To close a position the extra parameter reduce_only is needed, with values true or false. I also wanted to add a stop loss which i thought should also be added through params. I added them in actions.py as follows
i keep getting the error: NameError: name 'reduce_only' is not defined NameError: name 'stop_loss' is not defined
Any help would be greatly appreciated.. Thank you