ccxt 4.2.31__py2.py3-none-any.whl → 4.2.34__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.

Potentially problematic release.


This version of ccxt might be problematic. Click here for more details.

Files changed (242) hide show
  1. ccxt/__init__.py +1 -1
  2. ccxt/ace.py +4 -3
  3. ccxt/alpaca.py +1 -1
  4. ccxt/ascendex.py +6 -6
  5. ccxt/async_support/__init__.py +1 -1
  6. ccxt/async_support/ace.py +4 -3
  7. ccxt/async_support/alpaca.py +1 -1
  8. ccxt/async_support/ascendex.py +6 -6
  9. ccxt/async_support/base/exchange.py +62 -39
  10. ccxt/async_support/bigone.py +25 -5
  11. ccxt/async_support/binance.py +16 -15
  12. ccxt/async_support/bingx.py +10 -9
  13. ccxt/async_support/bit2c.py +13 -1
  14. ccxt/async_support/bitbank.py +2 -2
  15. ccxt/async_support/bitbns.py +1 -1
  16. ccxt/async_support/bitfinex.py +5 -5
  17. ccxt/async_support/bitfinex2.py +6 -6
  18. ccxt/async_support/bitflyer.py +5 -5
  19. ccxt/async_support/bitforex.py +1 -1
  20. ccxt/async_support/bitget.py +11 -11
  21. ccxt/async_support/bithumb.py +2 -2
  22. ccxt/async_support/bitmart.py +9 -9
  23. ccxt/async_support/bitmex.py +3 -3
  24. ccxt/async_support/bitopro.py +2 -2
  25. ccxt/async_support/bitrue.py +8 -8
  26. ccxt/async_support/bitso.py +4 -4
  27. ccxt/async_support/bitstamp.py +2 -2
  28. ccxt/async_support/bitteam.py +1 -1
  29. ccxt/async_support/bitvavo.py +3 -3
  30. ccxt/async_support/bl3p.py +1 -1
  31. ccxt/async_support/blockchaincom.py +3 -3
  32. ccxt/async_support/btcalpha.py +1 -1
  33. ccxt/async_support/btcbox.py +1 -1
  34. ccxt/async_support/btcmarkets.py +2 -2
  35. ccxt/async_support/btcturk.py +1 -1
  36. ccxt/async_support/bybit.py +9 -9
  37. ccxt/async_support/cex.py +1 -1
  38. ccxt/async_support/coinbase.py +6 -6
  39. ccxt/async_support/coinbasepro.py +2 -2
  40. ccxt/async_support/coincheck.py +1 -1
  41. ccxt/async_support/coinex.py +9 -9
  42. ccxt/async_support/coinlist.py +4 -4
  43. ccxt/async_support/coinmate.py +2 -2
  44. ccxt/async_support/coinmetro.py +2 -2
  45. ccxt/async_support/coinone.py +1 -1
  46. ccxt/async_support/coinsph.py +2 -2
  47. ccxt/async_support/coinspot.py +1 -1
  48. ccxt/async_support/cryptocom.py +14 -14
  49. ccxt/async_support/currencycom.py +1 -1
  50. ccxt/async_support/delta.py +2 -2
  51. ccxt/async_support/deribit.py +4 -4
  52. ccxt/async_support/digifinex.py +6 -6
  53. ccxt/async_support/exmo.py +2 -2
  54. ccxt/async_support/gate.py +41 -37
  55. ccxt/async_support/gemini.py +2 -2
  56. ccxt/async_support/hitbtc.py +5 -5
  57. ccxt/async_support/hollaex.py +2 -2
  58. ccxt/async_support/htx.py +10 -10
  59. ccxt/async_support/huobijp.py +4 -4
  60. ccxt/async_support/idex.py +2 -2
  61. ccxt/async_support/independentreserve.py +2 -2
  62. ccxt/async_support/indodax.py +2 -2
  63. ccxt/async_support/kraken.py +42 -4
  64. ccxt/async_support/krakenfutures.py +5 -5
  65. ccxt/async_support/kucoin.py +8 -8
  66. ccxt/async_support/kucoinfutures.py +4 -4
  67. ccxt/async_support/kuna.py +2 -2
  68. ccxt/async_support/latoken.py +3 -3
  69. ccxt/async_support/lbank.py +2 -2
  70. ccxt/async_support/luno.py +1 -1
  71. ccxt/async_support/lykke.py +2 -2
  72. ccxt/async_support/mercado.py +2 -2
  73. ccxt/async_support/mexc.py +7 -6
  74. ccxt/async_support/ndax.py +2 -2
  75. ccxt/async_support/novadax.py +4 -4
  76. ccxt/async_support/oceanex.py +1 -1
  77. ccxt/async_support/okcoin.py +5 -5
  78. ccxt/async_support/okx.py +11 -10
  79. ccxt/async_support/onetrading.py +2 -2
  80. ccxt/async_support/p2b.py +1 -1
  81. ccxt/async_support/paymium.py +3 -3
  82. ccxt/async_support/phemex.py +13 -13
  83. ccxt/async_support/poloniex.py +4 -4
  84. ccxt/async_support/poloniexfutures.py +1 -1
  85. ccxt/async_support/probit.py +5 -5
  86. ccxt/async_support/timex.py +1 -1
  87. ccxt/async_support/tokocrypto.py +4 -4
  88. ccxt/async_support/upbit.py +2 -2
  89. ccxt/async_support/wavesexchange.py +4 -3
  90. ccxt/async_support/wazirx.py +1 -1
  91. ccxt/async_support/whitebit.py +5 -5
  92. ccxt/async_support/woo.py +6 -6
  93. ccxt/async_support/yobit.py +41 -2
  94. ccxt/async_support/zaif.py +2 -2
  95. ccxt/async_support/zonda.py +4 -4
  96. ccxt/base/exchange.py +67 -40
  97. ccxt/base/types.py +10 -0
  98. ccxt/bigone.py +25 -5
  99. ccxt/binance.py +16 -15
  100. ccxt/bingx.py +10 -9
  101. ccxt/bit2c.py +13 -1
  102. ccxt/bitbank.py +2 -2
  103. ccxt/bitbns.py +1 -1
  104. ccxt/bitfinex.py +5 -5
  105. ccxt/bitfinex2.py +6 -6
  106. ccxt/bitflyer.py +5 -5
  107. ccxt/bitforex.py +1 -1
  108. ccxt/bitget.py +11 -11
  109. ccxt/bithumb.py +2 -2
  110. ccxt/bitmart.py +9 -9
  111. ccxt/bitmex.py +3 -3
  112. ccxt/bitopro.py +2 -2
  113. ccxt/bitrue.py +8 -8
  114. ccxt/bitso.py +4 -4
  115. ccxt/bitstamp.py +2 -2
  116. ccxt/bitteam.py +1 -1
  117. ccxt/bitvavo.py +3 -3
  118. ccxt/bl3p.py +1 -1
  119. ccxt/blockchaincom.py +3 -3
  120. ccxt/btcalpha.py +1 -1
  121. ccxt/btcbox.py +1 -1
  122. ccxt/btcmarkets.py +2 -2
  123. ccxt/btcturk.py +1 -1
  124. ccxt/bybit.py +9 -9
  125. ccxt/cex.py +1 -1
  126. ccxt/coinbase.py +6 -6
  127. ccxt/coinbasepro.py +2 -2
  128. ccxt/coincheck.py +1 -1
  129. ccxt/coinex.py +9 -9
  130. ccxt/coinlist.py +4 -4
  131. ccxt/coinmate.py +2 -2
  132. ccxt/coinmetro.py +2 -2
  133. ccxt/coinone.py +1 -1
  134. ccxt/coinsph.py +2 -2
  135. ccxt/coinspot.py +1 -1
  136. ccxt/cryptocom.py +14 -14
  137. ccxt/currencycom.py +1 -1
  138. ccxt/delta.py +2 -2
  139. ccxt/deribit.py +4 -4
  140. ccxt/digifinex.py +6 -6
  141. ccxt/exmo.py +2 -2
  142. ccxt/gate.py +41 -37
  143. ccxt/gemini.py +2 -2
  144. ccxt/hitbtc.py +5 -5
  145. ccxt/hollaex.py +2 -2
  146. ccxt/htx.py +10 -10
  147. ccxt/huobijp.py +4 -4
  148. ccxt/idex.py +2 -2
  149. ccxt/independentreserve.py +2 -2
  150. ccxt/indodax.py +2 -2
  151. ccxt/kraken.py +42 -4
  152. ccxt/krakenfutures.py +5 -5
  153. ccxt/kucoin.py +8 -8
  154. ccxt/kucoinfutures.py +4 -4
  155. ccxt/kuna.py +2 -2
  156. ccxt/latoken.py +3 -3
  157. ccxt/lbank.py +2 -2
  158. ccxt/luno.py +1 -1
  159. ccxt/lykke.py +2 -2
  160. ccxt/mercado.py +2 -2
  161. ccxt/mexc.py +7 -6
  162. ccxt/ndax.py +2 -2
  163. ccxt/novadax.py +4 -4
  164. ccxt/oceanex.py +1 -1
  165. ccxt/okcoin.py +5 -5
  166. ccxt/okx.py +11 -10
  167. ccxt/onetrading.py +2 -2
  168. ccxt/p2b.py +1 -1
  169. ccxt/paymium.py +3 -3
  170. ccxt/phemex.py +13 -13
  171. ccxt/poloniex.py +4 -4
  172. ccxt/poloniexfutures.py +1 -1
  173. ccxt/pro/__init__.py +1 -1
  174. ccxt/pro/alpaca.py +8 -4
  175. ccxt/pro/ascendex.py +1 -2
  176. ccxt/pro/binance.py +14 -10
  177. ccxt/pro/bingx.py +1 -1
  178. ccxt/pro/bitfinex.py +21 -22
  179. ccxt/pro/bitfinex2.py +13 -15
  180. ccxt/pro/bitget.py +3 -1
  181. ccxt/pro/bitmart.py +3 -7
  182. ccxt/pro/bitmex.py +4 -6
  183. ccxt/pro/bitopro.py +2 -4
  184. ccxt/pro/bitrue.py +1 -1
  185. ccxt/pro/bitstamp.py +2 -3
  186. ccxt/pro/bitvavo.py +10 -5
  187. ccxt/pro/blockchaincom.py +22 -22
  188. ccxt/pro/bybit.py +5 -5
  189. ccxt/pro/cex.py +7 -7
  190. ccxt/pro/coinbase.py +3 -2
  191. ccxt/pro/coinbasepro.py +1 -1
  192. ccxt/pro/coinex.py +15 -13
  193. ccxt/pro/currencycom.py +5 -6
  194. ccxt/pro/deribit.py +4 -4
  195. ccxt/pro/exmo.py +15 -13
  196. ccxt/pro/gate.py +1 -1
  197. ccxt/pro/gemini.py +4 -2
  198. ccxt/pro/hitbtc.py +10 -9
  199. ccxt/pro/hollaex.py +2 -2
  200. ccxt/pro/htx.py +6 -6
  201. ccxt/pro/huobijp.py +3 -4
  202. ccxt/pro/idex.py +1 -1
  203. ccxt/pro/independentreserve.py +14 -13
  204. ccxt/pro/kraken.py +10 -14
  205. ccxt/pro/krakenfutures.py +10 -6
  206. ccxt/pro/kucoin.py +10 -10
  207. ccxt/pro/kucoinfutures.py +11 -10
  208. ccxt/pro/lbank.py +10 -10
  209. ccxt/pro/luno.py +12 -14
  210. ccxt/pro/mexc.py +3 -2
  211. ccxt/pro/ndax.py +7 -11
  212. ccxt/pro/okcoin.py +7 -10
  213. ccxt/pro/okx.py +6 -9
  214. ccxt/pro/onetrading.py +16 -15
  215. ccxt/pro/p2b.py +5 -3
  216. ccxt/pro/phemex.py +16 -11
  217. ccxt/pro/poloniex.py +6 -4
  218. ccxt/pro/poloniexfutures.py +13 -9
  219. ccxt/pro/probit.py +15 -12
  220. ccxt/pro/upbit.py +8 -8
  221. ccxt/pro/wazirx.py +6 -3
  222. ccxt/pro/woo.py +9 -7
  223. ccxt/probit.py +5 -5
  224. ccxt/test/base/test_order_book.py +7 -7
  225. ccxt/test/base/test_shared_methods.py +1 -1
  226. ccxt/test/test_async.py +86 -36
  227. ccxt/test/test_sync.py +86 -36
  228. ccxt/timex.py +1 -1
  229. ccxt/tokocrypto.py +4 -4
  230. ccxt/upbit.py +2 -2
  231. ccxt/wavesexchange.py +4 -3
  232. ccxt/wazirx.py +1 -1
  233. ccxt/whitebit.py +5 -5
  234. ccxt/woo.py +6 -6
  235. ccxt/yobit.py +41 -2
  236. ccxt/zaif.py +2 -2
  237. ccxt/zonda.py +4 -4
  238. {ccxt-4.2.31.dist-info → ccxt-4.2.34.dist-info}/METADATA +9 -8
  239. ccxt-4.2.34.dist-info/RECORD +438 -0
  240. ccxt-4.2.31.dist-info/RECORD +0 -438
  241. {ccxt-4.2.31.dist-info → ccxt-4.2.34.dist-info}/WHEEL +0 -0
  242. {ccxt-4.2.31.dist-info → ccxt-4.2.34.dist-info}/top_level.txt +0 -0
@@ -5,7 +5,7 @@
5
5
 
6
6
  from ccxt.async_support.kucoin import kucoin
7
7
  from ccxt.abstract.kucoinfutures import ImplicitAPI
8
- from ccxt.base.types import Balances, Currency, Int, Market, Order, OrderBook, OrderRequest, OrderSide, OrderType, Str, Strings, Ticker, Trade, Transaction
8
+ from ccxt.base.types import Balances, Currency, Int, Market, Order, TransferEntry, OrderBook, OrderRequest, OrderSide, OrderType, Str, Strings, Ticker, Trade, Transaction
9
9
  from typing import List
10
10
  from ccxt.base.errors import PermissionDenied
11
11
  from ccxt.base.errors import AccountSuspended
@@ -1060,7 +1060,7 @@ class kucoinfutures(kucoin, ImplicitAPI):
1060
1060
  'takeProfitPrice': None,
1061
1061
  })
1062
1062
 
1063
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
1063
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
1064
1064
  """
1065
1065
  Create an order on the exchange
1066
1066
  :see: https://docs.kucoin.com/futures/#place-an-order
@@ -1154,7 +1154,7 @@ class kucoinfutures(kucoin, ImplicitAPI):
1154
1154
  data = self.safe_value(response, 'data', [])
1155
1155
  return self.parse_orders(data)
1156
1156
 
1157
- def create_contract_order_request(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
1157
+ def create_contract_order_request(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
1158
1158
  market = self.market(symbol)
1159
1159
  # required param, cannot be used twice
1160
1160
  clientOrderId = self.safe_string_2(params, 'clientOid', 'clientOrderId', self.uuid())
@@ -1842,7 +1842,7 @@ class kucoinfutures(kucoin, ImplicitAPI):
1842
1842
  #
1843
1843
  return self.parse_balance(response)
1844
1844
 
1845
- async def transfer(self, code: str, amount, fromAccount, toAccount, params={}):
1845
+ async def transfer(self, code: str, amount: float, fromAccount, toAccount, params={}) -> TransferEntry:
1846
1846
  """
1847
1847
  transfer currency internally between wallets on the same account
1848
1848
  :param str code: unified currency code
@@ -913,7 +913,7 @@ class kuna(Exchange, ImplicitAPI):
913
913
  data = self.safe_value(response, 'data', [])
914
914
  return self.parse_balance(data)
915
915
 
916
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
916
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
917
917
  """
918
918
  create a trade order
919
919
  :see: https://docs.kuna.io/docs/create-a-new-order-private
@@ -1337,7 +1337,7 @@ class kuna(Exchange, ImplicitAPI):
1337
1337
  data = self.safe_value(response, 'data')
1338
1338
  return self.parse_trades(data, market, since, limit)
1339
1339
 
1340
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
1340
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}):
1341
1341
  """
1342
1342
  make a withdrawal
1343
1343
  :see: https://docs.kuna.io/docs/create-a-withdraw
@@ -6,7 +6,7 @@
6
6
  from ccxt.async_support.base.exchange import Exchange
7
7
  from ccxt.abstract.latoken import ImplicitAPI
8
8
  import hashlib
9
- from ccxt.base.types import Balances, Currency, Int, Market, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
9
+ from ccxt.base.types import Balances, Currency, Int, Market, Order, TransferEntry, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
10
10
  from typing import List
11
11
  from ccxt.base.errors import ExchangeError
12
12
  from ccxt.base.errors import PermissionDenied
@@ -1192,7 +1192,7 @@ class latoken(Exchange, ImplicitAPI):
1192
1192
  #
1193
1193
  return self.parse_order(response)
1194
1194
 
1195
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
1195
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
1196
1196
  """
1197
1197
  create a trade order
1198
1198
  :see: https://api.latoken.com/doc/v2/#tag/Order/operation/placeOrder
@@ -1493,7 +1493,7 @@ class latoken(Exchange, ImplicitAPI):
1493
1493
  transfers = self.safe_value(response, 'content', [])
1494
1494
  return self.parse_transfers(transfers, currency, since, limit)
1495
1495
 
1496
- async def transfer(self, code: str, amount, fromAccount, toAccount, params={}):
1496
+ async def transfer(self, code: str, amount: float, fromAccount, toAccount, params={}) -> TransferEntry:
1497
1497
  """
1498
1498
  transfer currency internally between wallets on the same account
1499
1499
  :param str code: unified currency code
@@ -1245,7 +1245,7 @@ class lbank(Exchange, ImplicitAPI):
1245
1245
  params['createMarketBuyOrderRequiresPrice'] = False
1246
1246
  return await self.create_order(symbol, 'market', 'buy', cost, None, params)
1247
1247
 
1248
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
1248
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
1249
1249
  """
1250
1250
  create a trade order
1251
1251
  :see: https://www.lbank.com/en-US/docs/index.html#place-order
@@ -1905,7 +1905,7 @@ class lbank(Exchange, ImplicitAPI):
1905
1905
  'info': response,
1906
1906
  }
1907
1907
 
1908
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
1908
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}) -> Transaction:
1909
1909
  """
1910
1910
  make a withdrawal
1911
1911
  :see: https://www.lbank.com/en-US/docs/index.html#withdrawal
@@ -826,7 +826,7 @@ class luno(Exchange, ImplicitAPI):
826
826
  'taker': self.safe_number(response, 'taker_fee'),
827
827
  }
828
828
 
829
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
829
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
830
830
  """
831
831
  create a trade order
832
832
  :param str symbol: unified symbol of the market to create an order in
@@ -755,7 +755,7 @@ class lykke(Exchange, ImplicitAPI):
755
755
  'trades': None,
756
756
  }, market)
757
757
 
758
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
758
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
759
759
  """
760
760
  create a trade order
761
761
  :param str symbol: unified symbol of the market to create an order in
@@ -1174,7 +1174,7 @@ class lykke(Exchange, ImplicitAPI):
1174
1174
  currency = self.currency(code)
1175
1175
  return self.parse_transactions(payload, currency, since, limit)
1176
1176
 
1177
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
1177
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}):
1178
1178
  """
1179
1179
  make a withdrawal
1180
1180
  :param str code: unified currency code
@@ -412,7 +412,7 @@ class mercado(Exchange, ImplicitAPI):
412
412
  response = await self.privatePostGetAccountInfo(params)
413
413
  return self.parse_balance(response)
414
414
 
415
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
415
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
416
416
  """
417
417
  create a trade order
418
418
  :param str symbol: unified symbol of the market to create an order in
@@ -591,7 +591,7 @@ class mercado(Exchange, ImplicitAPI):
591
591
  order = self.safe_value(responseData, 'order')
592
592
  return self.parse_order(order, market)
593
593
 
594
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
594
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}):
595
595
  """
596
596
  make a withdrawal
597
597
  :param str code: unified currency code
@@ -6,7 +6,7 @@
6
6
  from ccxt.async_support.base.exchange import Exchange
7
7
  from ccxt.abstract.mexc import ImplicitAPI
8
8
  import hashlib
9
- from ccxt.base.types import Balances, Currency, Int, Market, Order, OrderBook, OrderRequest, OrderSide, OrderType, IndexType, Str, Strings, Ticker, Tickers, Trade, Transaction
9
+ from ccxt.base.types import Balances, Currency, Int, Market, Order, TransferEntry, OrderBook, OrderRequest, OrderSide, OrderType, IndexType, Str, Strings, Ticker, Tickers, Trade, Transaction
10
10
  from typing import List
11
11
  from ccxt.base.errors import ExchangeError
12
12
  from ccxt.base.errors import PermissionDenied
@@ -1339,7 +1339,8 @@ class mexc(Exchange, ImplicitAPI):
1339
1339
  orderbook['nonce'] = self.safe_integer(data, 'version')
1340
1340
  return orderbook
1341
1341
 
1342
- def parse_bid_ask(self, bidask, priceKey: IndexType = 0, amountKey: IndexType = 1, countKey: IndexType = 2):
1342
+ def parse_bid_ask(self, bidask, priceKey: IndexType = 0, amountKey: IndexType = 1, countOrIdKey: IndexType = 2):
1343
+ countKey = 2
1343
1344
  price = self.safe_number(bidask, priceKey)
1344
1345
  amount = self.safe_number(bidask, amountKey)
1345
1346
  count = self.safe_number(bidask, countKey)
@@ -2017,7 +2018,7 @@ class mexc(Exchange, ImplicitAPI):
2017
2018
  params['createMarketBuyOrderRequiresPrice'] = False
2018
2019
  return await self.create_order(symbol, 'market', 'buy', cost, None, params)
2019
2020
 
2020
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
2021
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
2021
2022
  """
2022
2023
  create a trade order
2023
2024
  :see: https://mexcdevelop.github.io/apidocs/spot_v3_en/#new-order
@@ -3698,7 +3699,7 @@ class mexc(Exchange, ImplicitAPI):
3698
3699
  """
3699
3700
  return await self.modify_margin_helper(symbol, amount, 'ADD', params)
3700
3701
 
3701
- async def set_leverage(self, leverage, symbol: Str = None, params={}):
3702
+ async def set_leverage(self, leverage: Int, symbol: Str = None, params={}):
3702
3703
  """
3703
3704
  set the level of leverage for a market
3704
3705
  :param float leverage: the rate of leverage
@@ -4582,7 +4583,7 @@ class mexc(Exchange, ImplicitAPI):
4582
4583
  #
4583
4584
  return self.parse_transfers(resultList, currency, since, limit)
4584
4585
 
4585
- async def transfer(self, code: str, amount, fromAccount, toAccount, params={}):
4586
+ async def transfer(self, code: str, amount: float, fromAccount, toAccount, params={}) -> TransferEntry:
4586
4587
  """
4587
4588
  transfer currency internally between wallets on the same account
4588
4589
  :see: https://mexcdevelop.github.io/apidocs/spot_v3_en/#user-universal-transfer
@@ -4707,7 +4708,7 @@ class mexc(Exchange, ImplicitAPI):
4707
4708
  }
4708
4709
  return self.safe_string(statuses, status, status)
4709
4710
 
4710
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
4711
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}):
4711
4712
  """
4712
4713
  make a withdrawal
4713
4714
  :see: https://mexcdevelop.github.io/apidocs/spot_v3_en/#withdraw
@@ -1274,7 +1274,7 @@ class ndax(Exchange, ImplicitAPI):
1274
1274
  'trades': None,
1275
1275
  }, market)
1276
1276
 
1277
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
1277
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
1278
1278
  """
1279
1279
  create a trade order
1280
1280
  :param str symbol: unified symbol of the market to create an order in
@@ -2173,7 +2173,7 @@ class ndax(Exchange, ImplicitAPI):
2173
2173
  'network': None,
2174
2174
  }
2175
2175
 
2176
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
2176
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}):
2177
2177
  """
2178
2178
  make a withdrawal
2179
2179
  :param str code: unified currency code
@@ -6,7 +6,7 @@
6
6
  from ccxt.async_support.base.exchange import Exchange
7
7
  from ccxt.abstract.novadax import ImplicitAPI
8
8
  import hashlib
9
- from ccxt.base.types import Balances, Currency, Int, Market, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
9
+ from ccxt.base.types import Balances, Currency, Int, Market, Order, TransferEntry, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
10
10
  from typing import List
11
11
  from ccxt.base.errors import ExchangeError
12
12
  from ccxt.base.errors import PermissionDenied
@@ -715,7 +715,7 @@ class novadax(Exchange, ImplicitAPI):
715
715
  #
716
716
  return self.parse_balance(response)
717
717
 
718
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
718
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
719
719
  """
720
720
  create a trade order
721
721
  :see: https://doc.novadax.com/en-US/#order-introduction
@@ -1083,7 +1083,7 @@ class novadax(Exchange, ImplicitAPI):
1083
1083
  'trades': None,
1084
1084
  }, market)
1085
1085
 
1086
- async def transfer(self, code: str, amount, fromAccount, toAccount, params={}):
1086
+ async def transfer(self, code: str, amount: float, fromAccount, toAccount, params={}) -> TransferEntry:
1087
1087
  """
1088
1088
  transfer currency internally between wallets on the same account
1089
1089
  :see: https://doc.novadax.com/en-US/#get-sub-account-transfer
@@ -1154,7 +1154,7 @@ class novadax(Exchange, ImplicitAPI):
1154
1154
  }
1155
1155
  return self.safe_string(statuses, status, 'failed')
1156
1156
 
1157
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
1157
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}):
1158
1158
  """
1159
1159
  make a withdrawal
1160
1160
  :see: https://doc.novadax.com/en-US/#send-cryptocurrencies
@@ -594,7 +594,7 @@ class oceanex(Exchange, ImplicitAPI):
594
594
  response = await self.privateGetMembersMe(params)
595
595
  return self.parse_balance(response)
596
596
 
597
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
597
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
598
598
  """
599
599
  create a trade order
600
600
  :see: https://api.oceanex.pro/doc/v1/#new-order-post
@@ -6,7 +6,7 @@
6
6
  from ccxt.async_support.base.exchange import Exchange
7
7
  from ccxt.abstract.okcoin import ImplicitAPI
8
8
  import hashlib
9
- from ccxt.base.types import Balances, Currency, Int, Market, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
9
+ from ccxt.base.types import Balances, Currency, Int, Market, Order, TransferEntry, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
10
10
  from typing import List
11
11
  from ccxt.base.errors import ExchangeError
12
12
  from ccxt.base.errors import PermissionDenied
@@ -1261,7 +1261,7 @@ class okcoin(Exchange, ImplicitAPI):
1261
1261
  params['tgtCcy'] = 'quote_ccy'
1262
1262
  return await self.create_order(symbol, 'market', 'buy', cost, None, params)
1263
1263
 
1264
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
1264
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
1265
1265
  """
1266
1266
  :see: https://www.okcoin.com/docs-v5/en/#rest-api-trade-place-order
1267
1267
  :see: https://www.okcoin.com/docs-v5/en/#rest-api-trade-place-algo-order
@@ -1316,7 +1316,7 @@ class okcoin(Exchange, ImplicitAPI):
1316
1316
  order['side'] = side
1317
1317
  return order
1318
1318
 
1319
- def create_order_request(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
1319
+ def create_order_request(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
1320
1320
  market = self.market(symbol)
1321
1321
  request = {
1322
1322
  'instId': market['id'],
@@ -2143,7 +2143,7 @@ class okcoin(Exchange, ImplicitAPI):
2143
2143
  parsed = self.parse_deposit_addresses(filtered, [currency['code']], False)
2144
2144
  return self.index_by(parsed, 'network')
2145
2145
 
2146
- async def transfer(self, code: str, amount, fromAccount, toAccount, params={}):
2146
+ async def transfer(self, code: str, amount: float, fromAccount, toAccount, params={}) -> TransferEntry:
2147
2147
  """
2148
2148
  :see: https://www.okcoin.com/docs-v5/en/#rest-api-funding-funds-transfer
2149
2149
  transfer currency internally between wallets on the same account
@@ -2282,7 +2282,7 @@ class okcoin(Exchange, ImplicitAPI):
2282
2282
  }
2283
2283
  return self.safe_string(statuses, status, status)
2284
2284
 
2285
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
2285
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}):
2286
2286
  """
2287
2287
  :see: https://www.okcoin.com/docs-v5/en/#rest-api-funding-withdrawal
2288
2288
  make a withdrawal
ccxt/async_support/okx.py CHANGED
@@ -7,7 +7,7 @@ from ccxt.async_support.base.exchange import Exchange
7
7
  from ccxt.abstract.okx import ImplicitAPI
8
8
  import asyncio
9
9
  import hashlib
10
- from ccxt.base.types import Balances, Currency, Greeks, Int, Market, Order, OrderBook, OrderRequest, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
10
+ from ccxt.base.types import Balances, Currency, Greeks, Int, Market, Order, TransferEntry, OrderBook, OrderRequest, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
11
11
  from typing import List
12
12
  from ccxt.base.errors import ExchangeError
13
13
  from ccxt.base.errors import PermissionDenied
@@ -1516,8 +1516,8 @@ class okx(Exchange, ImplicitAPI):
1516
1516
  # "msg": ""
1517
1517
  # }
1518
1518
  #
1519
- data = self.safe_value(response, 'data', [])
1520
- return self.parse_markets(data)
1519
+ dataResponse = self.safe_value(response, 'data', [])
1520
+ return self.parse_markets(dataResponse)
1521
1521
 
1522
1522
  def safe_network(self, networkId):
1523
1523
  networksById = {
@@ -2480,7 +2480,7 @@ class okx(Exchange, ImplicitAPI):
2480
2480
  params['tgtCcy'] = 'quote_ccy'
2481
2481
  return await self.create_order(symbol, 'market', 'sell', cost, None, params)
2482
2482
 
2483
- def create_order_request(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
2483
+ def create_order_request(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
2484
2484
  market = self.market(symbol)
2485
2485
  request = {
2486
2486
  'instId': market['id'],
@@ -2684,7 +2684,7 @@ class okx(Exchange, ImplicitAPI):
2684
2684
  params = self.omit(params, ['clOrdId', 'clientOrderId'])
2685
2685
  return self.extend(request, params)
2686
2686
 
2687
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
2687
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
2688
2688
  """
2689
2689
  create a trade order
2690
2690
  :see: https://www.okx.com/docs-v5/en/#order-book-trading-trade-post-place-order
@@ -2965,7 +2965,7 @@ class okx(Exchange, ImplicitAPI):
2965
2965
  :param string[]|str ids: order ids
2966
2966
  :returns str[]: list of order ids
2967
2967
  """
2968
- if isinstance(ids, str):
2968
+ if (ids is not None) and isinstance(ids, str):
2969
2969
  return ids.split(',')
2970
2970
  else:
2971
2971
  return ids
@@ -4377,7 +4377,7 @@ class okx(Exchange, ImplicitAPI):
4377
4377
  raise InvalidAddress(self.id + ' fetchDepositAddress() cannot find ' + network + ' deposit address for ' + code)
4378
4378
  return result
4379
4379
 
4380
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
4380
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}):
4381
4381
  """
4382
4382
  make a withdrawal
4383
4383
  :see: https://www.okx.com/docs-v5/en/#funding-account-rest-api-withdrawal
@@ -5118,7 +5118,7 @@ class okx(Exchange, ImplicitAPI):
5118
5118
  'takeProfitPrice': None,
5119
5119
  })
5120
5120
 
5121
- async def transfer(self, code: str, amount, fromAccount, toAccount, params={}):
5121
+ async def transfer(self, code: str, amount: float, fromAccount, toAccount, params={}) -> TransferEntry:
5122
5122
  """
5123
5123
  transfer currency internally between wallets on the same account
5124
5124
  :see: https://www.okx.com/docs-v5/en/#rest-api-funding-funds-transfer
@@ -5623,7 +5623,7 @@ class okx(Exchange, ImplicitAPI):
5623
5623
  sorted = self.sort_by(result, 'timestamp')
5624
5624
  return self.filter_by_symbol_since_limit(sorted, symbol, since, limit)
5625
5625
 
5626
- async def set_leverage(self, leverage, symbol: Str = None, params={}):
5626
+ async def set_leverage(self, leverage: Int, symbol: Str = None, params={}):
5627
5627
  """
5628
5628
  set the level of leverage for a market
5629
5629
  :see: https://www.okx.com/docs-v5/en/#rest-api-account-set-leverage
@@ -6178,7 +6178,7 @@ class okx(Exchange, ImplicitAPI):
6178
6178
  'info': info,
6179
6179
  }
6180
6180
 
6181
- async def borrow_cross_margin(self, code: str, amount, params={}):
6181
+ async def borrow_cross_margin(self, code: str, amount: float, params={}):
6182
6182
  """
6183
6183
  create a loan to borrow margin(need to be VIP 5 and above)
6184
6184
  :see: https://www.okx.com/docs-v5/en/#trading-account-rest-api-vip-loans-borrow-and-repay
@@ -6731,6 +6731,7 @@ class okx(Exchange, ImplicitAPI):
6731
6731
  entryMarketId = self.safe_string(entry, 'instId')
6732
6732
  if entryMarketId == marketId:
6733
6733
  return self.parse_greeks(entry, market)
6734
+ return None
6734
6735
 
6735
6736
  def parse_greeks(self, greeks, market: Market = None):
6736
6737
  #
@@ -1179,7 +1179,7 @@ class onetrading(Exchange, ImplicitAPI):
1179
1179
  withdrawalHistory = self.safe_value(response, 'withdrawal_history', [])
1180
1180
  return self.parse_transactions(withdrawalHistory, currency, since, limit, {'type': 'withdrawal'})
1181
1181
 
1182
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
1182
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}):
1183
1183
  """
1184
1184
  make a withdrawal
1185
1185
  :param str code: unified currency code
@@ -1443,7 +1443,7 @@ class onetrading(Exchange, ImplicitAPI):
1443
1443
  }
1444
1444
  return self.safe_string(timeInForces, timeInForce, timeInForce)
1445
1445
 
1446
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
1446
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
1447
1447
  """
1448
1448
  create a trade order
1449
1449
  :see: https://docs.onetrading.com/#create-order
ccxt/async_support/p2b.py CHANGED
@@ -760,7 +760,7 @@ class p2b(Exchange, ImplicitAPI):
760
760
  result[code] = account
761
761
  return self.safe_balance(result)
762
762
 
763
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
763
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
764
764
  """
765
765
  create a trade order
766
766
  :see: https://github.com/P2B-team/p2b-api-docs/blob/master/api-doc.md#create-order
@@ -6,7 +6,7 @@
6
6
  from ccxt.async_support.base.exchange import Exchange
7
7
  from ccxt.abstract.paymium import ImplicitAPI
8
8
  import hashlib
9
- from ccxt.base.types import Balances, Currency, Int, Market, OrderBook, OrderSide, OrderType, Str, Ticker, Trade
9
+ from ccxt.base.types import Balances, Currency, Int, Market, TransferEntry, OrderBook, OrderSide, OrderType, Str, Ticker, Trade
10
10
  from typing import List
11
11
  from ccxt.base.errors import ExchangeError
12
12
  from ccxt.base.decimal_to_precision import TICK_SIZE
@@ -366,7 +366,7 @@ class paymium(Exchange, ImplicitAPI):
366
366
  'network': None,
367
367
  }
368
368
 
369
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
369
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
370
370
  """
371
371
  create a trade order
372
372
  :see: https://paymium.github.io/api-documentation/#tag/Order/paths/~1user~1orders/post
@@ -409,7 +409,7 @@ class paymium(Exchange, ImplicitAPI):
409
409
  }
410
410
  return await self.privateDeleteUserOrdersUuidCancel(self.extend(request, params))
411
411
 
412
- async def transfer(self, code: str, amount, fromAccount, toAccount, params={}):
412
+ async def transfer(self, code: str, amount: float, fromAccount, toAccount, params={}) -> TransferEntry:
413
413
  """
414
414
  transfer currency internally between wallets on the same account
415
415
  :see: https://paymium.github.io/api-documentation/#tag/Transfer/paths/~1user~1email_transfers/post
@@ -7,7 +7,7 @@ from ccxt.async_support.base.exchange import Exchange
7
7
  from ccxt.abstract.phemex import ImplicitAPI
8
8
  import hashlib
9
9
  import numbers
10
- from ccxt.base.types import Balances, Currency, Int, Market, Order, OrderBook, OrderSide, OrderType, Num, Str, Strings, Ticker, Tickers, Trade, Transaction
10
+ from ccxt.base.types import Balances, Currency, Int, Market, Order, TransferEntry, OrderBook, OrderSide, OrderType, Num, Str, Strings, Ticker, Tickers, Trade, Transaction
11
11
  from typing import List
12
12
  from ccxt.base.errors import ExchangeError
13
13
  from ccxt.base.errors import PermissionDenied
@@ -1123,7 +1123,7 @@ class phemex(Exchange, ImplicitAPI):
1123
1123
  return orderbook
1124
1124
 
1125
1125
  def to_en(self, n, scale):
1126
- stringN = str(n)
1126
+ stringN = self.number_to_string(n)
1127
1127
  precise = Precise(stringN)
1128
1128
  precise.decimals = precise.decimals - scale
1129
1129
  precise.reduce()
@@ -2341,7 +2341,7 @@ class phemex(Exchange, ImplicitAPI):
2341
2341
  return self.parse_swap_order(order, market)
2342
2342
  return self.parse_spot_order(order, market)
2343
2343
 
2344
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
2344
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
2345
2345
  """
2346
2346
  create a trade order
2347
2347
  :see: https://github.com/phemex/phemex-api-docs/blob/master/Public-Hedged-Perpetual-API.md#place-order
@@ -2427,10 +2427,10 @@ class phemex(Exchange, ImplicitAPI):
2427
2427
  elif cost is None:
2428
2428
  raise ArgumentsRequired(self.id + ' createOrder() ' + qtyType + ' requires a price argument or a cost parameter')
2429
2429
  cost = amount if (cost is None) else cost
2430
- costString = str(cost)
2430
+ costString = self.number_to_string(cost)
2431
2431
  request['quoteQtyEv'] = self.to_ev(costString, market)
2432
2432
  else:
2433
- amountString = str(amount)
2433
+ amountString = self.number_to_string(amount)
2434
2434
  request['baseQtyEv'] = self.to_ev(amountString, market)
2435
2435
  elif market['swap']:
2436
2436
  posSide = self.safe_string_lower(params, 'posSide')
@@ -2443,7 +2443,7 @@ class phemex(Exchange, ImplicitAPI):
2443
2443
  if market['settle'] == 'USDT':
2444
2444
  request['orderQtyRq'] = amount
2445
2445
  else:
2446
- request['orderQty'] = int(amount)
2446
+ request['orderQty'] = self.parse_to_int(amount)
2447
2447
  if stopPrice is not None:
2448
2448
  triggerType = self.safe_string(params, 'triggerType', 'ByMarkPrice')
2449
2449
  request['triggerType'] = triggerType
@@ -4013,7 +4013,7 @@ class phemex(Exchange, ImplicitAPI):
4013
4013
  url = self.implode_hostname(self.urls['api'][api]) + url
4014
4014
  return {'url': url, 'method': method, 'body': body, 'headers': headers}
4015
4015
 
4016
- async def set_leverage(self, leverage, symbol: Str = None, params={}):
4016
+ async def set_leverage(self, leverage: Int, symbol: Str = None, params={}):
4017
4017
  """
4018
4018
  set the level of leverage for a market
4019
4019
  :see: https://github.com/phemex/phemex-api-docs/blob/master/Public-Hedged-Perpetual-API.md#set-leverage
@@ -4044,17 +4044,17 @@ class phemex(Exchange, ImplicitAPI):
4044
4044
  if not isHedged and longLeverageRr is None and shortLeverageRr is None:
4045
4045
  request['leverageRr'] = leverage
4046
4046
  else:
4047
- long = longLeverageRr if (longLeverageRr is not None) else leverage
4048
- short = shortLeverageRr if (shortLeverageRr is not None) else leverage
4049
- request['longLeverageRr'] = long
4050
- request['shortLeverageRr'] = short
4047
+ longVar = longLeverageRr if (longLeverageRr is not None) else leverage
4048
+ shortVar = shortLeverageRr if (shortLeverageRr is not None) else leverage
4049
+ request['longLeverageRr'] = longVar
4050
+ request['shortLeverageRr'] = shortVar
4051
4051
  response = await self.privatePutGPositionsLeverage(self.extend(request, params))
4052
4052
  else:
4053
4053
  request['leverage'] = leverage
4054
4054
  response = await self.privatePutPositionsLeverage(self.extend(request, params))
4055
4055
  return response
4056
4056
 
4057
- async def transfer(self, code: str, amount, fromAccount, toAccount, params={}):
4057
+ async def transfer(self, code: str, amount: float, fromAccount, toAccount, params={}) -> TransferEntry:
4058
4058
  """
4059
4059
  transfer currency internally between wallets on the same account
4060
4060
  :param str code: unified currency code
@@ -4311,7 +4311,7 @@ class phemex(Exchange, ImplicitAPI):
4311
4311
  sorted = self.sort_by(result, 'timestamp')
4312
4312
  return self.filter_by_symbol_since_limit(sorted, symbol, since, limit)
4313
4313
 
4314
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
4314
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}):
4315
4315
  """
4316
4316
  make a withdrawal
4317
4317
  :see: https://phemex-docs.github.io/#create-withdraw-request
@@ -6,7 +6,7 @@
6
6
  from ccxt.async_support.base.exchange import Exchange
7
7
  from ccxt.abstract.poloniex import ImplicitAPI
8
8
  import hashlib
9
- from ccxt.base.types import Balances, Currency, Int, Market, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
9
+ from ccxt.base.types import Balances, Currency, Int, Market, Order, TransferEntry, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction
10
10
  from typing import List
11
11
  from ccxt.base.errors import ExchangeError
12
12
  from ccxt.base.errors import PermissionDenied
@@ -1212,7 +1212,7 @@ class poloniex(Exchange, ImplicitAPI):
1212
1212
  extension = {'status': 'open'}
1213
1213
  return self.parse_orders(response, market, since, limit, extension)
1214
1214
 
1215
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
1215
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
1216
1216
  """
1217
1217
  create a trade order
1218
1218
  :see: https://docs.poloniex.com/#authenticated-endpoints-orders-create-order
@@ -1736,7 +1736,7 @@ class poloniex(Exchange, ImplicitAPI):
1736
1736
  'info': response,
1737
1737
  }
1738
1738
 
1739
- async def transfer(self, code: str, amount, fromAccount, toAccount, params={}):
1739
+ async def transfer(self, code: str, amount: float, fromAccount, toAccount, params={}) -> TransferEntry:
1740
1740
  """
1741
1741
  transfer currency internally between wallets on the same account
1742
1742
  :see: https://docs.poloniex.com/#authenticated-endpoints-accounts-accounts-transfer
@@ -1785,7 +1785,7 @@ class poloniex(Exchange, ImplicitAPI):
1785
1785
  'status': None,
1786
1786
  }
1787
1787
 
1788
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
1788
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}):
1789
1789
  """
1790
1790
  make a withdrawal
1791
1791
  :see: https://docs.poloniex.com/#authenticated-endpoints-wallets-withdraw-currency
@@ -780,7 +780,7 @@ class poloniexfutures(Exchange, ImplicitAPI):
780
780
  #
781
781
  return self.parse_balance(response)
782
782
 
783
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
783
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
784
784
  """
785
785
  Create an order on the exchange
786
786
  :see: https://futures-docs.poloniex.com/#place-an-order
@@ -433,8 +433,8 @@ class probit(Exchange, ImplicitAPI):
433
433
  networkList = {}
434
434
  for j in range(0, len(platformsByPriority)):
435
435
  network = platformsByPriority[j]
436
- networkId = self.safe_string(network, 'id')
437
- networkCode = self.network_id_to_code(networkId)
436
+ idInner = self.safe_string(network, 'id')
437
+ networkCode = self.network_id_to_code(idInner)
438
438
  currentDepositSuspended = self.safe_value(network, 'deposit_suspended')
439
439
  currentWithdrawalSuspended = self.safe_value(network, 'withdrawal_suspended')
440
440
  currentDeposit = not currentDepositSuspended
@@ -452,7 +452,7 @@ class probit(Exchange, ImplicitAPI):
452
452
  networkFee = withdrawPlatform
453
453
  break
454
454
  networkList[networkCode] = {
455
- 'id': networkId,
455
+ 'id': idInner,
456
456
  'network': networkCode,
457
457
  'active': currentActive,
458
458
  'deposit': currentDeposit,
@@ -1138,7 +1138,7 @@ class probit(Exchange, ImplicitAPI):
1138
1138
  def cost_to_precision(self, symbol, cost):
1139
1139
  return self.decimal_to_precision(cost, TRUNCATE, self.markets[symbol]['precision']['cost'], self.precisionMode)
1140
1140
 
1141
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
1141
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
1142
1142
  """
1143
1143
  create a trade order
1144
1144
  :see: https://docs-en.probit.com/reference/order-1
@@ -1331,7 +1331,7 @@ class probit(Exchange, ImplicitAPI):
1331
1331
  data = self.safe_value(response, 'data', [])
1332
1332
  return self.parse_deposit_addresses(data, codes)
1333
1333
 
1334
- async def withdraw(self, code: str, amount, address, tag=None, params={}):
1334
+ async def withdraw(self, code: str, amount: float, address, tag=None, params={}):
1335
1335
  """
1336
1336
  :see: https://docs-en.probit.com/reference/withdrawal
1337
1337
  make a withdrawal
@@ -686,7 +686,7 @@ class timex(Exchange, ImplicitAPI):
686
686
  #
687
687
  return self.parse_balance(response)
688
688
 
689
- async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount, price=None, params={}):
689
+ async def create_order(self, symbol: str, type: OrderType, side: OrderSide, amount: float, price: float = None, params={}):
690
690
  """
691
691
  create a trade order
692
692
  :param str symbol: unified symbol of the market to create an order in