ccxt 4.4.38__py2.py3-none-any.whl → 4.4.40__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ccxt/__init__.py +1 -1
- ccxt/abstract/digifinex.py +1 -0
- ccxt/abstract/mexc.py +1 -0
- ccxt/abstract/woo.py +2 -2
- ccxt/alpaca.py +74 -3
- ccxt/ascendex.py +9 -9
- ccxt/async_support/__init__.py +1 -1
- ccxt/async_support/alpaca.py +74 -3
- ccxt/async_support/ascendex.py +9 -9
- ccxt/async_support/base/exchange.py +1 -1
- ccxt/async_support/base/ws/aiohttp_client.py +2 -2
- ccxt/async_support/binance.py +13 -17
- ccxt/async_support/bingx.py +1 -2
- ccxt/async_support/bit2c.py +0 -1
- ccxt/async_support/bitbank.py +0 -1
- ccxt/async_support/bitbns.py +0 -1
- ccxt/async_support/bitfinex.py +15 -16
- ccxt/async_support/bitfinex1.py +0 -1
- ccxt/async_support/bitflyer.py +0 -1
- ccxt/async_support/bitget.py +1 -2
- ccxt/async_support/bithumb.py +0 -1
- ccxt/async_support/bitmart.py +3 -4
- ccxt/async_support/bitmex.py +5 -6
- ccxt/async_support/bitopro.py +4 -5
- ccxt/async_support/bitrue.py +5 -7
- ccxt/async_support/bitso.py +1 -2
- ccxt/async_support/bitstamp.py +1 -2
- ccxt/async_support/bitteam.py +1 -3
- ccxt/async_support/bitvavo.py +2 -4
- ccxt/async_support/blockchaincom.py +5 -5
- ccxt/async_support/blofin.py +10 -10
- ccxt/async_support/btcalpha.py +0 -1
- ccxt/async_support/btcbox.py +0 -1
- ccxt/async_support/btcmarkets.py +1 -3
- ccxt/async_support/bybit.py +2 -3
- ccxt/async_support/cex.py +1 -1
- ccxt/async_support/coinbase.py +77 -1
- ccxt/async_support/coinbaseexchange.py +1 -1
- ccxt/async_support/coinbaseinternational.py +62 -0
- ccxt/async_support/coincatch.py +1 -1
- ccxt/async_support/coinex.py +9 -9
- ccxt/async_support/coinlist.py +1 -1
- ccxt/async_support/coinmetro.py +1 -1
- ccxt/async_support/cryptocom.py +91 -2
- ccxt/async_support/currencycom.py +1 -1
- ccxt/async_support/defx.py +1 -2
- ccxt/async_support/delta.py +1 -1
- ccxt/async_support/digifinex.py +58 -19
- ccxt/async_support/exmo.py +2 -2
- ccxt/async_support/gate.py +1 -1
- ccxt/async_support/hashkey.py +3 -5
- ccxt/async_support/htx.py +155 -33
- ccxt/async_support/hyperliquid.py +1 -1
- ccxt/async_support/kraken.py +1 -1
- ccxt/async_support/kucoin.py +25 -24
- ccxt/async_support/luno.py +1 -1
- ccxt/async_support/mexc.py +173 -26
- ccxt/async_support/ndax.py +1 -1
- ccxt/async_support/okcoin.py +18 -18
- ccxt/async_support/okx.py +22 -21
- ccxt/async_support/phemex.py +12 -8
- ccxt/async_support/poloniex.py +1 -1
- ccxt/async_support/poloniexfutures.py +6 -6
- ccxt/async_support/vertex.py +11 -11
- ccxt/async_support/woo.py +39 -39
- ccxt/async_support/woofipro.py +24 -24
- ccxt/async_support/xt.py +26 -26
- ccxt/async_support/zonda.py +1 -1
- ccxt/base/exchange.py +32 -25
- ccxt/binance.py +13 -17
- ccxt/bingx.py +1 -2
- ccxt/bit2c.py +0 -1
- ccxt/bitbank.py +0 -1
- ccxt/bitbns.py +0 -1
- ccxt/bitfinex.py +15 -16
- ccxt/bitfinex1.py +0 -1
- ccxt/bitflyer.py +0 -1
- ccxt/bitget.py +1 -2
- ccxt/bithumb.py +0 -1
- ccxt/bitmart.py +3 -4
- ccxt/bitmex.py +5 -6
- ccxt/bitopro.py +4 -5
- ccxt/bitrue.py +5 -7
- ccxt/bitso.py +1 -2
- ccxt/bitstamp.py +1 -2
- ccxt/bitteam.py +1 -3
- ccxt/bitvavo.py +2 -4
- ccxt/blockchaincom.py +5 -5
- ccxt/blofin.py +10 -10
- ccxt/btcalpha.py +0 -1
- ccxt/btcbox.py +0 -1
- ccxt/btcmarkets.py +1 -3
- ccxt/bybit.py +2 -3
- ccxt/cex.py +1 -1
- ccxt/coinbase.py +77 -1
- ccxt/coinbaseexchange.py +1 -1
- ccxt/coinbaseinternational.py +62 -0
- ccxt/coincatch.py +1 -1
- ccxt/coinex.py +9 -9
- ccxt/coinlist.py +1 -1
- ccxt/coinmetro.py +1 -1
- ccxt/cryptocom.py +91 -2
- ccxt/currencycom.py +1 -1
- ccxt/defx.py +1 -2
- ccxt/delta.py +1 -1
- ccxt/digifinex.py +58 -19
- ccxt/exmo.py +2 -2
- ccxt/gate.py +1 -1
- ccxt/hashkey.py +3 -5
- ccxt/htx.py +155 -33
- ccxt/hyperliquid.py +1 -1
- ccxt/kraken.py +1 -1
- ccxt/kucoin.py +25 -24
- ccxt/luno.py +1 -1
- ccxt/mexc.py +173 -26
- ccxt/ndax.py +1 -1
- ccxt/okcoin.py +18 -18
- ccxt/okx.py +22 -21
- ccxt/phemex.py +12 -8
- ccxt/poloniex.py +1 -1
- ccxt/poloniexfutures.py +6 -6
- ccxt/pro/__init__.py +1 -1
- ccxt/pro/bitget.py +1 -1
- ccxt/pro/bybit.py +12 -1
- ccxt/pro/coinex.py +2 -2
- ccxt/pro/gate.py +6 -6
- ccxt/pro/kucoin.py +3 -3
- ccxt/pro/okx.py +11 -11
- ccxt/pro/upbit.py +2 -2
- ccxt/pro/woo.py +1 -1
- ccxt/vertex.py +11 -11
- ccxt/woo.py +39 -39
- ccxt/woofipro.py +24 -24
- ccxt/xt.py +26 -26
- ccxt/zonda.py +1 -1
- {ccxt-4.4.38.dist-info → ccxt-4.4.40.dist-info}/METADATA +4 -4
- {ccxt-4.4.38.dist-info → ccxt-4.4.40.dist-info}/RECORD +140 -140
- {ccxt-4.4.38.dist-info → ccxt-4.4.40.dist-info}/LICENSE.txt +0 -0
- {ccxt-4.4.38.dist-info → ccxt-4.4.40.dist-info}/WHEEL +0 -0
- {ccxt-4.4.38.dist-info → ccxt-4.4.40.dist-info}/top_level.txt +0 -0
ccxt/woofipro.py
CHANGED
@@ -1264,15 +1264,15 @@ class woofipro(Exchange, ImplicitAPI):
|
|
1264
1264
|
stopLoss = self.safe_value(params, 'stopLoss')
|
1265
1265
|
takeProfit = self.safe_value(params, 'takeProfit')
|
1266
1266
|
algoType = self.safe_string(params, 'algoType')
|
1267
|
-
|
1267
|
+
isConditional = stopPrice is not None or stopLoss is not None or takeProfit is not None or (self.safe_value(params, 'childOrders') is not None)
|
1268
1268
|
isMarket = orderType == 'MARKET'
|
1269
1269
|
timeInForce = self.safe_string_lower(params, 'timeInForce')
|
1270
1270
|
postOnly = self.is_post_only(isMarket, None, params)
|
1271
|
-
orderQtyKey = 'quantity' if
|
1272
|
-
priceKey = 'price' if
|
1273
|
-
typeKey = 'type' if
|
1271
|
+
orderQtyKey = 'quantity' if isConditional else 'order_quantity'
|
1272
|
+
priceKey = 'price' if isConditional else 'order_price'
|
1273
|
+
typeKey = 'type' if isConditional else 'order_type'
|
1274
1274
|
request[typeKey] = orderType # LIMIT/MARKET/IOC/FOK/POST_ONLY/ASK/BID
|
1275
|
-
if not
|
1275
|
+
if not isConditional:
|
1276
1276
|
if postOnly:
|
1277
1277
|
request['order_type'] = 'POST_ONLY'
|
1278
1278
|
elif timeInForce == 'fok':
|
@@ -1283,7 +1283,7 @@ class woofipro(Exchange, ImplicitAPI):
|
|
1283
1283
|
request['reduce_only'] = reduceOnly
|
1284
1284
|
if price is not None:
|
1285
1285
|
request[priceKey] = self.price_to_precision(symbol, price)
|
1286
|
-
if isMarket and not
|
1286
|
+
if isMarket and not isConditional:
|
1287
1287
|
request[orderQtyKey] = self.amount_to_precision(symbol, amount)
|
1288
1288
|
elif algoType != 'POSITIONAL_TP_SL':
|
1289
1289
|
request[orderQtyKey] = self.amount_to_precision(symbol, amount)
|
@@ -1355,9 +1355,9 @@ class woofipro(Exchange, ImplicitAPI):
|
|
1355
1355
|
stopPrice = self.safe_string_2(params, 'triggerPrice', 'stopPrice')
|
1356
1356
|
stopLoss = self.safe_value(params, 'stopLoss')
|
1357
1357
|
takeProfit = self.safe_value(params, 'takeProfit')
|
1358
|
-
|
1358
|
+
isConditional = stopPrice is not None or stopLoss is not None or takeProfit is not None or (self.safe_value(params, 'childOrders') is not None)
|
1359
1359
|
response = None
|
1360
|
-
if
|
1360
|
+
if isConditional:
|
1361
1361
|
response = self.v1PrivatePostAlgoOrder(request)
|
1362
1362
|
#
|
1363
1363
|
# {
|
@@ -1417,8 +1417,8 @@ class woofipro(Exchange, ImplicitAPI):
|
|
1417
1417
|
stopPrice = self.safe_string_2(orderParams, 'triggerPrice', 'stopPrice')
|
1418
1418
|
stopLoss = self.safe_value(orderParams, 'stopLoss')
|
1419
1419
|
takeProfit = self.safe_value(orderParams, 'takeProfit')
|
1420
|
-
|
1421
|
-
if
|
1420
|
+
isConditional = stopPrice is not None or stopLoss is not None or takeProfit is not None or (self.safe_value(orderParams, 'childOrders') is not None)
|
1421
|
+
if isConditional:
|
1422
1422
|
raise NotSupported(self.id + 'createOrders() only support non-stop order')
|
1423
1423
|
orderRequest = self.create_order_request(marketId, type, side, amount, price, orderParams)
|
1424
1424
|
ordersRequests.append(orderRequest)
|
@@ -1474,16 +1474,16 @@ class woofipro(Exchange, ImplicitAPI):
|
|
1474
1474
|
stopPrice = self.safe_string_n(params, ['triggerPrice', 'stopPrice', 'takeProfitPrice', 'stopLossPrice'])
|
1475
1475
|
if stopPrice is not None:
|
1476
1476
|
request['triggerPrice'] = self.price_to_precision(symbol, stopPrice)
|
1477
|
-
|
1478
|
-
orderQtyKey = 'quantity' if
|
1479
|
-
priceKey = 'price' if
|
1477
|
+
isConditional = (stopPrice is not None) or (self.safe_value(params, 'childOrders') is not None)
|
1478
|
+
orderQtyKey = 'quantity' if isConditional else 'order_quantity'
|
1479
|
+
priceKey = 'price' if isConditional else 'order_price'
|
1480
1480
|
if price is not None:
|
1481
1481
|
request[priceKey] = self.price_to_precision(symbol, price)
|
1482
1482
|
if amount is not None:
|
1483
1483
|
request[orderQtyKey] = self.amount_to_precision(symbol, amount)
|
1484
1484
|
params = self.omit(params, ['stopPrice', 'triggerPrice', 'takeProfitPrice', 'stopLossPrice', 'trailingTriggerPrice', 'trailingAmount', 'trailingPercent'])
|
1485
1485
|
response = None
|
1486
|
-
if
|
1486
|
+
if isConditional:
|
1487
1487
|
response = self.v1PrivatePutAlgoOrder(self.extend(request, params))
|
1488
1488
|
else:
|
1489
1489
|
request['symbol'] = market['id']
|
@@ -1536,9 +1536,9 @@ class woofipro(Exchange, ImplicitAPI):
|
|
1536
1536
|
:param str [params.clientOrderId]: a unique id for the order
|
1537
1537
|
:returns dict: An `order structure <https://docs.ccxt.com/#/?id=order-structure>`
|
1538
1538
|
"""
|
1539
|
-
|
1539
|
+
trigger = self.safe_bool_2(params, 'stop', 'trigger', False)
|
1540
1540
|
params = self.omit(params, ['stop', 'trigger'])
|
1541
|
-
if not
|
1541
|
+
if not trigger and (symbol is None):
|
1542
1542
|
raise ArgumentsRequired(self.id + ' cancelOrder() requires a symbol argument')
|
1543
1543
|
self.load_markets()
|
1544
1544
|
market: Market = None
|
@@ -1551,7 +1551,7 @@ class woofipro(Exchange, ImplicitAPI):
|
|
1551
1551
|
clientOrderIdExchangeSpecific = self.safe_string(params, 'client_order_id', clientOrderIdUnified)
|
1552
1552
|
isByClientOrder = clientOrderIdExchangeSpecific is not None
|
1553
1553
|
response = None
|
1554
|
-
if
|
1554
|
+
if trigger:
|
1555
1555
|
if isByClientOrder:
|
1556
1556
|
request['client_order_id'] = clientOrderIdExchangeSpecific
|
1557
1557
|
params = self.omit(params, ['clOrdID', 'clientOrderId', 'client_order_id'])
|
@@ -1587,7 +1587,7 @@ class woofipro(Exchange, ImplicitAPI):
|
|
1587
1587
|
extendParams['client_order_id'] = clientOrderIdExchangeSpecific
|
1588
1588
|
else:
|
1589
1589
|
extendParams['id'] = id
|
1590
|
-
if
|
1590
|
+
if trigger:
|
1591
1591
|
return self.extend(self.parse_order(response), extendParams)
|
1592
1592
|
data = self.safe_dict(response, 'data', {})
|
1593
1593
|
return self.extend(self.parse_order(data), extendParams)
|
@@ -1642,18 +1642,18 @@ class woofipro(Exchange, ImplicitAPI):
|
|
1642
1642
|
:returns dict: an list of `order structures <https://docs.ccxt.com/#/?id=order-structure>`
|
1643
1643
|
"""
|
1644
1644
|
self.load_markets()
|
1645
|
-
|
1645
|
+
trigger = self.safe_bool_2(params, 'stop', 'trigger')
|
1646
1646
|
params = self.omit(params, ['stop', 'trigger'])
|
1647
1647
|
request: dict = {}
|
1648
1648
|
if symbol is not None:
|
1649
1649
|
market = self.market(symbol)
|
1650
1650
|
request['symbol'] = market['id']
|
1651
1651
|
response = None
|
1652
|
-
if
|
1652
|
+
if trigger:
|
1653
1653
|
response = self.v1PrivateDeleteAlgoOrders(self.extend(request, params))
|
1654
1654
|
else:
|
1655
1655
|
response = self.v1PrivateDeleteOrders(self.extend(request, params))
|
1656
|
-
#
|
1656
|
+
# trigger
|
1657
1657
|
# {
|
1658
1658
|
# "success": True,
|
1659
1659
|
# "timestamp": 1702989203989,
|
@@ -1692,12 +1692,12 @@ class woofipro(Exchange, ImplicitAPI):
|
|
1692
1692
|
"""
|
1693
1693
|
self.load_markets()
|
1694
1694
|
market = self.market(symbol) if (symbol is not None) else None
|
1695
|
-
|
1695
|
+
trigger = self.safe_bool_2(params, 'stop', 'trigger', False)
|
1696
1696
|
request: dict = {}
|
1697
1697
|
clientOrderId = self.safe_string_n(params, ['clOrdID', 'clientOrderId', 'client_order_id'])
|
1698
1698
|
params = self.omit(params, ['stop', 'trigger', 'clOrdID', 'clientOrderId', 'client_order_id'])
|
1699
1699
|
response = None
|
1700
|
-
if
|
1700
|
+
if trigger:
|
1701
1701
|
if clientOrderId:
|
1702
1702
|
request['client_order_id'] = clientOrderId
|
1703
1703
|
response = self.v1PrivateGetAlgoClientOrderClientOrderId(self.extend(request, params))
|
@@ -2107,7 +2107,7 @@ class woofipro(Exchange, ImplicitAPI):
|
|
2107
2107
|
:param int [since]: timestamp in ms of the earliest ledger entry, default is None
|
2108
2108
|
:param int [limit]: max number of ledger entries to return, default is None
|
2109
2109
|
:param dict [params]: extra parameters specific to the exchange API endpoint
|
2110
|
-
:returns dict: a `ledger structure <https://docs.ccxt.com/#/?id=ledger
|
2110
|
+
:returns dict: a `ledger structure <https://docs.ccxt.com/#/?id=ledger>`
|
2111
2111
|
"""
|
2112
2112
|
currency, rows = self.get_asset_history_rows(code, since, limit, params)
|
2113
2113
|
return self.parse_ledger(rows, currency, since, limit, params)
|
ccxt/xt.py
CHANGED
@@ -2376,7 +2376,7 @@ class xt(Exchange, ImplicitAPI):
|
|
2376
2376
|
:param str id: order id
|
2377
2377
|
:param str [symbol]: unified symbol of the market the order was made in
|
2378
2378
|
:param dict params: extra parameters specific to the xt api endpoint
|
2379
|
-
:param bool [params.
|
2379
|
+
:param bool [params.trigger]: if the order is a trigger order or not
|
2380
2380
|
:param bool [params.stopLossTakeProfit]: if the order is a stop-loss or take-profit order
|
2381
2381
|
:returns dict: An `order structure <https://docs.ccxt.com/en/latest/manual.html#order-structure>`
|
2382
2382
|
"""
|
@@ -2390,15 +2390,15 @@ class xt(Exchange, ImplicitAPI):
|
|
2390
2390
|
response = None
|
2391
2391
|
type, params = self.handle_market_type_and_params('fetchOrder', market, params)
|
2392
2392
|
subType, params = self.handle_sub_type_and_params('fetchOrder', market, params)
|
2393
|
-
|
2393
|
+
trigger = self.safe_value(params, 'stop')
|
2394
2394
|
stopLossTakeProfit = self.safe_value(params, 'stopLossTakeProfit')
|
2395
|
-
if
|
2395
|
+
if trigger:
|
2396
2396
|
request['entrustId'] = id
|
2397
2397
|
elif stopLossTakeProfit:
|
2398
2398
|
request['profitId'] = id
|
2399
2399
|
else:
|
2400
2400
|
request['orderId'] = id
|
2401
|
-
if
|
2401
|
+
if trigger:
|
2402
2402
|
params = self.omit(params, 'stop')
|
2403
2403
|
if subType == 'inverse':
|
2404
2404
|
response = self.privateInverseGetFutureTradeV1EntrustPlanDetail(self.extend(request, params))
|
@@ -2548,7 +2548,7 @@ class xt(Exchange, ImplicitAPI):
|
|
2548
2548
|
:param int [since]: timestamp in ms of the earliest order
|
2549
2549
|
:param int [limit]: the maximum number of order structures to retrieve
|
2550
2550
|
:param dict params: extra parameters specific to the xt api endpoint
|
2551
|
-
:param bool [params.
|
2551
|
+
:param bool [params.trigger]: if the order is a trigger order or not
|
2552
2552
|
:returns dict[]: a list of `order structures <https://docs.ccxt.com/en/latest/manual.html#order-structure>`
|
2553
2553
|
"""
|
2554
2554
|
self.load_markets()
|
@@ -2566,9 +2566,9 @@ class xt(Exchange, ImplicitAPI):
|
|
2566
2566
|
response = None
|
2567
2567
|
type, params = self.handle_market_type_and_params('fetchOrders', market, params)
|
2568
2568
|
subType, params = self.handle_sub_type_and_params('fetchOrders', market, params)
|
2569
|
-
|
2570
|
-
if
|
2571
|
-
params = self.omit(params, 'stop')
|
2569
|
+
trigger = self.safe_value_2(params, 'trigger', 'stop')
|
2570
|
+
if trigger:
|
2571
|
+
params = self.omit(params, ['trigger', 'stop'])
|
2572
2572
|
if subType == 'inverse':
|
2573
2573
|
response = self.privateInverseGetFutureTradeV1EntrustPlanListHistory(self.extend(request, params))
|
2574
2574
|
else:
|
@@ -2709,31 +2709,31 @@ class xt(Exchange, ImplicitAPI):
|
|
2709
2709
|
response = None
|
2710
2710
|
type, params = self.handle_market_type_and_params('fetchOrdersByStatus', market, params)
|
2711
2711
|
subType, params = self.handle_sub_type_and_params('fetchOrdersByStatus', market, params)
|
2712
|
-
|
2712
|
+
trigger = self.safe_value(params, 'stop')
|
2713
2713
|
stopLossTakeProfit = self.safe_value(params, 'stopLossTakeProfit')
|
2714
2714
|
if status == 'open':
|
2715
|
-
if
|
2715
|
+
if trigger or stopLossTakeProfit:
|
2716
2716
|
request['state'] = 'NOT_TRIGGERED'
|
2717
2717
|
elif subType is not None:
|
2718
2718
|
request['state'] = 'NEW'
|
2719
2719
|
elif status == 'closed':
|
2720
|
-
if
|
2720
|
+
if trigger or stopLossTakeProfit:
|
2721
2721
|
request['state'] = 'TRIGGERED'
|
2722
2722
|
else:
|
2723
2723
|
request['state'] = 'FILLED'
|
2724
2724
|
elif status == 'canceled':
|
2725
|
-
if
|
2725
|
+
if trigger or stopLossTakeProfit:
|
2726
2726
|
request['state'] = 'USER_REVOCATION'
|
2727
2727
|
else:
|
2728
2728
|
request['state'] = 'CANCELED'
|
2729
2729
|
else:
|
2730
2730
|
request['state'] = status
|
2731
|
-
if
|
2731
|
+
if trigger or stopLossTakeProfit or (subType is not None) or (type == 'swap') or (type == 'future'):
|
2732
2732
|
if since is not None:
|
2733
2733
|
request['startTime'] = since
|
2734
2734
|
if limit is not None:
|
2735
2735
|
request['size'] = limit
|
2736
|
-
if
|
2736
|
+
if trigger:
|
2737
2737
|
params = self.omit(params, 'stop')
|
2738
2738
|
if subType == 'inverse':
|
2739
2739
|
response = self.privateInverseGetFutureTradeV1EntrustPlanList(self.extend(request, params))
|
@@ -2959,7 +2959,7 @@ class xt(Exchange, ImplicitAPI):
|
|
2959
2959
|
:param int [since]: timestamp in ms of the earliest order
|
2960
2960
|
:param int [limit]: the maximum number of open order structures to retrieve
|
2961
2961
|
:param dict params: extra parameters specific to the xt api endpoint
|
2962
|
-
:param bool [params.
|
2962
|
+
:param bool [params.trigger]: if the order is a trigger order or not
|
2963
2963
|
:param bool [params.stopLossTakeProfit]: if the order is a stop-loss or take-profit order
|
2964
2964
|
:returns dict[]: a list of `order structures <https://docs.ccxt.com/en/latest/manual.html#order-structure>`
|
2965
2965
|
"""
|
@@ -2978,7 +2978,7 @@ class xt(Exchange, ImplicitAPI):
|
|
2978
2978
|
:param int [since]: timestamp in ms of the earliest order
|
2979
2979
|
:param int [limit]: the maximum number of order structures to retrieve
|
2980
2980
|
:param dict params: extra parameters specific to the xt api endpoint
|
2981
|
-
:param bool [params.
|
2981
|
+
:param bool [params.trigger]: if the order is a trigger order or not
|
2982
2982
|
:param bool [params.stopLossTakeProfit]: if the order is a stop-loss or take-profit order
|
2983
2983
|
:returns dict[]: a list of `order structures <https://docs.ccxt.com/en/latest/manual.html#order-structure>`
|
2984
2984
|
"""
|
@@ -2997,7 +2997,7 @@ class xt(Exchange, ImplicitAPI):
|
|
2997
2997
|
:param int [since]: timestamp in ms of the earliest order
|
2998
2998
|
:param int [limit]: the maximum number of order structures to retrieve
|
2999
2999
|
:param dict params: extra parameters specific to the xt api endpoint
|
3000
|
-
:param bool [params.
|
3000
|
+
:param bool [params.trigger]: if the order is a trigger order or not
|
3001
3001
|
:param bool [params.stopLossTakeProfit]: if the order is a stop-loss or take-profit order
|
3002
3002
|
:returns dict: a list of `order structures <https://docs.ccxt.com/en/latest/manual.html#order-structure>`
|
3003
3003
|
"""
|
@@ -3015,7 +3015,7 @@ class xt(Exchange, ImplicitAPI):
|
|
3015
3015
|
:param str id: order id
|
3016
3016
|
:param str [symbol]: unified symbol of the market the order was made in
|
3017
3017
|
:param dict params: extra parameters specific to the xt api endpoint
|
3018
|
-
:param bool [params.
|
3018
|
+
:param bool [params.trigger]: if the order is a trigger order or not
|
3019
3019
|
:param bool [params.stopLossTakeProfit]: if the order is a stop-loss or take-profit order
|
3020
3020
|
:returns dict: An `order structure <https://docs.ccxt.com/en/latest/manual.html#order-structure>`
|
3021
3021
|
"""
|
@@ -3029,16 +3029,16 @@ class xt(Exchange, ImplicitAPI):
|
|
3029
3029
|
response = None
|
3030
3030
|
type, params = self.handle_market_type_and_params('cancelOrder', market, params)
|
3031
3031
|
subType, params = self.handle_sub_type_and_params('cancelOrder', market, params)
|
3032
|
-
|
3032
|
+
trigger = self.safe_value_2(params, 'trigger', 'stop')
|
3033
3033
|
stopLossTakeProfit = self.safe_value(params, 'stopLossTakeProfit')
|
3034
|
-
if
|
3034
|
+
if trigger:
|
3035
3035
|
request['entrustId'] = id
|
3036
3036
|
elif stopLossTakeProfit:
|
3037
3037
|
request['profitId'] = id
|
3038
3038
|
else:
|
3039
3039
|
request['orderId'] = id
|
3040
|
-
if
|
3041
|
-
params = self.omit(params, 'stop')
|
3040
|
+
if trigger:
|
3041
|
+
params = self.omit(params, ['trigger', 'stop'])
|
3042
3042
|
if subType == 'inverse':
|
3043
3043
|
response = self.privateInversePostFutureTradeV1EntrustCancelPlan(self.extend(request, params))
|
3044
3044
|
else:
|
@@ -3091,7 +3091,7 @@ class xt(Exchange, ImplicitAPI):
|
|
3091
3091
|
|
3092
3092
|
:param str [symbol]: unified market symbol of the market to cancel orders in
|
3093
3093
|
:param dict params: extra parameters specific to the xt api endpoint
|
3094
|
-
:param bool [params.
|
3094
|
+
:param bool [params.trigger]: if the order is a trigger order or not
|
3095
3095
|
:param bool [params.stopLossTakeProfit]: if the order is a stop-loss or take-profit order
|
3096
3096
|
:returns dict[]: a list of `order structures <https://docs.ccxt.com/en/latest/manual.html#order-structure>`
|
3097
3097
|
"""
|
@@ -3106,10 +3106,10 @@ class xt(Exchange, ImplicitAPI):
|
|
3106
3106
|
response = None
|
3107
3107
|
type, params = self.handle_market_type_and_params('cancelAllOrders', market, params)
|
3108
3108
|
subType, params = self.handle_sub_type_and_params('cancelAllOrders', market, params)
|
3109
|
-
|
3109
|
+
trigger = self.safe_value_2(params, 'trigger', 'stop')
|
3110
3110
|
stopLossTakeProfit = self.safe_value(params, 'stopLossTakeProfit')
|
3111
|
-
if
|
3112
|
-
params = self.omit(params, 'stop')
|
3111
|
+
if trigger:
|
3112
|
+
params = self.omit(params, ['trigger', 'stop'])
|
3113
3113
|
if subType == 'inverse':
|
3114
3114
|
response = self.privateInversePostFutureTradeV1EntrustCancelAllPlan(self.extend(request, params))
|
3115
3115
|
else:
|
ccxt/zonda.py
CHANGED
@@ -853,7 +853,7 @@ class zonda(Exchange, ImplicitAPI):
|
|
853
853
|
:param int [since]: timestamp in ms of the earliest ledger entry, default is None
|
854
854
|
:param int [limit]: max number of ledger entries to return, default is None
|
855
855
|
:param dict [params]: extra parameters specific to the exchange API endpoint
|
856
|
-
:returns dict: a `ledger structure <https://docs.ccxt.com/#/?id=ledger
|
856
|
+
:returns dict: a `ledger structure <https://docs.ccxt.com/#/?id=ledger>`
|
857
857
|
"""
|
858
858
|
balanceCurrencies = []
|
859
859
|
if code is not None:
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: ccxt
|
3
|
-
Version: 4.4.
|
3
|
+
Version: 4.4.40
|
4
4
|
Summary: A JavaScript / TypeScript / Python / C# / PHP cryptocurrency trading library with support for 100+ exchanges
|
5
5
|
Home-page: https://ccxt.com
|
6
6
|
Author: Igor Kroitor
|
@@ -275,13 +275,13 @@ console.log(version, Object.keys(exchanges));
|
|
275
275
|
|
276
276
|
All-in-one browser bundle (dependencies included), served from a CDN of your choice:
|
277
277
|
|
278
|
-
* jsDelivr: https://cdn.jsdelivr.net/npm/ccxt@4.4.
|
279
|
-
* unpkg: https://unpkg.com/ccxt@4.4.
|
278
|
+
* jsDelivr: https://cdn.jsdelivr.net/npm/ccxt@4.4.40/dist/ccxt.browser.min.js
|
279
|
+
* unpkg: https://unpkg.com/ccxt@4.4.40/dist/ccxt.browser.min.js
|
280
280
|
|
281
281
|
CDNs are not updated in real-time and may have delays. Defaulting to the most recent version without specifying the version number is not recommended. Please, keep in mind that we are not responsible for the correct operation of those CDN servers.
|
282
282
|
|
283
283
|
```HTML
|
284
|
-
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/ccxt@4.4.
|
284
|
+
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/ccxt@4.4.40/dist/ccxt.browser.min.js"></script>
|
285
285
|
```
|
286
286
|
|
287
287
|
Creates a global `ccxt` object:
|