removed leverage from create order api call

This commit is contained in:
Sam Germain 2021-09-19 02:23:05 -06:00
parent 2b6d134294
commit 835e0e69fc
4 changed files with 10 additions and 26 deletions

View File

@ -15,3 +15,7 @@ For longs, the currency which pays the interest fee for the `borrowed` will alre
Rollover fee = P (borrowed money) * R (quat_hourly_interest) * ceiling(T/4) (in hours)
I (interest) = Opening fee + Rollover fee
[source](https://support.kraken.com/hc/en-us/articles/206161568-What-are-the-fees-for-margin-trading-)
# TODO-lev: Mention that says you can't run 2 bots on the same account with leverage,
#TODO-lev: Create a huge risk disclaimer

View File

@ -107,15 +107,8 @@ class Binance(Exchange):
rate = self.price_to_precision(pair, rate)
order = self._api.create_order(
symbol=pair,
type=ordertype,
side=side,
amount=amount,
price=rate,
params=params,
leverage=leverage
)
order = self._api.create_order(symbol=pair, type=ordertype, side=side,
amount=amount, price=rate, params=params)
logger.info('stoploss limit order added for %s. '
'stop price: %s. limit: %s', pair, stop_price, rate)
self._log_exchange_response('create_stoploss_order', order)

View File

@ -81,14 +81,8 @@ class Ftx(Exchange):
params['stopPrice'] = stop_price
amount = self.amount_to_precision(pair, amount)
order = self._api.create_order(
symbol=pair,
type=ordertype,
side=side,
amount=amount,
leverage=leverage,
params=params
)
order = self._api.create_order(symbol=pair, type=ordertype, side=side,
amount=amount, params=params)
self._log_exchange_response('create_stoploss_order', order)
logger.info('stoploss order added for %s. '
'stop price: %s.', pair, stop_price)

View File

@ -114,15 +114,8 @@ class Kraken(Exchange):
try:
amount = self.amount_to_precision(pair, amount)
order = self._api.create_order(
symbol=pair,
type=ordertype,
side=side,
amount=amount,
price=stop_price,
leverage=leverage,
params=params
)
order = self._api.create_order(symbol=pair, type=ordertype, side=side,
amount=amount, price=stop_price, params=params)
self._log_exchange_response('create_stoploss_order', order)
logger.info('stoploss order added for %s. '
'stop price: %s.', pair, stop_price)