ccxt 4.4.41__py2.py3-none-any.whl → 4.4.43__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 (177) hide show
  1. ccxt/__init__.py +3 -1
  2. ccxt/abstract/binance.py +3 -0
  3. ccxt/abstract/binancecoinm.py +3 -0
  4. ccxt/abstract/binanceus.py +3 -0
  5. ccxt/abstract/binanceusdm.py +3 -0
  6. ccxt/abstract/bingx.py +4 -0
  7. ccxt/abstract/bitstamp.py +1 -0
  8. ccxt/abstract/myokx.py +340 -0
  9. ccxt/ace.py +1 -1
  10. ccxt/alpaca.py +0 -1
  11. ccxt/ascendex.py +0 -1
  12. ccxt/async_support/__init__.py +3 -1
  13. ccxt/async_support/ace.py +1 -1
  14. ccxt/async_support/alpaca.py +0 -1
  15. ccxt/async_support/ascendex.py +0 -1
  16. ccxt/async_support/base/exchange.py +15 -15
  17. ccxt/async_support/bigone.py +0 -1
  18. ccxt/async_support/binance.py +3 -0
  19. ccxt/async_support/bingx.py +27 -7
  20. ccxt/async_support/bitfinex.py +122 -0
  21. ccxt/async_support/bitstamp.py +54 -0
  22. ccxt/async_support/blofin.py +16 -7
  23. ccxt/async_support/cex.py +1 -1
  24. ccxt/async_support/coinbase.py +8 -9
  25. ccxt/async_support/coinbaseexchange.py +5 -6
  26. ccxt/async_support/coinbaseinternational.py +7 -8
  27. ccxt/async_support/coincatch.py +0 -1
  28. ccxt/async_support/coincheck.py +0 -1
  29. ccxt/async_support/coinex.py +91 -6
  30. ccxt/async_support/coinlist.py +3 -4
  31. ccxt/async_support/coinmate.py +1 -3
  32. ccxt/async_support/coinmetro.py +4 -5
  33. ccxt/async_support/coinone.py +0 -1
  34. ccxt/async_support/coinsph.py +7 -8
  35. ccxt/async_support/cryptocom.py +3 -0
  36. ccxt/async_support/currencycom.py +3 -4
  37. ccxt/async_support/defx.py +6 -7
  38. ccxt/async_support/deribit.py +1 -3
  39. ccxt/async_support/digifinex.py +0 -1
  40. ccxt/async_support/ellipx.py +0 -2
  41. ccxt/async_support/exmo.py +1 -2
  42. ccxt/async_support/gate.py +1 -2
  43. ccxt/async_support/gemini.py +63 -6
  44. ccxt/async_support/hashkey.py +79 -67
  45. ccxt/async_support/hitbtc.py +47 -5
  46. ccxt/async_support/hollaex.py +4 -6
  47. ccxt/async_support/htx.py +1 -3
  48. ccxt/async_support/huobijp.py +0 -1
  49. ccxt/async_support/hyperliquid.py +1 -1
  50. ccxt/async_support/idex.py +8 -8
  51. ccxt/async_support/independentreserve.py +0 -1
  52. ccxt/async_support/indodax.py +0 -1
  53. ccxt/async_support/kraken.py +63 -3
  54. ccxt/async_support/krakenfutures.py +75 -3
  55. ccxt/async_support/kucoin.py +1 -3
  56. ccxt/async_support/kucoinfutures.py +10 -9
  57. ccxt/async_support/kuna.py +1 -3
  58. ccxt/async_support/latoken.py +1 -3
  59. ccxt/async_support/lbank.py +0 -1
  60. ccxt/async_support/luno.py +0 -1
  61. ccxt/async_support/lykke.py +0 -1
  62. ccxt/async_support/mercado.py +0 -1
  63. ccxt/async_support/mexc.py +3 -4
  64. ccxt/async_support/myokx.py +35 -0
  65. ccxt/async_support/ndax.py +1 -1
  66. ccxt/async_support/novadax.py +4 -6
  67. ccxt/async_support/oceanex.py +0 -1
  68. ccxt/async_support/okcoin.py +1 -3
  69. ccxt/async_support/okx.py +1 -3
  70. ccxt/async_support/onetrading.py +1 -3
  71. ccxt/async_support/p2b.py +1 -1
  72. ccxt/async_support/paradex.py +5 -7
  73. ccxt/async_support/phemex.py +14 -14
  74. ccxt/async_support/poloniex.py +1 -3
  75. ccxt/async_support/poloniexfutures.py +6 -6
  76. ccxt/async_support/probit.py +0 -1
  77. ccxt/async_support/timex.py +0 -1
  78. ccxt/async_support/tokocrypto.py +11 -14
  79. ccxt/async_support/tradeogre.py +1 -1
  80. ccxt/async_support/upbit.py +0 -1
  81. ccxt/async_support/vertex.py +63 -4
  82. ccxt/async_support/wavesexchange.py +4 -5
  83. ccxt/async_support/whitebit.py +8 -9
  84. ccxt/async_support/woo.py +100 -14
  85. ccxt/async_support/woofipro.py +96 -15
  86. ccxt/async_support/xt.py +3 -2
  87. ccxt/async_support/yobit.py +0 -1
  88. ccxt/async_support/zaif.py +0 -1
  89. ccxt/async_support/zonda.py +1 -2
  90. ccxt/base/exchange.py +21 -17
  91. ccxt/bigone.py +0 -1
  92. ccxt/binance.py +3 -0
  93. ccxt/bingx.py +27 -7
  94. ccxt/bitfinex.py +122 -0
  95. ccxt/bitstamp.py +54 -0
  96. ccxt/blofin.py +16 -7
  97. ccxt/cex.py +1 -1
  98. ccxt/coinbase.py +8 -9
  99. ccxt/coinbaseexchange.py +5 -6
  100. ccxt/coinbaseinternational.py +7 -8
  101. ccxt/coincatch.py +0 -1
  102. ccxt/coincheck.py +0 -1
  103. ccxt/coinex.py +91 -6
  104. ccxt/coinlist.py +3 -4
  105. ccxt/coinmate.py +1 -3
  106. ccxt/coinmetro.py +4 -5
  107. ccxt/coinone.py +0 -1
  108. ccxt/coinsph.py +7 -8
  109. ccxt/cryptocom.py +3 -0
  110. ccxt/currencycom.py +3 -4
  111. ccxt/defx.py +6 -7
  112. ccxt/deribit.py +1 -3
  113. ccxt/digifinex.py +0 -1
  114. ccxt/ellipx.py +0 -2
  115. ccxt/exmo.py +1 -2
  116. ccxt/gate.py +1 -2
  117. ccxt/gemini.py +63 -6
  118. ccxt/hashkey.py +79 -67
  119. ccxt/hitbtc.py +47 -5
  120. ccxt/hollaex.py +4 -6
  121. ccxt/htx.py +1 -3
  122. ccxt/huobijp.py +0 -1
  123. ccxt/hyperliquid.py +1 -1
  124. ccxt/idex.py +8 -8
  125. ccxt/independentreserve.py +0 -1
  126. ccxt/indodax.py +0 -1
  127. ccxt/kraken.py +63 -3
  128. ccxt/krakenfutures.py +75 -3
  129. ccxt/kucoin.py +1 -3
  130. ccxt/kucoinfutures.py +10 -9
  131. ccxt/kuna.py +1 -3
  132. ccxt/latoken.py +1 -3
  133. ccxt/lbank.py +0 -1
  134. ccxt/luno.py +0 -1
  135. ccxt/lykke.py +0 -1
  136. ccxt/mercado.py +0 -1
  137. ccxt/mexc.py +3 -4
  138. ccxt/myokx.py +35 -0
  139. ccxt/ndax.py +1 -1
  140. ccxt/novadax.py +4 -6
  141. ccxt/oceanex.py +0 -1
  142. ccxt/okcoin.py +1 -3
  143. ccxt/okx.py +1 -3
  144. ccxt/onetrading.py +1 -3
  145. ccxt/p2b.py +1 -1
  146. ccxt/paradex.py +5 -7
  147. ccxt/phemex.py +14 -14
  148. ccxt/poloniex.py +1 -3
  149. ccxt/poloniexfutures.py +6 -6
  150. ccxt/pro/__init__.py +3 -1
  151. ccxt/pro/myokx.py +23 -0
  152. ccxt/probit.py +0 -1
  153. ccxt/timex.py +0 -1
  154. ccxt/tokocrypto.py +11 -14
  155. ccxt/tradeogre.py +1 -1
  156. ccxt/upbit.py +0 -1
  157. ccxt/vertex.py +63 -4
  158. ccxt/wavesexchange.py +4 -5
  159. ccxt/whitebit.py +8 -9
  160. ccxt/woo.py +100 -14
  161. ccxt/woofipro.py +96 -15
  162. ccxt/xt.py +3 -2
  163. ccxt/yobit.py +0 -1
  164. ccxt/zaif.py +0 -1
  165. ccxt/zonda.py +1 -2
  166. {ccxt-4.4.41.dist-info → ccxt-4.4.43.dist-info}/METADATA +37 -35
  167. {ccxt-4.4.41.dist-info → ccxt-4.4.43.dist-info}/RECORD +170 -173
  168. ccxt/async_support/bitbay.py +0 -17
  169. ccxt/async_support/bitfinex2.py +0 -3625
  170. ccxt/async_support/hitbtc3.py +0 -16
  171. ccxt/bitbay.py +0 -17
  172. ccxt/bitfinex2.py +0 -3624
  173. ccxt/hitbtc3.py +0 -16
  174. ccxt/pro/bitfinex2.py +0 -1086
  175. {ccxt-4.4.41.dist-info → ccxt-4.4.43.dist-info}/LICENSE.txt +0 -0
  176. {ccxt-4.4.41.dist-info → ccxt-4.4.43.dist-info}/WHEEL +0 -0
  177. {ccxt-4.4.41.dist-info → ccxt-4.4.43.dist-info}/top_level.txt +0 -0
@@ -514,6 +514,92 @@ class coinex(Exchange, ImplicitAPI):
514
514
  # CSC, AE, BASE, AIPG, AKASH, POLKADOTASSETHUB ?, ALEO, STX, ALGO, ALPH, BLAST, AR, ARCH, ARDR, ARK, ARRR, MANTA, NTRN, LUNA, AURORA, AVAIL, ASC20, AVA, AYA, AZERO, BAN, BAND, BB, RUNES, BEAM, BELLSCOIN, BITCI, NEAR, AGORIC, BLOCX, BNC, BOBA, BRISE, KRC20, CANTO, CAPS, CCD, CELO, CFX, CHI, CKB, CLORE, CLV, CORE, CSPR, CTXC, DAG, DCR, DERO, DESO, DEFI, DGB, DNX, DOCK, DOGECHAIN, DYDX, DYMENSION, EGLD, ELA, ELF, ENJIN, EOSIO, ERG, ETN_SC, EVMOS, EWC, SGB, FACT, FB, FET, FIO, FIRO, NEO3, FLOW, FLARE, FLUX, LINEA, FREN, FSN, FB_BRC20, GLMR, GRIN, GRS, HACASH, HBAR, HERB, HIVE, MAPO, HMND, HNS, ZKSYNC, HTR, HUAHUA, MERLIN, ICP, ICX, INJ, IOST, IOTA, IOTX, IRIS, IRON, ONE, JOYSTREAM, KAI, KAR, KAS, KAVA, KCN, KDA, KLAY, KLY, KMD, KSM, KUB, KUJIRA, LAT, LBC, LUNC, LUKSO, MARS, METIS, MINA, MANTLE, MOB, MODE, MONA, MOVR, MTL, NEOX, NEXA, NIBI, NIMIQ, NMC, ONOMY, NRG, WAVES, NULS, OAS, OCTA, OLT, ONT, OORT, ORAI, OSMO, P3D, COMPOSABLE, PIVX, RON, POKT, POLYMESH, PRE_MARKET, PYI, QKC, QTUM, QUBIC, RSK, ROSE, ROUTE, RTM, THORCHAIN, RVN, RADIANT, SAGA, SALVIUM, SATOX, SC, SCP, _NULL, SCRT, SDN, RGBPP, SELF, SMH, SPACE, STARGAZE, STC, STEEM, STRATISEVM, STRD, STARKNET, SXP, SYS, TAIKO, TAO, TARA, TENET, THETA, TT, VENOM, VECHAIN, TOMO, VITE, VLX, VSYS, VTC, WAN, WAXP, WEMIX, XCH, XDC, XEC, XELIS, NEM, XHV, XLM, XNA, NANO, XPLA, XPR, XPRT, XRD, XTZ, XVG, XYM, ZANO, ZEC, ZEN, ZEPH, ZETA
515
515
  },
516
516
  },
517
+ 'features': {
518
+ 'spot': {
519
+ 'sandbox': False,
520
+ 'createOrder': {
521
+ 'marginMode': True,
522
+ 'triggerPrice': True,
523
+ 'triggerPriceType': None,
524
+ 'triggerDirection': False,
525
+ 'stopLossPrice': False, # todo
526
+ 'takeProfitPrice': False, # todo
527
+ 'attachedStopLossTakeProfit': None,
528
+ 'timeInForce': {
529
+ 'IOC': True,
530
+ 'FOK': True,
531
+ 'PO': True,
532
+ 'GTD': False,
533
+ },
534
+ 'hedged': False,
535
+ 'trailing': False,
536
+ # exchange-supported features
537
+ # 'marketBuyRequiresPrice': True,
538
+ # 'marketBuyByCost': True,
539
+ # 'selfTradePrevention': True,
540
+ # 'iceberg': True,
541
+ },
542
+ 'createOrders': {
543
+ 'max': 5,
544
+ },
545
+ 'fetchMyTrades': {
546
+ 'marginMode': True,
547
+ 'limit': 1000,
548
+ 'daysBack': None,
549
+ 'untilDays': 100000,
550
+ },
551
+ 'fetchOrder': {
552
+ 'marginMode': False,
553
+ 'trigger': False,
554
+ 'trailing': False,
555
+ },
556
+ 'fetchOpenOrders': {
557
+ 'marginMode': True,
558
+ 'limit': 1000,
559
+ 'trigger': True,
560
+ 'trailing': False,
561
+ },
562
+ 'fetchOrders': None,
563
+ 'fetchClosedOrders': {
564
+ 'marginMode': True,
565
+ 'limit': 1000,
566
+ 'daysBackClosed': None,
567
+ 'daysBackCanceled': None,
568
+ 'untilDays': None,
569
+ 'trigger': True,
570
+ 'trailing': False,
571
+ },
572
+ 'fetchOHLCV': {
573
+ 'limit': 1000,
574
+ },
575
+ },
576
+ 'forDerivatives': {
577
+ 'extends': 'spot',
578
+ 'createOrder': {
579
+ 'marginMode': True,
580
+ 'stopLossPrice': True,
581
+ 'takeProfitPrice': True,
582
+ },
583
+ 'fetchOpenOrders': {
584
+ 'marginMode': False,
585
+ },
586
+ 'fetchClosedOrders': {
587
+ 'marginMode': False,
588
+ },
589
+ },
590
+ 'swap': {
591
+ 'linear': {
592
+ 'extends': 'forDerivatives',
593
+ },
594
+ 'inverse': {
595
+ 'extends': 'forDerivatives',
596
+ },
597
+ },
598
+ 'future': {
599
+ 'linear': None,
600
+ 'inverse': None,
601
+ },
602
+ },
517
603
  'commonCurrencies': {
518
604
  'ACM': 'Actinium',
519
605
  },
@@ -1978,7 +2064,6 @@ class coinex(Exchange, ImplicitAPI):
1978
2064
  'reduceOnly': None,
1979
2065
  'side': side,
1980
2066
  'price': self.safe_string(order, 'price'),
1981
- 'stopPrice': self.safe_string(order, 'trigger_price'),
1982
2067
  'triggerPrice': self.safe_string(order, 'trigger_price'),
1983
2068
  'takeProfitPrice': self.safe_number(order, 'take_profit_price'),
1984
2069
  'stopLossPrice': self.safe_number(order, 'stop_loss_price'),
@@ -2018,7 +2103,7 @@ class coinex(Exchange, ImplicitAPI):
2018
2103
  market = self.market(symbol)
2019
2104
  swap = market['swap']
2020
2105
  clientOrderId = self.safe_string_2(params, 'client_id', 'clientOrderId')
2021
- stopPrice = self.safe_string_2(params, 'stopPrice', 'triggerPrice')
2106
+ triggerPrice = self.safe_string_2(params, 'stopPrice', 'triggerPrice')
2022
2107
  stopLossPrice = self.safe_string(params, 'stopLossPrice')
2023
2108
  takeProfitPrice = self.safe_string(params, 'takeProfitPrice')
2024
2109
  option = self.safe_string(params, 'option')
@@ -2063,8 +2148,8 @@ class coinex(Exchange, ImplicitAPI):
2063
2148
  request['take_profit_type'] = self.safe_string(params, 'stop_type', 'latest_price')
2064
2149
  else:
2065
2150
  request['amount'] = self.amount_to_precision(symbol, amount)
2066
- if stopPrice is not None:
2067
- request['trigger_price'] = self.price_to_precision(symbol, stopPrice)
2151
+ if triggerPrice is not None:
2152
+ request['trigger_price'] = self.price_to_precision(symbol, triggerPrice)
2068
2153
  request['trigger_price_type'] = self.safe_string(params, 'stop_type', 'latest_price')
2069
2154
  else:
2070
2155
  marginMode = None
@@ -2091,8 +2176,8 @@ class coinex(Exchange, ImplicitAPI):
2091
2176
  request['amount'] = self.cost_to_precision(symbol, amount)
2092
2177
  else:
2093
2178
  request['amount'] = self.amount_to_precision(symbol, amount)
2094
- if stopPrice is not None:
2095
- request['trigger_price'] = self.price_to_precision(symbol, stopPrice)
2179
+ if triggerPrice is not None:
2180
+ request['trigger_price'] = self.price_to_precision(symbol, triggerPrice)
2096
2181
  params = self.omit(params, ['reduceOnly', 'timeInForce', 'postOnly', 'stopPrice', 'triggerPrice', 'stopLossPrice', 'takeProfitPrice'])
2097
2182
  return self.extend(request, params)
2098
2183
 
@@ -1504,7 +1504,7 @@ class coinlist(Exchange, ImplicitAPI):
1504
1504
  elif type == 'limit':
1505
1505
  request['type'] = 'stop_limit'
1506
1506
  elif (type == 'stop_market') or (type == 'stop_limit') or (type == 'take_market') or (type == 'take_limit'):
1507
- raise ArgumentsRequired(self.id + ' createOrder() requires a stopPrice parameter for stop-loss and take-profit orders')
1507
+ raise ArgumentsRequired(self.id + ' createOrder() requires a triggerPrice parameter for stop-loss and take-profit orders')
1508
1508
  clientOrderId = self.safe_string_2(params, 'clientOrderId', 'client_id')
1509
1509
  if clientOrderId is not None:
1510
1510
  request['client_id'] = clientOrderId
@@ -1643,7 +1643,7 @@ class coinlist(Exchange, ImplicitAPI):
1643
1643
  type = self.parse_order_type(self.safe_string(order, 'type'))
1644
1644
  side = self.safe_string(order, 'side')
1645
1645
  price = self.safe_string(order, 'price')
1646
- stopPrice = self.safe_string(order, 'stop_price')
1646
+ triggerPrice = self.safe_string(order, 'stop_price')
1647
1647
  average = self.safe_string(order, 'average_fill_price') # from documentation
1648
1648
  amount = self.safe_string(order, 'size')
1649
1649
  filled = self.safe_string(order, 'size_filled')
@@ -1668,8 +1668,7 @@ class coinlist(Exchange, ImplicitAPI):
1668
1668
  'timeInForce': 'GTC',
1669
1669
  'side': side,
1670
1670
  'price': price,
1671
- 'stopPrice': stopPrice,
1672
- 'triggerPrice': stopPrice,
1671
+ 'triggerPrice': triggerPrice,
1673
1672
  'average': average,
1674
1673
  'amount': amount,
1675
1674
  'cost': None,
@@ -938,7 +938,6 @@ class coinmate(Exchange, ImplicitAPI):
938
938
  marketId = self.safe_string(order, 'currencyPair')
939
939
  symbol = self.safe_symbol(marketId, market, '_')
940
940
  clientOrderId = self.safe_string(order, 'clientOrderId')
941
- stopPrice = self.safe_number(order, 'stopPrice')
942
941
  return self.safe_order({
943
942
  'id': id,
944
943
  'clientOrderId': clientOrderId,
@@ -951,8 +950,7 @@ class coinmate(Exchange, ImplicitAPI):
951
950
  'postOnly': None,
952
951
  'side': side,
953
952
  'price': priceString,
954
- 'stopPrice': stopPrice,
955
- 'triggerPrice': stopPrice,
953
+ 'triggerPrice': self.safe_number(order, 'stopPrice'),
956
954
  'amount': amountString,
957
955
  'cost': None,
958
956
  'average': averageString,
@@ -1202,10 +1202,10 @@ class coinmetro(Exchange, ImplicitAPI):
1202
1202
  if timeInForce is not None:
1203
1203
  params = self.omit(params, 'timeInForce')
1204
1204
  request['timeInForce'] = self.encode_order_time_in_force(timeInForce)
1205
- stopPrice = self.safe_string_2(params, 'triggerPrice', 'stopPrice')
1206
- if stopPrice is not None:
1205
+ triggerPrice = self.safe_string_2(params, 'triggerPrice', 'stopPrice')
1206
+ if triggerPrice is not None:
1207
1207
  params = self.omit(params, ['triggerPrice'])
1208
- request['stopPrice'] = self.price_to_precision(symbol, stopPrice)
1208
+ request['stopPrice'] = self.price_to_precision(symbol, triggerPrice)
1209
1209
  userData = self.safe_value(params, 'userData', {})
1210
1210
  comment = self.safe_string_2(params, 'clientOrderId', 'comment')
1211
1211
  if comment is not None:
@@ -1706,7 +1706,6 @@ class coinmetro(Exchange, ImplicitAPI):
1706
1706
  }
1707
1707
  trades = self.safe_value(order, 'fills', [])
1708
1708
  userData = self.safe_value(order, 'userData', {})
1709
- triggerPrice = self.safe_string(order, 'stopPrice')
1710
1709
  clientOrderId = self.safe_string(userData, 'comment')
1711
1710
  takeProfitPrice = self.safe_string(userData, 'takeProfit')
1712
1711
  stopLossPrice = self.safe_string(userData, 'stopLoss')
@@ -1722,7 +1721,7 @@ class coinmetro(Exchange, ImplicitAPI):
1722
1721
  'timeInForce': self.parse_order_time_in_force(self.safe_integer(order, 'timeInForce')),
1723
1722
  'side': side,
1724
1723
  'price': price,
1725
- 'triggerPrice': triggerPrice,
1724
+ 'triggerPrice': self.safe_string(order, 'stopPrice'),
1726
1725
  'takeProfitPrice': takeProfitPrice,
1727
1726
  'stopLossPrice': stopLossPrice,
1728
1727
  'average': None,
@@ -915,7 +915,6 @@ class coinone(Exchange, ImplicitAPI):
915
915
  'postOnly': None,
916
916
  'side': side,
917
917
  'price': self.safe_string(order, 'price'),
918
- 'stopPrice': None,
919
918
  'triggerPrice': None,
920
919
  'cost': None,
921
920
  'average': self.safe_string(order, 'averageExecutedPrice'),
@@ -1146,10 +1146,10 @@ class coinsph(Exchange, ImplicitAPI):
1146
1146
  quoteAmount = self.cost_to_precision(symbol, amount)
1147
1147
  request['quoteOrderQty'] = quoteAmount
1148
1148
  if orderType == 'STOP_LOSS' or orderType == 'STOP_LOSS_LIMIT' or orderType == 'TAKE_PROFIT' or orderType == 'TAKE_PROFIT_LIMIT':
1149
- stopPrice = self.safe_string_2(params, 'triggerPrice', 'stopPrice')
1150
- if stopPrice is None:
1149
+ triggerPrice = self.safe_string_2(params, 'triggerPrice', 'stopPrice')
1150
+ if triggerPrice is None:
1151
1151
  raise InvalidOrder(self.id + ' createOrder() requires a triggerPrice or stopPrice param for stop_loss, take_profit, stop_loss_limit, and take_profit_limit orders')
1152
- request['stopPrice'] = self.price_to_precision(symbol, stopPrice)
1152
+ request['stopPrice'] = self.price_to_precision(symbol, triggerPrice)
1153
1153
  request['newOrderRespType'] = newOrderRespType
1154
1154
  params = self.omit(params, 'price', 'stopPrice', 'triggerPrice', 'quantity', 'quoteOrderQty')
1155
1155
  response = None
@@ -1374,9 +1374,9 @@ class coinsph(Exchange, ImplicitAPI):
1374
1374
  market = self.safe_market(marketId, market)
1375
1375
  timestamp = self.safe_integer_2(order, 'time', 'transactTime')
1376
1376
  trades = self.safe_value(order, 'fills', None)
1377
- stopPrice = self.safe_string(order, 'stopPrice')
1378
- if Precise.string_eq(stopPrice, '0'):
1379
- stopPrice = None
1377
+ triggerPrice = self.safe_string(order, 'stopPrice')
1378
+ if Precise.string_eq(triggerPrice, '0'):
1379
+ triggerPrice = None
1380
1380
  return self.safe_order({
1381
1381
  'id': id,
1382
1382
  'clientOrderId': self.safe_string(order, 'clientOrderId'),
@@ -1389,8 +1389,7 @@ class coinsph(Exchange, ImplicitAPI):
1389
1389
  'timeInForce': self.parse_order_time_in_force(self.safe_string(order, 'timeInForce')),
1390
1390
  'side': self.parse_order_side(self.safe_string(order, 'side')),
1391
1391
  'price': self.safe_string(order, 'price'),
1392
- 'stopPrice': stopPrice,
1393
- 'triggerPrice': stopPrice,
1392
+ 'triggerPrice': triggerPrice,
1394
1393
  'average': None,
1395
1394
  'amount': self.safe_string(order, 'origQty'),
1396
1395
  'cost': self.safe_string(order, 'cummulativeQuoteQty'),
@@ -507,6 +507,9 @@ class cryptocom(Exchange, ImplicitAPI):
507
507
  '40801': RequestTimeout,
508
508
  '42901': RateLimitExceeded,
509
509
  '43005': InvalidOrder, # Rejected POST_ONLY create-order request(normally happened when exec_inst contains POST_ONLY but time_in_force is NOT GOOD_TILL_CANCEL)
510
+ '43003': InvalidOrder, # FOK order has not been filled and cancelled
511
+ '43004': InvalidOrder, # IOC order has not been filled and cancelled
512
+ '43012': BadRequest, # Canceled due to Self Trade Prevention
510
513
  '50001': ExchangeError,
511
514
  '9010001': OnMaintenance, # {"code":9010001,"message":"SYSTEM_MAINTENANCE","details":"Crypto.com Exchange is currently under maintenance. Please refer to https://status.crypto.com for more details."}
512
515
  },
@@ -1198,7 +1198,6 @@ class currencycom(Exchange, ImplicitAPI):
1198
1198
  'timeInForce': timeInForce,
1199
1199
  'side': side,
1200
1200
  'price': price,
1201
- 'stopPrice': None,
1202
1201
  'triggerPrice': None,
1203
1202
  'amount': amount,
1204
1203
  'cost': None,
@@ -1296,11 +1295,11 @@ class currencycom(Exchange, ImplicitAPI):
1296
1295
  request['type'] = 'STOP'
1297
1296
  request['price'] = self.price_to_precision(symbol, price)
1298
1297
  elif type == 'market':
1299
- stopPrice = self.safe_value_2(params, 'triggerPrice', 'stopPrice')
1298
+ triggerPrice = self.safe_value_2(params, 'triggerPrice', 'stopPrice')
1300
1299
  params = self.omit(params, ['triggerPrice', 'stopPrice'])
1301
- if stopPrice is not None:
1300
+ if triggerPrice is not None:
1302
1301
  request['type'] = 'STOP'
1303
- request['price'] = self.price_to_precision(symbol, stopPrice)
1302
+ request['price'] = self.price_to_precision(symbol, triggerPrice)
1304
1303
  response = await self.privatePostV2Order(self.extend(request, params))
1305
1304
  #
1306
1305
  # limit
@@ -1157,7 +1157,7 @@ class defx(Exchange, ImplicitAPI):
1157
1157
  'type': orderType,
1158
1158
  }
1159
1159
  takeProfitPrice = self.safe_string(params, 'takeProfitPrice')
1160
- stopPrice = self.safe_string_2(params, 'stopPrice', 'triggerPrice')
1160
+ triggerPrice = self.safe_string_2(params, 'stopPrice', 'triggerPrice')
1161
1161
  isMarket = orderType == 'MARKET'
1162
1162
  isLimit = orderType == 'LIMIT'
1163
1163
  timeInForce = self.safe_string_upper(params, 'timeInForce')
@@ -1172,7 +1172,7 @@ class defx(Exchange, ImplicitAPI):
1172
1172
  clientOrderId = self.safe_string(params, 'clientOrderId')
1173
1173
  if clientOrderId is not None:
1174
1174
  request['newClientOrderId'] = clientOrderId
1175
- if stopPrice is not None or takeProfitPrice is not None:
1175
+ if triggerPrice is not None or takeProfitPrice is not None:
1176
1176
  request['workingType'] = 'MARK_PRICE'
1177
1177
  if takeProfitPrice is not None:
1178
1178
  request['stopPrice'] = self.price_to_precision(symbol, takeProfitPrice)
@@ -1181,7 +1181,7 @@ class defx(Exchange, ImplicitAPI):
1181
1181
  else:
1182
1182
  request['type'] = 'TAKE_PROFIT_LIMIT'
1183
1183
  else:
1184
- request['stopPrice'] = self.price_to_precision(symbol, stopPrice)
1184
+ request['stopPrice'] = self.price_to_precision(symbol, triggerPrice)
1185
1185
  if isMarket:
1186
1186
  request['type'] = 'STOP_MARKET'
1187
1187
  else:
@@ -1268,12 +1268,12 @@ class defx(Exchange, ImplicitAPI):
1268
1268
  average = self.omit_zero(self.safe_string(order, 'avgPrice'))
1269
1269
  timeInForce = self.safe_string_lower(order, 'timeInForce')
1270
1270
  takeProfitPrice: Str = None
1271
- stopPrice: Str = None
1271
+ triggerPrice: Str = None
1272
1272
  if orderType is not None:
1273
1273
  if orderType.find('take_profit') >= 0:
1274
1274
  takeProfitPrice = self.safe_string(order, 'stopPrice')
1275
1275
  else:
1276
- stopPrice = self.safe_string(order, 'stopPrice')
1276
+ triggerPrice = self.safe_string(order, 'stopPrice')
1277
1277
  timestamp = self.parse8601(self.safe_string(order, 'createdAt'))
1278
1278
  lastTradeTimestamp = self.parse8601(self.safe_string(order, 'updatedAt'))
1279
1279
  return self.safe_order({
@@ -1291,8 +1291,7 @@ class defx(Exchange, ImplicitAPI):
1291
1291
  'reduceOnly': self.safe_bool(order, 'reduceOnly'),
1292
1292
  'side': side,
1293
1293
  'price': price,
1294
- 'stopPrice': stopPrice,
1295
- 'triggerPrice': stopPrice,
1294
+ 'triggerPrice': triggerPrice,
1296
1295
  'takeProfitPrice': takeProfitPrice,
1297
1296
  'stopLossPrice': None,
1298
1297
  'average': average,
@@ -1767,7 +1767,6 @@ class deribit(Exchange, ImplicitAPI):
1767
1767
  # injected in createOrder
1768
1768
  trades = self.safe_value(order, 'trades')
1769
1769
  timeInForce = self.parse_time_in_force(self.safe_string(order, 'time_in_force'))
1770
- stopPrice = self.safe_value(order, 'stop_price')
1771
1770
  postOnly = self.safe_value(order, 'post_only')
1772
1771
  return self.safe_order({
1773
1772
  'info': order,
@@ -1782,8 +1781,7 @@ class deribit(Exchange, ImplicitAPI):
1782
1781
  'postOnly': postOnly,
1783
1782
  'side': side,
1784
1783
  'price': priceString,
1785
- 'stopPrice': stopPrice,
1786
- 'triggerPrice': stopPrice,
1784
+ 'triggerPrice': self.safe_value(order, 'stop_price'),
1787
1785
  'amount': amount,
1788
1786
  'cost': cost,
1789
1787
  'average': averageString,
@@ -2025,7 +2025,6 @@ class digifinex(Exchange, ImplicitAPI):
2025
2025
  'postOnly': None,
2026
2026
  'side': side,
2027
2027
  'price': self.safe_number(order, 'price'),
2028
- 'stopPrice': None,
2029
2028
  'triggerPrice': None,
2030
2029
  'amount': self.safe_number_2(order, 'amount', 'size'),
2031
2030
  'filled': self.safe_number_2(order, 'executed_amount', 'filled_qty'),
@@ -1264,7 +1264,6 @@ class ellipx(Exchange, ImplicitAPI):
1264
1264
  'postOnly': postOnly,
1265
1265
  'side': side,
1266
1266
  'price': price,
1267
- 'stopPrice': None,
1268
1267
  'triggerPrice': None,
1269
1268
  'average': None,
1270
1269
  'cost': cost,
@@ -1323,7 +1322,6 @@ class ellipx(Exchange, ImplicitAPI):
1323
1322
  'postOnly': None,
1324
1323
  'side': None,
1325
1324
  'price': None,
1326
- 'stopPrice': None,
1327
1325
  'triggerPrice': None,
1328
1326
  'average': None,
1329
1327
  'cost': None,
@@ -1415,7 +1415,7 @@ class exmo(Exchange, ImplicitAPI):
1415
1415
  :param float amount: how much of currency you want to trade in units of base currency
1416
1416
  :param float [price]: the price at which the order is to be fulfilled, in units of the quote currency, ignored in market orders
1417
1417
  :param dict [params]: extra parameters specific to the exchange API endpoint
1418
- :param float [params.stopPrice]: the price at which a trigger order is triggered at
1418
+ :param float [params.triggerPrice]: the price at which a trigger order is triggered at
1419
1419
  :param str [params.timeInForce]: *spot only* 'fok', 'ioc' or 'post_only'
1420
1420
  :param boolean [params.postOnly]: *spot only* True for post only orders
1421
1421
  :param float [params.cost]: *spot only* *market orders only* the cost of the order in the quote currency for market orders
@@ -1904,7 +1904,6 @@ class exmo(Exchange, ImplicitAPI):
1904
1904
  'postOnly': None,
1905
1905
  'side': side,
1906
1906
  'price': price,
1907
- 'stopPrice': triggerPrice,
1908
1907
  'triggerPrice': triggerPrice,
1909
1908
  'cost': cost,
1910
1909
  'amount': amount,
@@ -3916,7 +3916,7 @@ class gate(Exchange, ImplicitAPI):
3916
3916
  :param float amount: the amount of currency to trade
3917
3917
  :param float [price]: the price at which the order is to be fulfilled, in units of the quote currency, ignored in market orders
3918
3918
  :param dict [params]: extra parameters specific to the exchange API endpoint
3919
- :param float [params.stopPrice]: The price at which a trigger order is triggered at
3919
+ :param float [params.triggerPrice]: The price at which a trigger order is triggered at
3920
3920
  :param str [params.timeInForce]: "GTC", "IOC", or "PO"
3921
3921
  :param float [params.stopLossPrice]: The price at which a stop loss order is triggered at
3922
3922
  :param float [params.takeProfitPrice]: The price at which a take profit order is triggered at
@@ -4664,7 +4664,6 @@ class gate(Exchange, ImplicitAPI):
4664
4664
  'reduceOnly': self.safe_value(order, 'is_reduce_only'),
4665
4665
  'side': side,
4666
4666
  'price': price,
4667
- 'stopPrice': triggerPrice,
4668
4667
  'triggerPrice': triggerPrice,
4669
4668
  'average': average,
4670
4669
  'amount': Precise.string_abs(amount),
@@ -311,6 +311,64 @@ class gemini(Exchange, ImplicitAPI):
311
311
  },
312
312
  },
313
313
  },
314
+ 'features': {
315
+ 'default': {
316
+ 'sandbox': True,
317
+ 'createOrder': {
318
+ 'marginMode': False,
319
+ 'triggerPrice': True,
320
+ 'triggerPriceType': None,
321
+ 'triggerDirection': False,
322
+ 'stopLossPrice': False, # todo
323
+ 'takeProfitPrice': False, # todo
324
+ 'attachedStopLossTakeProfit': None,
325
+ 'timeInForce': {
326
+ 'IOC': True,
327
+ 'FOK': True,
328
+ 'PO': True,
329
+ 'GTD': False,
330
+ },
331
+ 'hedged': False,
332
+ 'trailing': False,
333
+ },
334
+ 'createOrders': None,
335
+ 'fetchMyTrades': {
336
+ 'marginMode': False,
337
+ 'limit': 500,
338
+ 'daysBack': None,
339
+ 'untilDays': None,
340
+ },
341
+ 'fetchOrder': {
342
+ 'marginMode': False,
343
+ 'trigger': False,
344
+ 'trailing': False,
345
+ },
346
+ 'fetchOpenOrders': {
347
+ 'marginMode': False,
348
+ 'limit': None,
349
+ 'trigger': False,
350
+ 'trailing': False,
351
+ },
352
+ 'fetchOrders': None,
353
+ 'fetchClosedOrders': None, # todo: implement
354
+ 'fetchOHLCV': {
355
+ 'limit': None,
356
+ },
357
+ },
358
+ 'spot': {
359
+ 'extends': 'default',
360
+ },
361
+ 'swap': {
362
+ 'linear': {
363
+ 'extends': 'default',
364
+ },
365
+ 'inverse': None,
366
+ },
367
+ 'future': {
368
+ 'linear': None,
369
+ 'inverse': None,
370
+ },
371
+ },
314
372
  })
315
373
 
316
374
  async def fetch_currencies(self, params={}) -> Currencies:
@@ -1301,7 +1359,6 @@ class gemini(Exchange, ImplicitAPI):
1301
1359
  'postOnly': postOnly,
1302
1360
  'side': side,
1303
1361
  'price': price,
1304
- 'stopPrice': None,
1305
1362
  'triggerPrice': None,
1306
1363
  'average': average,
1307
1364
  'cost': None,
@@ -1432,12 +1489,12 @@ class gemini(Exchange, ImplicitAPI):
1432
1489
  }
1433
1490
  type = self.safe_string(params, 'type', type)
1434
1491
  params = self.omit(params, 'type')
1435
- rawStopPrice = self.safe_string_2(params, 'stop_price', 'stopPrice')
1436
- params = self.omit(params, ['stop_price', 'stopPrice', 'type'])
1492
+ triggerPrice = self.safe_string_n(params, ['triggerPrice', 'stop_price', 'stopPrice'])
1493
+ params = self.omit(params, ['triggerPrice', 'stop_price', 'stopPrice', 'type'])
1437
1494
  if type == 'stopLimit':
1438
- raise ArgumentsRequired(self.id + ' createOrder() requires a stopPrice parameter or a stop_price parameter for ' + type + ' orders')
1439
- if rawStopPrice is not None:
1440
- request['stop_price'] = self.price_to_precision(symbol, rawStopPrice)
1495
+ raise ArgumentsRequired(self.id + ' createOrder() requires a triggerPrice parameter or a stop_price parameter for ' + type + ' orders')
1496
+ if triggerPrice is not None:
1497
+ request['stop_price'] = self.price_to_precision(symbol, triggerPrice)
1441
1498
  request['type'] = 'exchange stop limit'
1442
1499
  else:
1443
1500
  # No options can be applied to stop-limit orders at self time.