ccxt 4.4.98__py2.py3-none-any.whl → 4.4.100__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ccxt/__init__.py +3 -1
- ccxt/abstract/bingx.py +1 -0
- ccxt/abstract/bitget.py +6 -0
- ccxt/abstract/hibachi.py +26 -0
- ccxt/alpaca.py +1 -1
- ccxt/apex.py +1 -1
- ccxt/ascendex.py +1 -1
- ccxt/async_support/__init__.py +3 -1
- ccxt/async_support/alpaca.py +1 -1
- ccxt/async_support/apex.py +1 -1
- ccxt/async_support/ascendex.py +1 -1
- ccxt/async_support/base/exchange.py +44 -9
- ccxt/async_support/base/ws/client.py +3 -1
- ccxt/async_support/bigone.py +1 -1
- ccxt/async_support/binance.py +10 -8
- ccxt/async_support/bingx.py +33 -4
- ccxt/async_support/bitbank.py +1 -1
- ccxt/async_support/bitfinex.py +4 -1
- ccxt/async_support/bitflyer.py +1 -1
- ccxt/async_support/bitget.py +2040 -561
- ccxt/async_support/bithumb.py +1 -1
- ccxt/async_support/bitmart.py +2 -2
- ccxt/async_support/bitmex.py +3 -2
- ccxt/async_support/bitopro.py +1 -1
- ccxt/async_support/bitrue.py +2 -2
- ccxt/async_support/bitso.py +1 -1
- ccxt/async_support/bitstamp.py +1 -1
- ccxt/async_support/bittrade.py +1 -1
- ccxt/async_support/bitvavo.py +1 -1
- ccxt/async_support/blockchaincom.py +1 -1
- ccxt/async_support/blofin.py +1 -1
- ccxt/async_support/btcmarkets.py +1 -1
- ccxt/async_support/bybit.py +7 -3
- ccxt/async_support/coinbase.py +1 -1
- ccxt/async_support/coinbaseexchange.py +1 -1
- ccxt/async_support/coinbaseinternational.py +1 -1
- ccxt/async_support/coincatch.py +2 -2
- ccxt/async_support/coinex.py +67 -6
- ccxt/async_support/coinmate.py +1 -1
- ccxt/async_support/coinsph.py +1 -1
- ccxt/async_support/cryptocom.py +2 -2
- ccxt/async_support/defx.py +2 -2
- ccxt/async_support/delta.py +1 -1
- ccxt/async_support/deribit.py +1 -1
- ccxt/async_support/digifinex.py +2 -2
- ccxt/async_support/ellipx.py +1 -1
- ccxt/async_support/exmo.py +1 -1
- ccxt/async_support/foxbit.py +3 -3
- ccxt/async_support/gate.py +18 -4
- ccxt/async_support/gemini.py +1 -1
- ccxt/async_support/hashkey.py +2 -2
- ccxt/async_support/hibachi.py +2080 -0
- ccxt/async_support/hitbtc.py +2 -2
- ccxt/async_support/hollaex.py +1 -1
- ccxt/async_support/htx.py +4 -3
- ccxt/async_support/hyperliquid.py +71 -29
- ccxt/async_support/independentreserve.py +1 -1
- ccxt/async_support/indodax.py +1 -1
- ccxt/async_support/kraken.py +1 -1
- ccxt/async_support/krakenfutures.py +2 -1
- ccxt/async_support/kucoin.py +2 -2
- ccxt/async_support/kucoinfutures.py +2 -1
- ccxt/async_support/lbank.py +2 -2
- ccxt/async_support/mercado.py +1 -1
- ccxt/async_support/mexc.py +9 -2
- ccxt/async_support/modetrade.py +93 -2
- ccxt/async_support/ndax.py +1 -1
- ccxt/async_support/novadax.py +35 -1
- ccxt/async_support/okcoin.py +1 -1
- ccxt/async_support/okx.py +2 -2
- ccxt/async_support/onetrading.py +33 -0
- ccxt/async_support/oxfun.py +1 -1
- ccxt/async_support/p2b.py +32 -0
- ccxt/async_support/paradex.py +2 -1
- ccxt/async_support/phemex.py +2 -2
- ccxt/async_support/poloniex.py +2 -2
- ccxt/async_support/probit.py +36 -1
- ccxt/async_support/tokocrypto.py +1 -1
- ccxt/async_support/upbit.py +1 -1
- ccxt/async_support/vertex.py +1 -1
- ccxt/async_support/wavesexchange.py +1 -1
- ccxt/async_support/whitebit.py +2 -2
- ccxt/async_support/woo.py +4 -4
- ccxt/async_support/woofipro.py +93 -2
- ccxt/async_support/xt.py +2 -2
- ccxt/async_support/yobit.py +1 -1
- ccxt/async_support/zaif.py +1 -1
- ccxt/async_support/zonda.py +1 -1
- ccxt/base/errors.py +0 -6
- ccxt/base/exchange.py +11 -9
- ccxt/base/types.py +1 -0
- ccxt/bigone.py +1 -1
- ccxt/binance.py +10 -8
- ccxt/bingx.py +33 -4
- ccxt/bitbank.py +1 -1
- ccxt/bitfinex.py +4 -1
- ccxt/bitflyer.py +1 -1
- ccxt/bitget.py +2040 -561
- ccxt/bithumb.py +1 -1
- ccxt/bitmart.py +2 -2
- ccxt/bitmex.py +3 -2
- ccxt/bitopro.py +1 -1
- ccxt/bitrue.py +2 -2
- ccxt/bitso.py +1 -1
- ccxt/bitstamp.py +1 -1
- ccxt/bittrade.py +1 -1
- ccxt/bitvavo.py +1 -1
- ccxt/blockchaincom.py +1 -1
- ccxt/blofin.py +1 -1
- ccxt/btcmarkets.py +1 -1
- ccxt/bybit.py +7 -3
- ccxt/coinbase.py +1 -1
- ccxt/coinbaseexchange.py +1 -1
- ccxt/coinbaseinternational.py +1 -1
- ccxt/coincatch.py +2 -2
- ccxt/coinex.py +67 -6
- ccxt/coinmate.py +1 -1
- ccxt/coinsph.py +1 -1
- ccxt/cryptocom.py +2 -2
- ccxt/defx.py +2 -2
- ccxt/delta.py +1 -1
- ccxt/deribit.py +1 -1
- ccxt/digifinex.py +2 -2
- ccxt/ellipx.py +1 -1
- ccxt/exmo.py +1 -1
- ccxt/foxbit.py +3 -3
- ccxt/gate.py +18 -4
- ccxt/gemini.py +1 -1
- ccxt/hashkey.py +2 -2
- ccxt/hibachi.py +2079 -0
- ccxt/hitbtc.py +2 -2
- ccxt/hollaex.py +1 -1
- ccxt/htx.py +4 -3
- ccxt/hyperliquid.py +71 -29
- ccxt/independentreserve.py +1 -1
- ccxt/indodax.py +1 -1
- ccxt/kraken.py +1 -1
- ccxt/krakenfutures.py +2 -1
- ccxt/kucoin.py +2 -2
- ccxt/kucoinfutures.py +2 -1
- ccxt/lbank.py +2 -2
- ccxt/mercado.py +1 -1
- ccxt/mexc.py +9 -2
- ccxt/modetrade.py +93 -2
- ccxt/ndax.py +1 -1
- ccxt/novadax.py +35 -1
- ccxt/okcoin.py +1 -1
- ccxt/okx.py +2 -2
- ccxt/onetrading.py +33 -0
- ccxt/oxfun.py +1 -1
- ccxt/p2b.py +32 -0
- ccxt/paradex.py +2 -1
- ccxt/phemex.py +2 -2
- ccxt/poloniex.py +2 -2
- ccxt/pro/__init__.py +1 -1
- ccxt/pro/alpaca.py +2 -2
- ccxt/pro/apex.py +2 -2
- ccxt/pro/ascendex.py +2 -2
- ccxt/pro/binance.py +4 -5
- ccxt/pro/bitget.py +3 -3
- ccxt/pro/bithumb.py +2 -2
- ccxt/pro/bitmart.py +2 -2
- ccxt/pro/bitmex.py +3 -3
- ccxt/pro/bitstamp.py +3 -3
- ccxt/pro/bittrade.py +2 -2
- ccxt/pro/bitvavo.py +5 -3
- ccxt/pro/bybit.py +5 -4
- ccxt/pro/cex.py +3 -2
- ccxt/pro/coinbaseexchange.py +4 -4
- ccxt/pro/coinbaseinternational.py +2 -2
- ccxt/pro/coincatch.py +1 -1
- ccxt/pro/coinex.py +1 -1
- ccxt/pro/coinone.py +2 -2
- ccxt/pro/cryptocom.py +2 -2
- ccxt/pro/derive.py +2 -2
- ccxt/pro/gate.py +3 -3
- ccxt/pro/hollaex.py +2 -2
- ccxt/pro/htx.py +3 -3
- ccxt/pro/hyperliquid.py +101 -14
- ccxt/pro/kraken.py +2 -2
- ccxt/pro/krakenfutures.py +4 -3
- ccxt/pro/kucoin.py +4 -3
- ccxt/pro/kucoinfutures.py +4 -3
- ccxt/pro/mexc.py +328 -139
- ccxt/pro/modetrade.py +2 -2
- ccxt/pro/okcoin.py +2 -2
- ccxt/pro/okx.py +7 -6
- ccxt/pro/onetrading.py +2 -2
- ccxt/pro/oxfun.py +1 -1
- ccxt/pro/p2b.py +2 -2
- ccxt/pro/paradex.py +2 -2
- ccxt/pro/poloniex.py +2 -2
- ccxt/pro/probit.py +2 -2
- ccxt/pro/vertex.py +2 -2
- ccxt/pro/whitebit.py +2 -2
- ccxt/pro/woo.py +2 -2
- ccxt/pro/woofipro.py +2 -2
- ccxt/probit.py +36 -1
- ccxt/protobuf/__init__.py +0 -0
- ccxt/protobuf/mexc/PrivateAccountV3Api_pb2.py +37 -0
- ccxt/protobuf/mexc/PrivateDealsV3Api_pb2.py +37 -0
- ccxt/protobuf/mexc/PrivateOrdersV3Api_pb2.py +37 -0
- ccxt/protobuf/mexc/PublicAggreBookTickerV3Api_pb2.py +37 -0
- ccxt/protobuf/mexc/PublicAggreDealsV3Api_pb2.py +39 -0
- ccxt/protobuf/mexc/PublicAggreDepthsV3Api_pb2.py +39 -0
- ccxt/protobuf/mexc/PublicBookTickerBatchV3Api_pb2.py +38 -0
- ccxt/protobuf/mexc/PublicBookTickerV3Api_pb2.py +37 -0
- ccxt/protobuf/mexc/PublicDealsV3Api_pb2.py +39 -0
- ccxt/protobuf/mexc/PublicIncreaseDepthsBatchV3Api_pb2.py +38 -0
- ccxt/protobuf/mexc/PublicIncreaseDepthsV3Api_pb2.py +39 -0
- ccxt/protobuf/mexc/PublicLimitDepthsV3Api_pb2.py +39 -0
- ccxt/protobuf/mexc/PublicMiniTickerV3Api_pb2.py +37 -0
- ccxt/protobuf/mexc/PublicMiniTickersV3Api_pb2.py +38 -0
- ccxt/protobuf/mexc/PublicSpotKlineV3Api_pb2.py +37 -0
- ccxt/protobuf/mexc/PushDataV3ApiWrapper_pb2.py +52 -0
- ccxt/protobuf/mexc/__init__.py +0 -0
- ccxt/test/tests_async.py +1 -1
- ccxt/test/tests_sync.py +1 -1
- ccxt/tokocrypto.py +1 -1
- ccxt/upbit.py +1 -1
- ccxt/vertex.py +1 -1
- ccxt/wavesexchange.py +1 -1
- ccxt/whitebit.py +2 -2
- ccxt/woo.py +4 -4
- ccxt/woofipro.py +93 -2
- ccxt/xt.py +2 -2
- ccxt/yobit.py +1 -1
- ccxt/zaif.py +1 -1
- ccxt/zonda.py +1 -1
- {ccxt-4.4.98.dist-info → ccxt-4.4.100.dist-info}/METADATA +8 -7
- {ccxt-4.4.98.dist-info → ccxt-4.4.100.dist-info}/RECORD +234 -213
- {ccxt-4.4.98.dist-info → ccxt-4.4.100.dist-info}/LICENSE.txt +0 -0
- {ccxt-4.4.98.dist-info → ccxt-4.4.100.dist-info}/WHEEL +0 -0
- {ccxt-4.4.98.dist-info → ccxt-4.4.100.dist-info}/top_level.txt +0 -0
ccxt/async_support/bithumb.py
CHANGED
@@ -1095,7 +1095,7 @@ class bithumb(Exchange, ImplicitAPI):
|
|
1095
1095
|
}
|
1096
1096
|
return await self.cancel_order(order['id'], order['symbol'], self.extend(request, params))
|
1097
1097
|
|
1098
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
1098
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1099
1099
|
"""
|
1100
1100
|
make a withdrawal
|
1101
1101
|
|
ccxt/async_support/bitmart.py
CHANGED
@@ -3606,7 +3606,7 @@ class bitmart(Exchange, ImplicitAPI):
|
|
3606
3606
|
'tag': self.safe_string_2(depositAddress, 'address_memo', 'memo'),
|
3607
3607
|
}
|
3608
3608
|
|
3609
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
3609
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
3610
3610
|
"""
|
3611
3611
|
make a withdrawal
|
3612
3612
|
|
@@ -4466,7 +4466,7 @@ class bitmart(Exchange, ImplicitAPI):
|
|
4466
4466
|
'info': interest,
|
4467
4467
|
}, market)
|
4468
4468
|
|
4469
|
-
async def set_leverage(self, leverage:
|
4469
|
+
async def set_leverage(self, leverage: int, symbol: Str = None, params={}):
|
4470
4470
|
"""
|
4471
4471
|
set the level of leverage for a market
|
4472
4472
|
|
ccxt/async_support/bitmex.py
CHANGED
@@ -2446,7 +2446,7 @@ class bitmex(Exchange, ImplicitAPI):
|
|
2446
2446
|
'takeProfitPrice': None,
|
2447
2447
|
})
|
2448
2448
|
|
2449
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
2449
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
2450
2450
|
"""
|
2451
2451
|
make a withdrawal
|
2452
2452
|
|
@@ -2625,7 +2625,7 @@ class bitmex(Exchange, ImplicitAPI):
|
|
2625
2625
|
'datetime': datetime,
|
2626
2626
|
}
|
2627
2627
|
|
2628
|
-
async def set_leverage(self, leverage:
|
2628
|
+
async def set_leverage(self, leverage: int, symbol: Str = None, params={}):
|
2629
2629
|
"""
|
2630
2630
|
set the level of leverage for a market
|
2631
2631
|
|
@@ -2883,6 +2883,7 @@ class bitmex(Exchange, ImplicitAPI):
|
|
2883
2883
|
'contracts': None,
|
2884
2884
|
'contractSize': self.safe_number(market, 'contractSize'),
|
2885
2885
|
'price': self.safe_number(liquidation, 'price'),
|
2886
|
+
'side': self.safe_string_lower(liquidation, 'side'),
|
2886
2887
|
'baseValue': None,
|
2887
2888
|
'quoteValue': None,
|
2888
2889
|
'timestamp': None,
|
ccxt/async_support/bitopro.py
CHANGED
@@ -1680,7 +1680,7 @@ class bitopro(Exchange, ImplicitAPI):
|
|
1680
1680
|
#
|
1681
1681
|
return self.parse_transaction(result, currency)
|
1682
1682
|
|
1683
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
1683
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1684
1684
|
"""
|
1685
1685
|
make a withdrawal
|
1686
1686
|
|
ccxt/async_support/bitrue.py
CHANGED
@@ -2749,7 +2749,7 @@ class bitrue(Exchange, ImplicitAPI):
|
|
2749
2749
|
'fee': fee,
|
2750
2750
|
}
|
2751
2751
|
|
2752
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
2752
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
2753
2753
|
"""
|
2754
2754
|
make a withdrawal
|
2755
2755
|
|
@@ -2975,7 +2975,7 @@ class bitrue(Exchange, ImplicitAPI):
|
|
2975
2975
|
data = self.safe_dict(response, 'data', {})
|
2976
2976
|
return self.parse_transfer(data, currency)
|
2977
2977
|
|
2978
|
-
async def set_leverage(self, leverage:
|
2978
|
+
async def set_leverage(self, leverage: int, symbol: Str = None, params={}):
|
2979
2979
|
"""
|
2980
2980
|
set the level of leverage for a market
|
2981
2981
|
|
ccxt/async_support/bitso.py
CHANGED
@@ -1630,7 +1630,7 @@ class bitso(Exchange, ImplicitAPI):
|
|
1630
1630
|
result[code]['info'][code] = withdrawFee
|
1631
1631
|
return result
|
1632
1632
|
|
1633
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
1633
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1634
1634
|
"""
|
1635
1635
|
make a withdrawal
|
1636
1636
|
:param str code: unified currency code
|
ccxt/async_support/bitstamp.py
CHANGED
@@ -2148,7 +2148,7 @@ class bitstamp(Exchange, ImplicitAPI):
|
|
2148
2148
|
'tag': tag,
|
2149
2149
|
}
|
2150
2150
|
|
2151
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
2151
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
2152
2152
|
"""
|
2153
2153
|
make a withdrawal
|
2154
2154
|
|
ccxt/async_support/bittrade.py
CHANGED
@@ -1824,7 +1824,7 @@ class bittrade(Exchange, ImplicitAPI):
|
|
1824
1824
|
}
|
1825
1825
|
return self.safe_string(statuses, status, status)
|
1826
1826
|
|
1827
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
1827
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1828
1828
|
"""
|
1829
1829
|
make a withdrawal
|
1830
1830
|
:param str code: unified currency code
|
ccxt/async_support/bitvavo.py
CHANGED
@@ -1788,7 +1788,7 @@ class bitvavo(Exchange, ImplicitAPI):
|
|
1788
1788
|
request['paymentId'] = tag
|
1789
1789
|
return self.extend(request, params)
|
1790
1790
|
|
1791
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
1791
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1792
1792
|
"""
|
1793
1793
|
make a withdrawal
|
1794
1794
|
:param str code: unified currency code
|
@@ -976,7 +976,7 @@ class blockchaincom(Exchange, ImplicitAPI):
|
|
976
976
|
'fee': fee,
|
977
977
|
}
|
978
978
|
|
979
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
979
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
980
980
|
"""
|
981
981
|
make a withdrawal
|
982
982
|
|
ccxt/async_support/blofin.py
CHANGED
@@ -2159,7 +2159,7 @@ class blofin(Exchange, ImplicitAPI):
|
|
2159
2159
|
'shortLeverage': leverageValue,
|
2160
2160
|
}
|
2161
2161
|
|
2162
|
-
async def set_leverage(self, leverage:
|
2162
|
+
async def set_leverage(self, leverage: int, symbol: Str = None, params={}):
|
2163
2163
|
"""
|
2164
2164
|
set the level of leverage for a market
|
2165
2165
|
|
ccxt/async_support/btcmarkets.py
CHANGED
@@ -1280,7 +1280,7 @@ class btcmarkets(Exchange, ImplicitAPI):
|
|
1280
1280
|
#
|
1281
1281
|
return self.parse_trades(response, market, since, limit)
|
1282
1282
|
|
1283
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
1283
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1284
1284
|
"""
|
1285
1285
|
make a withdrawal
|
1286
1286
|
|
ccxt/async_support/bybit.py
CHANGED
@@ -5842,7 +5842,7 @@ classic accounts only/ spot not supported* fetches information on an order made
|
|
5842
5842
|
}
|
5843
5843
|
return self.safe_string(types, type, type)
|
5844
5844
|
|
5845
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
5845
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
5846
5846
|
"""
|
5847
5847
|
make a withdrawal
|
5848
5848
|
|
@@ -5857,7 +5857,11 @@ classic accounts only/ spot not supported* fetches information on an order made
|
|
5857
5857
|
"""
|
5858
5858
|
tag, params = self.handle_withdraw_tag_and_params(tag, params)
|
5859
5859
|
accountType = None
|
5860
|
+
accounts = await self.is_unified_enabled()
|
5861
|
+
isUta = accounts[1]
|
5860
5862
|
accountType, params = self.handle_option_and_params(params, 'withdraw', 'accountType', 'SPOT')
|
5863
|
+
if isUta:
|
5864
|
+
accountType = 'UTA'
|
5861
5865
|
await self.load_markets()
|
5862
5866
|
self.check_address(address)
|
5863
5867
|
currency = self.currency(code)
|
@@ -6402,7 +6406,7 @@ classic accounts only/ spot not supported* fetches information on an order made
|
|
6402
6406
|
response = await self.privatePostV5PositionSwitchIsolated(self.extend(request, params))
|
6403
6407
|
return response
|
6404
6408
|
|
6405
|
-
async def set_leverage(self, leverage:
|
6409
|
+
async def set_leverage(self, leverage: int, symbol: Str = None, params={}):
|
6406
6410
|
"""
|
6407
6411
|
set the level of leverage for a market
|
6408
6412
|
|
@@ -7935,7 +7939,7 @@ classic accounts only/ spot not supported* fetches information on an order made
|
|
7935
7939
|
if market['spot']:
|
7936
7940
|
raise NotSupported(self.id + ' fetchLeverageTiers() is not supported for spot market')
|
7937
7941
|
symbol = market['symbol']
|
7938
|
-
data = await self.get_leverage_tiers_paginated(symbol, self.extend({'paginate': True, 'paginationCalls':
|
7942
|
+
data = await self.get_leverage_tiers_paginated(symbol, self.extend({'paginate': True, 'paginationCalls': 50}, params))
|
7939
7943
|
symbols = self.market_symbols(symbols)
|
7940
7944
|
return self.parse_leverage_tiers(data, symbols, 'symbol')
|
7941
7945
|
|
ccxt/async_support/coinbase.py
CHANGED
@@ -3901,7 +3901,7 @@ class coinbase(Exchange, ImplicitAPI):
|
|
3901
3901
|
tickers = self.safe_list(response, 'pricebooks', [])
|
3902
3902
|
return self.parse_tickers(tickers, symbols)
|
3903
3903
|
|
3904
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
3904
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
3905
3905
|
"""
|
3906
3906
|
make a withdrawal
|
3907
3907
|
|
@@ -1566,7 +1566,7 @@ class coinbaseexchange(Exchange, ImplicitAPI):
|
|
1566
1566
|
async def fetch_payment_methods(self, params={}):
|
1567
1567
|
return await self.privateGetPaymentMethods(params)
|
1568
1568
|
|
1569
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
1569
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1570
1570
|
"""
|
1571
1571
|
make a withdrawal
|
1572
1572
|
|
@@ -2127,7 +2127,7 @@ class coinbaseinternational(Exchange, ImplicitAPI):
|
|
2127
2127
|
trades = self.safe_list(response, 'results', [])
|
2128
2128
|
return self.parse_trades(trades, market, since, limit)
|
2129
2129
|
|
2130
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
2130
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
2131
2131
|
"""
|
2132
2132
|
make a withdrawal
|
2133
2133
|
|
ccxt/async_support/coincatch.py
CHANGED
@@ -2085,7 +2085,7 @@ class coincatch(Exchange, ImplicitAPI):
|
|
2085
2085
|
data = self.safe_list(response, 'data', [])
|
2086
2086
|
return self.parse_transactions(data, currency, since, limit)
|
2087
2087
|
|
2088
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
2088
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
2089
2089
|
"""
|
2090
2090
|
make a withdrawal
|
2091
2091
|
|
@@ -4447,7 +4447,7 @@ class coincatch(Exchange, ImplicitAPI):
|
|
4447
4447
|
data = self.safe_dict(response, 'data', {})
|
4448
4448
|
return self.parse_leverage(data, market)
|
4449
4449
|
|
4450
|
-
async def set_leverage(self, leverage:
|
4450
|
+
async def set_leverage(self, leverage: int, symbol: Str = None, params={}):
|
4451
4451
|
"""
|
4452
4452
|
set the level of leverage for a market
|
4453
4453
|
|
ccxt/async_support/coinex.py
CHANGED
@@ -87,7 +87,7 @@ class coinex(Exchange, ImplicitAPI):
|
|
87
87
|
'fetchDepositAddressesByNetwork': False,
|
88
88
|
'fetchDeposits': True,
|
89
89
|
'fetchDepositWithdrawFee': True,
|
90
|
-
'fetchDepositWithdrawFees':
|
90
|
+
'fetchDepositWithdrawFees': True,
|
91
91
|
'fetchFundingHistory': True,
|
92
92
|
'fetchFundingInterval': True,
|
93
93
|
'fetchFundingIntervals': False,
|
@@ -740,6 +740,7 @@ class coinex(Exchange, ImplicitAPI):
|
|
740
740
|
for j in range(0, len(chains)):
|
741
741
|
chain = chains[j]
|
742
742
|
networkId = self.safe_string(chain, 'chain')
|
743
|
+
networkCode = self.network_id_to_code(networkId, code)
|
743
744
|
if networkId is None:
|
744
745
|
continue
|
745
746
|
precisionString = self.parse_precision(self.safe_string(chain, 'withdrawal_precision'))
|
@@ -750,7 +751,7 @@ class coinex(Exchange, ImplicitAPI):
|
|
750
751
|
canWithdrawChain = self.safe_bool(chain, 'withdraw_enabled')
|
751
752
|
network: dict = {
|
752
753
|
'id': networkId,
|
753
|
-
'network':
|
754
|
+
'network': networkCode,
|
754
755
|
'name': None,
|
755
756
|
'active': canDepositChain and canWithdrawChain,
|
756
757
|
'deposit': canDepositChain,
|
@@ -773,7 +774,7 @@ class coinex(Exchange, ImplicitAPI):
|
|
773
774
|
},
|
774
775
|
'info': chain,
|
775
776
|
}
|
776
|
-
networks[
|
777
|
+
networks[networkCode] = network
|
777
778
|
result[code] = self.safe_currency_structure({
|
778
779
|
'id': currencyId,
|
779
780
|
'code': code,
|
@@ -4125,7 +4126,7 @@ class coinex(Exchange, ImplicitAPI):
|
|
4125
4126
|
# }
|
4126
4127
|
#
|
4127
4128
|
|
4128
|
-
async def set_leverage(self, leverage:
|
4129
|
+
async def set_leverage(self, leverage: int, symbol: Str = None, params={}):
|
4129
4130
|
"""
|
4130
4131
|
|
4131
4132
|
https://docs.coinex.com/api/v2/futures/position/http/adjust-position-leverage
|
@@ -4601,7 +4602,7 @@ class coinex(Exchange, ImplicitAPI):
|
|
4601
4602
|
data = self.safe_list(response, 'data', [])
|
4602
4603
|
return self.parse_funding_rates(data, symbols)
|
4603
4604
|
|
4604
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
4605
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
4605
4606
|
"""
|
4606
4607
|
make a withdrawal
|
4607
4608
|
|
@@ -4610,7 +4611,7 @@ class coinex(Exchange, ImplicitAPI):
|
|
4610
4611
|
:param str code: unified currency code
|
4611
4612
|
:param float amount: the amount to withdraw
|
4612
4613
|
:param str address: the address to withdraw to
|
4613
|
-
:param str tag:
|
4614
|
+
:param str [tag]: memo
|
4614
4615
|
:param dict [params]: extra parameters specific to the exchange API endpoint
|
4615
4616
|
:param str [params.network]: unified network code
|
4616
4617
|
:returns dict: a `transaction structure <https://docs.ccxt.com/#/?id=transaction-structure>`
|
@@ -5393,6 +5394,66 @@ class coinex(Exchange, ImplicitAPI):
|
|
5393
5394
|
data = self.safe_dict(response, 'data', {})
|
5394
5395
|
return self.parse_deposit_withdraw_fee(data, currency)
|
5395
5396
|
|
5397
|
+
async def fetch_deposit_withdraw_fees(self, codes: Strings = None, params={}):
|
5398
|
+
"""
|
5399
|
+
fetch the fees for deposits and withdrawals
|
5400
|
+
|
5401
|
+
https://docs.coinex.com/api/v2/assets/deposit-withdrawal/http/list-all-deposit-withdrawal-config
|
5402
|
+
|
5403
|
+
@param codes
|
5404
|
+
:param dict [params]: extra parameters specific to the exchange API endpoint
|
5405
|
+
:returns dict: a dictionary of `fee structures <https://docs.ccxt.com/#/?id=fee-structure>`
|
5406
|
+
"""
|
5407
|
+
await self.load_markets()
|
5408
|
+
response = await self.v2PublicGetAssetsAllDepositWithdrawConfig(params)
|
5409
|
+
#
|
5410
|
+
# {
|
5411
|
+
# "code": 0,
|
5412
|
+
# "data": [
|
5413
|
+
# {
|
5414
|
+
# "asset": {
|
5415
|
+
# "ccy": "CET",
|
5416
|
+
# "deposit_enabled": True,
|
5417
|
+
# "withdraw_enabled": True,
|
5418
|
+
# "inter_transfer_enabled": True,
|
5419
|
+
# "is_st": False
|
5420
|
+
# },
|
5421
|
+
# "chains": [
|
5422
|
+
# {
|
5423
|
+
# "chain": "CSC",
|
5424
|
+
# "min_deposit_amount": "0.8",
|
5425
|
+
# "min_withdraw_amount": "8",
|
5426
|
+
# "deposit_enabled": True,
|
5427
|
+
# "withdraw_enabled": True,
|
5428
|
+
# "deposit_delay_minutes": 0,
|
5429
|
+
# "safe_confirmations": 10,
|
5430
|
+
# "irreversible_confirmations": 20,
|
5431
|
+
# "deflation_rate": "0",
|
5432
|
+
# "withdrawal_fee": "0.026",
|
5433
|
+
# "withdrawal_precision": 8,
|
5434
|
+
# "memo": "",
|
5435
|
+
# "is_memo_required_for_deposit": False,
|
5436
|
+
# "explorer_asset_url": ""
|
5437
|
+
# },
|
5438
|
+
# ]
|
5439
|
+
# }
|
5440
|
+
# ],
|
5441
|
+
# "message": "OK"
|
5442
|
+
# }
|
5443
|
+
#
|
5444
|
+
data = self.safe_list(response, 'data', [])
|
5445
|
+
result: dict = {}
|
5446
|
+
for i in range(0, len(data)):
|
5447
|
+
item = data[i]
|
5448
|
+
asset = self.safe_dict(item, 'asset', {})
|
5449
|
+
currencyId = self.safe_string(asset, 'ccy')
|
5450
|
+
if currencyId is None:
|
5451
|
+
continue
|
5452
|
+
code = self.safe_currency_code(currencyId)
|
5453
|
+
if codes is None or self.in_array(code, codes):
|
5454
|
+
result[code] = self.parse_deposit_withdraw_fee(item)
|
5455
|
+
return result
|
5456
|
+
|
5396
5457
|
def parse_deposit_withdraw_fee(self, fee, currency: Currency = None):
|
5397
5458
|
#
|
5398
5459
|
# {
|
ccxt/async_support/coinmate.py
CHANGED
@@ -700,7 +700,7 @@ class coinmate(Exchange, ImplicitAPI):
|
|
700
700
|
},
|
701
701
|
}
|
702
702
|
|
703
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
703
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
704
704
|
"""
|
705
705
|
make a withdrawal
|
706
706
|
|
ccxt/async_support/coinsph.py
CHANGED
@@ -1768,7 +1768,7 @@ class coinsph(Exchange, ImplicitAPI):
|
|
1768
1768
|
'tierBased': None,
|
1769
1769
|
}
|
1770
1770
|
|
1771
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
1771
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1772
1772
|
"""
|
1773
1773
|
make a withdrawal to coins_ph account
|
1774
1774
|
|
ccxt/async_support/cryptocom.py
CHANGED
@@ -1134,7 +1134,7 @@ class cryptocom(Exchange, ImplicitAPI):
|
|
1134
1134
|
'instrument_name': market['id'],
|
1135
1135
|
}
|
1136
1136
|
if limit:
|
1137
|
-
request['depth'] = limit
|
1137
|
+
request['depth'] = min(limit, 50) # max 50
|
1138
1138
|
response = await self.v1PublicGetPublicGetBook(self.extend(request, params))
|
1139
1139
|
#
|
1140
1140
|
# {
|
@@ -1869,7 +1869,7 @@ class cryptocom(Exchange, ImplicitAPI):
|
|
1869
1869
|
address = addressString
|
1870
1870
|
return [address, tag]
|
1871
1871
|
|
1872
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
1872
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1873
1873
|
"""
|
1874
1874
|
make a withdrawal
|
1875
1875
|
|
ccxt/async_support/defx.py
CHANGED
@@ -1894,7 +1894,7 @@ class defx(Exchange, ImplicitAPI):
|
|
1894
1894
|
}
|
1895
1895
|
return self.safe_string(ledgerType, type, type)
|
1896
1896
|
|
1897
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}):
|
1897
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1898
1898
|
"""
|
1899
1899
|
make a withdrawal
|
1900
1900
|
|
@@ -1955,7 +1955,7 @@ class defx(Exchange, ImplicitAPI):
|
|
1955
1955
|
'fee': None,
|
1956
1956
|
}
|
1957
1957
|
|
1958
|
-
async def set_leverage(self, leverage:
|
1958
|
+
async def set_leverage(self, leverage: int, symbol: Str = None, params={}):
|
1959
1959
|
"""
|
1960
1960
|
set the level of leverage for a market
|
1961
1961
|
|
ccxt/async_support/delta.py
CHANGED
@@ -2938,7 +2938,7 @@ class delta(Exchange, ImplicitAPI):
|
|
2938
2938
|
'shortLeverage': leverageValue,
|
2939
2939
|
}
|
2940
2940
|
|
2941
|
-
async def set_leverage(self, leverage:
|
2941
|
+
async def set_leverage(self, leverage: int, symbol: Str = None, params={}):
|
2942
2942
|
"""
|
2943
2943
|
set the level of leverage for a market
|
2944
2944
|
|
ccxt/async_support/deribit.py
CHANGED
@@ -2936,7 +2936,7 @@ class deribit(Exchange, ImplicitAPI):
|
|
2936
2936
|
}
|
2937
2937
|
return self.safe_string(statuses, status, status)
|
2938
2938
|
|
2939
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
2939
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
2940
2940
|
"""
|
2941
2941
|
make a withdrawal
|
2942
2942
|
|
ccxt/async_support/digifinex.py
CHANGED
@@ -2913,7 +2913,7 @@ class digifinex(Exchange, ImplicitAPI):
|
|
2913
2913
|
response = await self.privateSpotPostTransfer(self.extend(request, params))
|
2914
2914
|
return self.parse_transfer(response, currency)
|
2915
2915
|
|
2916
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
2916
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
2917
2917
|
"""
|
2918
2918
|
make a withdrawal
|
2919
2919
|
:param str code: unified currency code
|
@@ -3586,7 +3586,7 @@ class digifinex(Exchange, ImplicitAPI):
|
|
3586
3586
|
'takeProfitPrice': None,
|
3587
3587
|
})
|
3588
3588
|
|
3589
|
-
async def set_leverage(self, leverage:
|
3589
|
+
async def set_leverage(self, leverage: int, symbol: Str = None, params={}):
|
3590
3590
|
"""
|
3591
3591
|
set the level of leverage for a market
|
3592
3592
|
|
ccxt/async_support/ellipx.py
CHANGED
@@ -1810,7 +1810,7 @@ class ellipx(Exchange, ImplicitAPI):
|
|
1810
1810
|
'tierBased': True, # fees can vary based on volume tiers
|
1811
1811
|
}
|
1812
1812
|
|
1813
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
1813
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1814
1814
|
"""
|
1815
1815
|
Make a withdrawal request
|
1816
1816
|
|
ccxt/async_support/exmo.py
CHANGED
@@ -2186,7 +2186,7 @@ class exmo(Exchange, ImplicitAPI):
|
|
2186
2186
|
return self.markets[symbols[0]]
|
2187
2187
|
return None
|
2188
2188
|
|
2189
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
2189
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
2190
2190
|
"""
|
2191
2191
|
make a withdrawal
|
2192
2192
|
|
ccxt/async_support/foxbit.py
CHANGED
@@ -95,7 +95,7 @@ class foxbit(Exchange, ImplicitAPI):
|
|
95
95
|
'1M': '1M',
|
96
96
|
},
|
97
97
|
'urls': {
|
98
|
-
'logo': 'https://github.com/user-attachments/assets/
|
98
|
+
'logo': 'https://github.com/user-attachments/assets/1f8faca2-ae2f-4222-b33e-5671e7d873dd',
|
99
99
|
'api': {
|
100
100
|
'public': 'https://api.foxbit.com.br',
|
101
101
|
'private': 'https://api.foxbit.com.br',
|
@@ -1460,7 +1460,7 @@ class foxbit(Exchange, ImplicitAPI):
|
|
1460
1460
|
# }
|
1461
1461
|
return self.parse_order(response['create'], market)
|
1462
1462
|
|
1463
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}):
|
1463
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1464
1464
|
"""
|
1465
1465
|
Make a withdrawal.
|
1466
1466
|
|
@@ -1628,7 +1628,7 @@ class foxbit(Exchange, ImplicitAPI):
|
|
1628
1628
|
'percentage': self.safe_string(rolling_24h, 'price_change_percent'),
|
1629
1629
|
'average': None,
|
1630
1630
|
'baseVolume': self.safe_string(rolling_24h, 'volume'),
|
1631
|
-
'quoteVolume':
|
1631
|
+
'quoteVolume': self.safe_string(rolling_24h, 'quote_volume'),
|
1632
1632
|
'info': ticker,
|
1633
1633
|
}, market)
|
1634
1634
|
|
ccxt/async_support/gate.py
CHANGED
@@ -685,8 +685,7 @@ class gate(Exchange, ImplicitAPI):
|
|
685
685
|
'BSC': 'BSC',
|
686
686
|
'BEP20': 'BSC',
|
687
687
|
'SOL': 'SOL',
|
688
|
-
'
|
689
|
-
'MATIC': 'POL',
|
688
|
+
'MATIC': 'MATIC',
|
690
689
|
'OPTIMISM': 'OPETH',
|
691
690
|
'ADA': 'ADA', # CARDANO
|
692
691
|
'AVAXC': 'AVAX_C',
|
@@ -3792,7 +3791,7 @@ class gate(Exchange, ImplicitAPI):
|
|
3792
3791
|
response = await self.privateWalletGetWithdrawals(self.extend(request, params))
|
3793
3792
|
return self.parse_transactions(response, currency)
|
3794
3793
|
|
3795
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
3794
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
3796
3795
|
"""
|
3797
3796
|
make a withdrawal
|
3798
3797
|
|
@@ -5460,7 +5459,7 @@ class gate(Exchange, ImplicitAPI):
|
|
5460
5459
|
'info': transfer,
|
5461
5460
|
}
|
5462
5461
|
|
5463
|
-
async def set_leverage(self, leverage:
|
5462
|
+
async def set_leverage(self, leverage: int, symbol: Str = None, params={}):
|
5464
5463
|
"""
|
5465
5464
|
set the level of leverage for a market
|
5466
5465
|
|
@@ -7213,12 +7212,27 @@ class gate(Exchange, ImplicitAPI):
|
|
7213
7212
|
quoteValueString = self.safe_string(liquidation, 'pnl')
|
7214
7213
|
if quoteValueString is None:
|
7215
7214
|
quoteValueString = Precise.string_mul(baseValueString, priceString)
|
7215
|
+
# --- derive side ---
|
7216
|
+
# 1) options payload has explicit 'side': 'long' | 'short'
|
7217
|
+
optPos = self.safe_string_lower(liquidation, 'side')
|
7218
|
+
side: Str = None
|
7219
|
+
if optPos == 'long':
|
7220
|
+
side = 'buy'
|
7221
|
+
elif optPos == 'short':
|
7222
|
+
side = 'sell'
|
7223
|
+
else:
|
7224
|
+
if size is not None: # 2) futures/perpetual(and fallback for options): infer from size
|
7225
|
+
if Precise.string_gt(size, '0'):
|
7226
|
+
side = 'buy'
|
7227
|
+
elif Precise.string_lt(size, '0'):
|
7228
|
+
side = 'sell'
|
7216
7229
|
return self.safe_liquidation({
|
7217
7230
|
'info': liquidation,
|
7218
7231
|
'symbol': self.safe_symbol(marketId, market),
|
7219
7232
|
'contracts': self.parse_number(contractsString),
|
7220
7233
|
'contractSize': self.parse_number(contractSizeString),
|
7221
7234
|
'price': self.parse_number(priceString),
|
7235
|
+
'side': side,
|
7222
7236
|
'baseValue': self.parse_number(baseValueString),
|
7223
7237
|
'quoteValue': self.parse_number(Precise.string_abs(quoteValueString)),
|
7224
7238
|
'timestamp': timestamp,
|
ccxt/async_support/gemini.py
CHANGED
@@ -1616,7 +1616,7 @@ class gemini(Exchange, ImplicitAPI):
|
|
1616
1616
|
response = await self.privatePostV1Mytrades(self.extend(request, params))
|
1617
1617
|
return self.parse_trades(response, market, since, limit)
|
1618
1618
|
|
1619
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
1619
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
1620
1620
|
"""
|
1621
1621
|
make a withdrawal
|
1622
1622
|
|
ccxt/async_support/hashkey.py
CHANGED
@@ -1999,7 +1999,7 @@ class hashkey(Exchange, ImplicitAPI):
|
|
1999
1999
|
#
|
2000
2000
|
return self.parse_transactions(response, currency, since, limit, {'type': 'withdrawal'})
|
2001
2001
|
|
2002
|
-
async def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
|
2002
|
+
async def withdraw(self, code: str, amount: float, address: str, tag: Str = None, params={}) -> Transaction:
|
2003
2003
|
"""
|
2004
2004
|
make a withdrawal
|
2005
2005
|
|
@@ -3877,7 +3877,7 @@ class hashkey(Exchange, ImplicitAPI):
|
|
3877
3877
|
'shortLeverage': leverageValue,
|
3878
3878
|
}
|
3879
3879
|
|
3880
|
-
async def set_leverage(self, leverage:
|
3880
|
+
async def set_leverage(self, leverage: int, symbol: Str = None, params={}):
|
3881
3881
|
"""
|
3882
3882
|
set the level of leverage for a market
|
3883
3883
|
|