ccxt 4.4.48__py2.py3-none-any.whl → 4.4.50__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.
Files changed (97) hide show
  1. ccxt/__init__.py +1 -1
  2. ccxt/abstract/binance.py +1 -0
  3. ccxt/abstract/binancecoinm.py +1 -0
  4. ccxt/abstract/binanceus.py +1 -0
  5. ccxt/abstract/binanceusdm.py +1 -0
  6. ccxt/alpaca.py +62 -1
  7. ccxt/async_support/__init__.py +1 -1
  8. ccxt/async_support/alpaca.py +62 -1
  9. ccxt/async_support/base/exchange.py +1 -1
  10. ccxt/async_support/binance.py +8 -4
  11. ccxt/async_support/bingx.py +73 -29
  12. ccxt/async_support/bitget.py +12 -10
  13. ccxt/async_support/blofin.py +1 -1
  14. ccxt/async_support/coinex.py +3 -3
  15. ccxt/async_support/coinsph.py +17 -8
  16. ccxt/async_support/deribit.py +82 -0
  17. ccxt/async_support/digifinex.py +125 -10
  18. ccxt/async_support/ellipx.py +61 -0
  19. ccxt/async_support/exmo.py +58 -0
  20. ccxt/async_support/hitbtc.py +99 -0
  21. ccxt/async_support/hollaex.py +85 -16
  22. ccxt/async_support/huobijp.py +73 -0
  23. ccxt/async_support/hyperliquid.py +22 -1
  24. ccxt/async_support/idex.py +71 -0
  25. ccxt/async_support/independentreserve.py +64 -0
  26. ccxt/async_support/indodax.py +61 -0
  27. ccxt/async_support/kucoin.py +47 -67
  28. ccxt/async_support/kuna.py +60 -1
  29. ccxt/async_support/latoken.py +64 -0
  30. ccxt/async_support/lbank.py +70 -0
  31. ccxt/async_support/luno.py +73 -0
  32. ccxt/async_support/lykke.py +64 -0
  33. ccxt/async_support/mercado.py +65 -0
  34. ccxt/async_support/mexc.py +4 -3
  35. ccxt/async_support/myokx.py +10 -0
  36. ccxt/async_support/ndax.py +71 -0
  37. ccxt/async_support/novadax.py +74 -0
  38. ccxt/async_support/oceanex.py +69 -0
  39. ccxt/async_support/okcoin.py +92 -7
  40. ccxt/async_support/onetrading.py +66 -0
  41. ccxt/async_support/oxfun.py +66 -0
  42. ccxt/async_support/p2b.py +63 -1
  43. ccxt/async_support/paradex.py +68 -0
  44. ccxt/async_support/paymium.py +42 -0
  45. ccxt/async_support/probit.py +68 -1
  46. ccxt/async_support/timex.py +67 -0
  47. ccxt/async_support/tokocrypto.py +81 -4
  48. ccxt/async_support/tradeogre.py +58 -1
  49. ccxt/async_support/whitebit.py +10 -4
  50. ccxt/base/exchange.py +62 -1
  51. ccxt/binance.py +8 -4
  52. ccxt/bingx.py +73 -29
  53. ccxt/bitget.py +12 -10
  54. ccxt/blofin.py +1 -1
  55. ccxt/coinex.py +3 -3
  56. ccxt/coinsph.py +17 -8
  57. ccxt/deribit.py +82 -0
  58. ccxt/digifinex.py +125 -10
  59. ccxt/ellipx.py +61 -0
  60. ccxt/exmo.py +58 -0
  61. ccxt/hitbtc.py +99 -0
  62. ccxt/hollaex.py +85 -16
  63. ccxt/huobijp.py +73 -0
  64. ccxt/hyperliquid.py +22 -1
  65. ccxt/idex.py +71 -0
  66. ccxt/independentreserve.py +64 -0
  67. ccxt/indodax.py +61 -0
  68. ccxt/kucoin.py +47 -67
  69. ccxt/kuna.py +60 -1
  70. ccxt/latoken.py +64 -0
  71. ccxt/lbank.py +70 -0
  72. ccxt/luno.py +73 -0
  73. ccxt/lykke.py +64 -0
  74. ccxt/mercado.py +65 -0
  75. ccxt/mexc.py +4 -3
  76. ccxt/myokx.py +10 -0
  77. ccxt/ndax.py +71 -0
  78. ccxt/novadax.py +74 -0
  79. ccxt/oceanex.py +69 -0
  80. ccxt/okcoin.py +92 -7
  81. ccxt/onetrading.py +66 -0
  82. ccxt/oxfun.py +66 -0
  83. ccxt/p2b.py +63 -1
  84. ccxt/paradex.py +68 -0
  85. ccxt/paymium.py +42 -0
  86. ccxt/pro/__init__.py +1 -1
  87. ccxt/pro/bitmart.py +5 -0
  88. ccxt/probit.py +68 -1
  89. ccxt/timex.py +67 -0
  90. ccxt/tokocrypto.py +81 -4
  91. ccxt/tradeogre.py +58 -1
  92. ccxt/whitebit.py +10 -4
  93. {ccxt-4.4.48.dist-info → ccxt-4.4.50.dist-info}/METADATA +4 -4
  94. {ccxt-4.4.48.dist-info → ccxt-4.4.50.dist-info}/RECORD +97 -97
  95. {ccxt-4.4.48.dist-info → ccxt-4.4.50.dist-info}/LICENSE.txt +0 -0
  96. {ccxt-4.4.48.dist-info → ccxt-4.4.50.dist-info}/WHEEL +0 -0
  97. {ccxt-4.4.48.dist-info → ccxt-4.4.50.dist-info}/top_level.txt +0 -0
ccxt/huobijp.py CHANGED
@@ -265,6 +265,79 @@ class huobijp(Exchange, ImplicitAPI):
265
265
  'taker': self.parse_number('0.002'),
266
266
  },
267
267
  },
268
+ 'features': {
269
+ 'spot': {
270
+ 'sandbox': False,
271
+ 'createOrder': {
272
+ 'marginMode': False,
273
+ 'triggerPrice': True, # todo: implement
274
+ 'triggerPriceType': None,
275
+ 'triggerDirection': False,
276
+ 'stopLossPrice': False, # todo
277
+ 'takeProfitPrice': False, # todo
278
+ 'attachedStopLossTakeProfit': None,
279
+ 'timeInForce': {
280
+ 'IOC': False,
281
+ 'FOK': False,
282
+ 'PO': False,
283
+ 'GTD': False,
284
+ },
285
+ 'hedged': False,
286
+ 'selfTradePrevention': False,
287
+ 'trailing': False,
288
+ 'leverage': False,
289
+ 'marketBuyByCost': True,
290
+ 'marketBuyRequiresPrice': False,
291
+ 'iceberg': False,
292
+ },
293
+ 'createOrders': None,
294
+ 'fetchMyTrades': {
295
+ 'marginMode': False,
296
+ 'limit': 100,
297
+ 'daysBack': 120,
298
+ 'untilDays': 2,
299
+ },
300
+ 'fetchOrder': {
301
+ 'marginMode': False,
302
+ 'trigger': False,
303
+ 'trailing': False,
304
+ },
305
+ 'fetchOpenOrders': {
306
+ 'marginMode': False,
307
+ 'limit': None, # todo
308
+ 'trigger': False,
309
+ 'trailing': False,
310
+ },
311
+ 'fetchOrders': {
312
+ 'marginMode': False,
313
+ 'limit': None,
314
+ 'daysBack': None, # todo
315
+ 'untilDays': None, # todo
316
+ 'trigger': False,
317
+ 'trailing': False,
318
+ },
319
+ 'fetchClosedOrders': {
320
+ 'marginMode': False,
321
+ 'limit': None,
322
+ 'daysBack': None, # todo
323
+ 'daysBackCanceled': None, # todo
324
+ 'untilDays': None, # todo
325
+ 'trigger': False,
326
+ 'trailing': False,
327
+ },
328
+ 'fetchOHLCV': {
329
+ 'limit': 2000,
330
+ },
331
+ },
332
+ 'swap': {
333
+ 'linear': None,
334
+ 'inverse': None,
335
+ },
336
+ 'future': {
337
+ 'linear': None,
338
+ 'inverse': None,
339
+ },
340
+ },
268
341
  'precisionMode': TICK_SIZE,
269
342
  'exceptions': {
270
343
  'broad': {
ccxt/hyperliquid.py CHANGED
@@ -215,6 +215,8 @@ class hyperliquid(Exchange, ImplicitAPI):
215
215
  'Order price cannot be more than 80% away from the reference price': InvalidOrder,
216
216
  'Order has zero size.': InvalidOrder,
217
217
  'Insufficient spot balance asset': InsufficientFunds,
218
+ 'Insufficient balance for withdrawal': InsufficientFunds,
219
+ 'Insufficient balance for token transfer': InsufficientFunds,
218
220
  },
219
221
  },
220
222
  'precisionMode': TICK_SIZE,
@@ -2755,7 +2757,26 @@ class hyperliquid(Exchange, ImplicitAPI):
2755
2757
  'signature': sig,
2756
2758
  }
2757
2759
  response = self.privatePostExchange(request)
2758
- return response
2760
+ #
2761
+ # {'response': {'type': 'default'}, 'status': 'ok'}
2762
+ #
2763
+ return self.parse_transfer(response)
2764
+
2765
+ def parse_transfer(self, transfer: dict, currency: Currency = None) -> TransferEntry:
2766
+ #
2767
+ # {'response': {'type': 'default'}, 'status': 'ok'}
2768
+ #
2769
+ return {
2770
+ 'info': transfer,
2771
+ 'id': None,
2772
+ 'timestamp': None,
2773
+ 'datetime': None,
2774
+ 'currency': None,
2775
+ 'amount': None,
2776
+ 'fromAccount': None,
2777
+ 'toAccount': None,
2778
+ 'status': 'ok',
2779
+ }
2759
2780
 
2760
2781
  def withdraw(self, code: str, amount: float, address: str, tag=None, params={}) -> Transaction:
2761
2782
  """
ccxt/idex.py CHANGED
@@ -176,6 +176,77 @@ class idex(Exchange, ImplicitAPI):
176
176
  'defaultSelfTradePrevention': 'cn',
177
177
  'network': 'MATIC',
178
178
  },
179
+ 'features': {
180
+ 'spot': {
181
+ 'sandbox': False,
182
+ 'createOrder': {
183
+ 'marginMode': False,
184
+ 'triggerPrice': True,
185
+ # todo: revise
186
+ 'triggerPriceType': {
187
+ 'last': True,
188
+ 'mark': True,
189
+ 'index': True,
190
+ },
191
+ 'triggerDirection': False,
192
+ 'stopLossPrice': False, # todo
193
+ 'takeProfitPrice': False, # todo
194
+ 'attachedStopLossTakeProfit': None,
195
+ 'timeInForce': {
196
+ 'IOC': True,
197
+ 'FOK': True,
198
+ 'PO': True,
199
+ 'GTD': False,
200
+ },
201
+ 'hedged': False,
202
+ 'selfTradePrevention': True, # todo implementation
203
+ 'trailing': False,
204
+ 'leverage': False,
205
+ 'marketBuyByCost': False,
206
+ 'marketBuyRequiresPrice': False,
207
+ 'iceberg': False,
208
+ },
209
+ 'createOrders': None,
210
+ 'fetchMyTrades': {
211
+ 'marginMode': False,
212
+ 'limit': 1000,
213
+ 'daysBack': 100000, # todo
214
+ 'untilDays': 100000, # todo
215
+ },
216
+ 'fetchOrder': {
217
+ 'marginMode': False,
218
+ 'trigger': False,
219
+ 'trailing': False,
220
+ },
221
+ 'fetchOpenOrders': {
222
+ 'marginMode': False,
223
+ 'limit': 1000,
224
+ 'trigger': False,
225
+ 'trailing': False,
226
+ },
227
+ 'fetchOrders': None,
228
+ 'fetchClosedOrders': {
229
+ 'marginMode': False,
230
+ 'limit': 1000,
231
+ 'daysBack': 1000000, # todo
232
+ 'daysBackCanceled': 1, # todo
233
+ 'untilDays': 1000000, # todo
234
+ 'trigger': False,
235
+ 'trailing': False,
236
+ },
237
+ 'fetchOHLCV': {
238
+ 'limit': 1000,
239
+ },
240
+ },
241
+ 'swap': {
242
+ 'linear': None,
243
+ 'inverse': None,
244
+ },
245
+ 'future': {
246
+ 'linear': None,
247
+ 'inverse': None,
248
+ },
249
+ },
179
250
  'exceptions': {
180
251
  'exact': {
181
252
  'INVALID_ORDER_QUANTITY': InvalidOrder,
@@ -148,6 +148,70 @@ class independentreserve(Exchange, ImplicitAPI):
148
148
  'tierBased': False,
149
149
  },
150
150
  },
151
+ 'features': {
152
+ 'spot': {
153
+ 'sandbox': False,
154
+ 'createOrder': {
155
+ 'marginMode': False,
156
+ 'triggerPrice': False,
157
+ 'triggerPriceType': None,
158
+ 'triggerDirection': False,
159
+ 'stopLossPrice': False,
160
+ 'takeProfitPrice': False,
161
+ 'attachedStopLossTakeProfit': None,
162
+ 'timeInForce': {
163
+ 'IOC': False,
164
+ 'FOK': False,
165
+ 'PO': False,
166
+ 'GTD': False,
167
+ },
168
+ 'hedged': False,
169
+ 'selfTradePrevention': False,
170
+ 'trailing': False,
171
+ 'leverage': False,
172
+ 'marketBuyByCost': False,
173
+ 'marketBuyRequiresPrice': False,
174
+ 'iceberg': False,
175
+ },
176
+ 'createOrders': None,
177
+ 'fetchMyTrades': {
178
+ 'marginMode': False,
179
+ 'limit': 100, # todo
180
+ 'daysBack': None,
181
+ 'untilDays': None,
182
+ },
183
+ 'fetchOrder': {
184
+ 'marginMode': False,
185
+ 'trigger': False,
186
+ 'trailing': False,
187
+ },
188
+ 'fetchOpenOrders': {
189
+ 'marginMode': False,
190
+ 'limit': 100, # todo
191
+ 'trigger': False,
192
+ 'trailing': False,
193
+ },
194
+ 'fetchOrders': None,
195
+ 'fetchClosedOrders': {
196
+ 'marginMode': False,
197
+ 'limit': 100, # todo
198
+ 'daysBack': None,
199
+ 'daysBackCanceled': None,
200
+ 'untilDays': None,
201
+ 'trigger': False,
202
+ 'trailing': False,
203
+ },
204
+ 'fetchOHLCV': None,
205
+ },
206
+ 'swap': {
207
+ 'linear': None,
208
+ 'inverse': None,
209
+ },
210
+ 'future': {
211
+ 'linear': None,
212
+ 'inverse': None,
213
+ },
214
+ },
151
215
  'commonCurrencies': {
152
216
  'PLA': 'PlayChip',
153
217
  },
ccxt/indodax.py CHANGED
@@ -204,6 +204,67 @@ class indodax(Exchange, ImplicitAPI):
204
204
  '1w': '1W',
205
205
  },
206
206
  },
207
+ 'features': {
208
+ 'spot': {
209
+ 'sandbox': False,
210
+ 'createOrder': {
211
+ 'marginMode': False,
212
+ 'triggerPrice': False,
213
+ 'triggerPriceType': None,
214
+ 'triggerDirection': False,
215
+ 'stopLossPrice': False,
216
+ 'takeProfitPrice': False,
217
+ 'attachedStopLossTakeProfit': None,
218
+ 'timeInForce': {
219
+ 'IOC': True, # todo implementation
220
+ 'FOK': False,
221
+ 'PO': False,
222
+ 'GTD': False,
223
+ },
224
+ 'hedged': False,
225
+ 'selfTradePrevention': False,
226
+ 'trailing': False,
227
+ 'leverage': False,
228
+ 'marketBuyByCost': False,
229
+ 'marketBuyRequiresPrice': False,
230
+ 'iceberg': False,
231
+ },
232
+ 'createOrders': None,
233
+ 'fetchMyTrades': None, # todo implement
234
+ 'fetchOrder': {
235
+ 'marginMode': False,
236
+ 'trigger': False,
237
+ 'trailing': False,
238
+ },
239
+ 'fetchOpenOrders': {
240
+ 'marginMode': False,
241
+ 'limit': None,
242
+ 'trigger': False,
243
+ 'trailing': False,
244
+ },
245
+ 'fetchOrders': None,
246
+ 'fetchClosedOrders': {
247
+ 'marginMode': False,
248
+ 'limit': 1000,
249
+ 'daysBack': 100000, # todo
250
+ 'daysBackCanceled': 1,
251
+ 'untilDays': None,
252
+ 'trigger': False,
253
+ 'trailing': False,
254
+ },
255
+ 'fetchOHLCV': {
256
+ 'limit': 2000, # todo: not in request
257
+ },
258
+ },
259
+ 'swap': {
260
+ 'linear': None,
261
+ 'inverse': None,
262
+ },
263
+ 'future': {
264
+ 'linear': None,
265
+ 'inverse': None,
266
+ },
267
+ },
207
268
  'commonCurrencies': {
208
269
  'STR': 'XLM',
209
270
  'BCHABC': 'BCH',
ccxt/kucoin.py CHANGED
@@ -1351,8 +1351,7 @@ class kucoin(Exchange, ImplicitAPI):
1351
1351
  :param dict params: extra parameters specific to the exchange API endpoint
1352
1352
  :returns dict: an associative dictionary of currencies
1353
1353
  """
1354
- promises = []
1355
- promises.append(self.publicGetCurrencies(params))
1354
+ response = self.publicGetCurrencies(params)
1356
1355
  #
1357
1356
  # {
1358
1357
  # "code":"200000",
@@ -1378,87 +1377,39 @@ class kucoin(Exchange, ImplicitAPI):
1378
1377
  # "isDepositEnabled":false,
1379
1378
  # "confirms":12,
1380
1379
  # "preConfirms":12,
1380
+ # "withdrawPrecision": 8,
1381
+ # "maxWithdraw": null,
1382
+ # "maxDeposit": null,
1383
+ # "needTag": False,
1381
1384
  # "contractAddress":"0xa6446d655a0c34bc4f05042ee88170d056cbaf45",
1382
1385
  # "depositFeeRate": "0.001", # present for some currencies/networks
1383
1386
  # }
1384
1387
  # ]
1385
1388
  # },
1386
- # }
1387
- #
1388
- promises.append(self.fetch_web_endpoint('fetchCurrencies', 'webExchangeGetCurrencyCurrencyChainInfo', True))
1389
- #
1390
- # {
1391
- # "success": True,
1392
- # "code": "200",
1393
- # "msg": "success",
1394
- # "retry": False,
1395
- # "data": [
1396
- # {
1397
- # "status": "enabled",
1398
- # "currency": "BTC",
1399
- # "isChainEnabled": "true",
1400
- # "chain": "btc",
1401
- # "chainName": "BTC",
1402
- # "chainFullName": "Bitcoin",
1403
- # "walletPrecision": "8",
1404
- # "isDepositEnabled": "true",
1405
- # "depositMinSize": "0.00005",
1406
- # "confirmationCount": "2",
1407
- # "isWithdrawEnabled": "true",
1408
- # "withdrawMinSize": "0.001",
1409
- # "withdrawMinFee": "0.0005",
1410
- # "withdrawFeeRate": "0",
1411
- # "depositDisabledTip": "Wallet Maintenance",
1412
- # "preDepositTipEnabled": "true",
1413
- # "preDepositTip": "Do not transfer from ETH network directly",
1414
- # "withdrawDisabledTip": "",
1415
- # "preWithdrawTipEnabled": "false",
1416
- # "preWithdrawTip": "",
1417
- # "orgAddress": "",
1418
- # "userAddressName": "Memo",
1419
- # },
1420
1389
  # ]
1421
1390
  # }
1422
1391
  #
1423
- responses = promises
1424
- currenciesResponse = self.safe_dict(responses, 0, {})
1425
- currenciesData = self.safe_list(currenciesResponse, 'data', [])
1426
- additionalResponse = self.safe_dict(responses, 1, {})
1427
- additionalData = self.safe_list(additionalResponse, 'data', [])
1428
- additionalDataGrouped = self.group_by(additionalData, 'currency')
1392
+ currenciesData = self.safe_list(response, 'data', [])
1429
1393
  result: dict = {}
1430
1394
  for i in range(0, len(currenciesData)):
1431
1395
  entry = currenciesData[i]
1432
1396
  id = self.safe_string(entry, 'currency')
1433
1397
  name = self.safe_string(entry, 'fullName')
1434
1398
  code = self.safe_currency_code(id)
1435
- isWithdrawEnabled = None
1436
- isDepositEnabled = None
1437
1399
  networks: dict = {}
1438
1400
  chains = self.safe_list(entry, 'chains', [])
1439
- extraChainsData = self.index_by(self.safe_list(additionalDataGrouped, id, []), 'chain')
1440
1401
  rawPrecision = self.safe_string(entry, 'precision')
1441
1402
  precision = self.parse_number(self.parse_precision(rawPrecision))
1442
1403
  chainsLength = len(chains)
1443
1404
  if not chainsLength:
1444
- # https://t.me/KuCoin_API/173118
1445
- isWithdrawEnabled = False
1446
- isDepositEnabled = False
1405
+ # one buggy coin, which doesn't contain info https://t.me/KuCoin_API/173118
1406
+ continue
1447
1407
  for j in range(0, chainsLength):
1448
1408
  chain = chains[j]
1449
1409
  chainId = self.safe_string(chain, 'chainId')
1450
1410
  networkCode = self.network_id_to_code(chainId, code)
1451
1411
  chainWithdrawEnabled = self.safe_bool(chain, 'isWithdrawEnabled', False)
1452
- if isWithdrawEnabled is None:
1453
- isWithdrawEnabled = chainWithdrawEnabled
1454
- else:
1455
- isWithdrawEnabled = isWithdrawEnabled or chainWithdrawEnabled
1456
1412
  chainDepositEnabled = self.safe_bool(chain, 'isDepositEnabled', False)
1457
- if isDepositEnabled is None:
1458
- isDepositEnabled = chainDepositEnabled
1459
- else:
1460
- isDepositEnabled = isDepositEnabled or chainDepositEnabled
1461
- chainExtraData = self.safe_dict(extraChainsData, chainId, {})
1462
1413
  networks[networkCode] = {
1463
1414
  'info': chain,
1464
1415
  'id': chainId,
@@ -1468,34 +1419,34 @@ class kucoin(Exchange, ImplicitAPI):
1468
1419
  'fee': self.safe_number(chain, 'withdrawalMinFee'),
1469
1420
  'deposit': chainDepositEnabled,
1470
1421
  'withdraw': chainWithdrawEnabled,
1471
- 'precision': self.parse_number(self.parse_precision(self.safe_string(chainExtraData, 'walletPrecision'))),
1422
+ 'precision': self.parse_number(self.parse_precision(self.safe_string(chain, 'withdrawPrecision'))),
1472
1423
  'limits': {
1473
1424
  'withdraw': {
1474
1425
  'min': self.safe_number(chain, 'withdrawalMinSize'),
1475
- 'max': None,
1426
+ 'max': self.safe_number(chain, 'maxWithdraw'),
1476
1427
  },
1477
1428
  'deposit': {
1478
1429
  'min': self.safe_number(chain, 'depositMinSize'),
1479
- 'max': None,
1430
+ 'max': self.safe_number(chain, 'maxDeposit'),
1480
1431
  },
1481
1432
  },
1482
1433
  }
1483
1434
  # kucoin has determined 'fiat' currencies with below logic
1484
1435
  isFiat = (rawPrecision == '2') and (chainsLength == 0)
1485
- result[code] = {
1436
+ result[code] = self.safe_currency_structure({
1486
1437
  'id': id,
1487
1438
  'name': name,
1488
1439
  'code': code,
1489
1440
  'type': 'fiat' if isFiat else 'crypto',
1490
1441
  'precision': precision,
1491
1442
  'info': entry,
1492
- 'active': (isDepositEnabled or isWithdrawEnabled),
1493
- 'deposit': isDepositEnabled,
1494
- 'withdraw': isWithdrawEnabled,
1495
- 'fee': None,
1496
- 'limits': self.limits,
1497
1443
  'networks': networks,
1498
- }
1444
+ 'deposit': None,
1445
+ 'withdraw': None,
1446
+ 'active': None,
1447
+ 'fee': None,
1448
+ 'limits': None,
1449
+ })
1499
1450
  return result
1500
1451
 
1501
1452
  def fetch_accounts(self, params={}) -> List[Account]:
@@ -1635,6 +1586,35 @@ class kucoin(Exchange, ImplicitAPI):
1635
1586
  # "chain": "ERC20"
1636
1587
  # }
1637
1588
  #
1589
+ if 'chains' in fee:
1590
+ # if data obtained through `currencies` endpoint
1591
+ resultNew: dict = {
1592
+ 'info': fee,
1593
+ 'withdraw': {
1594
+ 'fee': None,
1595
+ 'percentage': False,
1596
+ },
1597
+ 'deposit': {
1598
+ 'fee': None,
1599
+ 'percentage': None,
1600
+ },
1601
+ 'networks': {},
1602
+ }
1603
+ chains = self.safe_list(fee, 'chains', [])
1604
+ for i in range(0, len(chains)):
1605
+ chain = chains[i]
1606
+ networkCodeNew = self.network_id_to_code(self.safe_string(chain, 'chainId'), self.safe_string(currency, 'code'))
1607
+ resultNew['networks'][networkCodeNew] = {
1608
+ 'withdraw': {
1609
+ 'fee': self.safe_number(chain, 'withdrawMinFee'),
1610
+ 'percentage': False,
1611
+ },
1612
+ 'deposit': {
1613
+ 'fee': None,
1614
+ 'percentage': None,
1615
+ },
1616
+ }
1617
+ return resultNew
1638
1618
  minWithdrawFee = self.safe_number(fee, 'withdrawMinFee')
1639
1619
  result: dict = {
1640
1620
  'info': fee,
ccxt/kuna.py CHANGED
@@ -78,7 +78,7 @@ class kuna(Exchange, ImplicitAPI):
78
78
  'fetchMarkets': True,
79
79
  'fetchMarkOHLCV': False,
80
80
  'fetchMyTrades': True,
81
- 'fetchOHLCV': 'emulated',
81
+ 'fetchOHLCV': False,
82
82
  'fetchOpenInterest': False,
83
83
  'fetchOpenInterestHistory': False,
84
84
  'fetchOpenOrders': True,
@@ -363,6 +363,65 @@ class kuna(Exchange, ImplicitAPI):
363
363
  ],
364
364
  },
365
365
  },
366
+ 'features': {
367
+ 'spot': {
368
+ 'sandbox': False,
369
+ 'createOrder': {
370
+ 'marginMode': False,
371
+ 'triggerPrice': True,
372
+ 'triggerPriceType': None,
373
+ 'triggerDirection': False,
374
+ 'stopLossPrice': False, # todo
375
+ 'takeProfitPrice': False, # todo
376
+ 'attachedStopLossTakeProfit': None,
377
+ 'timeInForce': {
378
+ 'IOC': False,
379
+ 'FOK': False,
380
+ 'PO': False,
381
+ 'GTD': False,
382
+ },
383
+ 'hedged': False,
384
+ 'selfTradePrevention': False,
385
+ 'trailing': False,
386
+ 'leverage': False,
387
+ 'marketBuyByCost': True,
388
+ 'marketBuyRequiresPrice': False,
389
+ 'iceberg': False,
390
+ },
391
+ 'createOrders': None,
392
+ 'fetchMyTrades': None, # todo implement
393
+ 'fetchOrder': {
394
+ 'marginMode': False,
395
+ 'trigger': False,
396
+ 'trailing': False,
397
+ },
398
+ 'fetchOpenOrders': {
399
+ 'marginMode': False,
400
+ 'limit': 100,
401
+ 'trigger': False,
402
+ 'trailing': False,
403
+ },
404
+ 'fetchOrders': None,
405
+ 'fetchClosedOrders': {
406
+ 'marginMode': False,
407
+ 'limit': 100,
408
+ 'daysBack': 100000, # todo
409
+ 'daysBackCanceled': 1,
410
+ 'untilDays': 14,
411
+ 'trigger': False,
412
+ 'trailing': False,
413
+ },
414
+ 'fetchOHLCV': None,
415
+ },
416
+ 'swap': {
417
+ 'linear': None,
418
+ 'inverse': None,
419
+ },
420
+ 'future': {
421
+ 'linear': None,
422
+ 'inverse': None,
423
+ },
424
+ },
366
425
  'fees': {
367
426
  'trading': {
368
427
  'tierBased': False,
ccxt/latoken.py CHANGED
@@ -248,6 +248,70 @@ class latoken(Exchange, ImplicitAPI):
248
248
  'method': 'fetchPrivateTradingFee', # or 'fetchPublicTradingFee'
249
249
  },
250
250
  },
251
+ 'features': {
252
+ 'spot': {
253
+ 'sandbox': False,
254
+ 'createOrder': {
255
+ 'marginMode': False,
256
+ 'triggerPrice': True,
257
+ 'triggerPriceType': None,
258
+ 'triggerDirection': False,
259
+ 'stopLossPrice': False, # todo
260
+ 'takeProfitPrice': False, # todo
261
+ 'attachedStopLossTakeProfit': None,
262
+ 'timeInForce': {
263
+ 'IOC': True, # todo: for non-trigger orders
264
+ 'FOK': True,
265
+ 'PO': False,
266
+ 'GTD': False,
267
+ },
268
+ 'hedged': False,
269
+ 'selfTradePrevention': False,
270
+ 'trailing': False,
271
+ 'leverage': False,
272
+ 'marketBuyByCost': True,
273
+ 'marketBuyRequiresPrice': False,
274
+ 'iceberg': False,
275
+ },
276
+ 'createOrders': None,
277
+ 'fetchMyTrades': {
278
+ 'marginMode': False,
279
+ 'limit': 1000,
280
+ 'daysBack': 100000, # todo
281
+ 'untilDays': None,
282
+ },
283
+ 'fetchOrder': {
284
+ 'marginMode': False,
285
+ 'trigger': True,
286
+ 'trailing': False,
287
+ },
288
+ 'fetchOpenOrders': {
289
+ 'marginMode': False,
290
+ 'limit': None,
291
+ 'trigger': False,
292
+ 'trailing': False,
293
+ },
294
+ 'fetchOrders': None,
295
+ 'fetchClosedOrders': {
296
+ 'marginMode': False,
297
+ 'limit': 1000,
298
+ 'daysBack': 100000, # todo
299
+ 'daysBackCanceled': 1,
300
+ 'untilDays': None,
301
+ 'trigger': True,
302
+ 'trailing': False,
303
+ },
304
+ 'fetchOHLCV': None,
305
+ },
306
+ 'swap': {
307
+ 'linear': None,
308
+ 'inverse': None,
309
+ },
310
+ 'future': {
311
+ 'linear': None,
312
+ 'inverse': None,
313
+ },
314
+ },
251
315
  })
252
316
 
253
317
  def nonce(self):