moved get_maintenance_ratio_and_amt to base.exchange. Wrote get_leverage_tiers. Added mmr_key to exchange._ft_has

This commit is contained in:
Sam Germain
2022-02-05 19:32:46 -06:00
parent ee5f05208e
commit a5aba4813d
7 changed files with 150 additions and 128 deletions

View File

@@ -25,7 +25,7 @@ class Okx(Exchange):
# TradingMode.SPOT always supported and not required in this list
# (TradingMode.MARGIN, MarginMode.CROSS),
# (TradingMode.FUTURES, MarginMode.CROSS),
# (TradingMode.FUTURES, MarginMode.ISOLATED)
(TradingMode.FUTURES, MarginMode.ISOLATED),
]
def _lev_prep(
@@ -46,3 +46,6 @@ class Okx(Exchange):
"mgnMode": self.margin_mode.value,
"posSide": "long" if side == "buy" else "short",
})
def get_leverage_tiers(self, pair: str):
return self._api.fetch_leverage_tiers(pair)