ccxt 4.4.44 → 4.4.45

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 (70) hide show
  1. package/README.md +3 -3
  2. package/dist/ccxt.browser.min.js +15 -15
  3. package/dist/cjs/ccxt.js +1 -1
  4. package/dist/cjs/src/binance.js +161 -39
  5. package/dist/cjs/src/bingx.js +15 -9
  6. package/dist/cjs/src/bitfinex.js +1 -1
  7. package/dist/cjs/src/bitget.js +3 -3
  8. package/dist/cjs/src/bitmart.js +3 -3
  9. package/dist/cjs/src/bitmex.js +1 -1
  10. package/dist/cjs/src/blofin.js +22 -0
  11. package/dist/cjs/src/bybit.js +4 -4
  12. package/dist/cjs/src/coinbase.js +1 -1
  13. package/dist/cjs/src/coinex.js +1 -1
  14. package/dist/cjs/src/cryptocom.js +1 -1
  15. package/dist/cjs/src/exmo.js +18 -8
  16. package/dist/cjs/src/gate.js +1 -1
  17. package/dist/cjs/src/hashkey.js +7 -1
  18. package/dist/cjs/src/htx.js +2 -2
  19. package/dist/cjs/src/hyperliquid.js +1 -1
  20. package/dist/cjs/src/kraken.js +1 -1
  21. package/dist/cjs/src/krakenfutures.js +1 -1
  22. package/dist/cjs/src/kucoin.js +1 -1
  23. package/dist/cjs/src/kucoinfutures.js +2 -3
  24. package/dist/cjs/src/lykke.js +1 -1
  25. package/dist/cjs/src/mexc.js +2 -2
  26. package/dist/cjs/src/myokx.js +8 -0
  27. package/dist/cjs/src/okx.js +4 -4
  28. package/dist/cjs/src/onetrading.js +2 -1
  29. package/dist/cjs/src/pro/binance.js +2 -1
  30. package/dist/cjs/src/pro/myokx.js +5 -0
  31. package/dist/cjs/src/whitebit.js +34 -8
  32. package/dist/cjs/src/woo.js +1 -1
  33. package/dist/cjs/src/woofipro.js +2 -2
  34. package/js/ccxt.d.ts +1 -1
  35. package/js/ccxt.js +1 -1
  36. package/js/src/abstract/blofin.d.ts +22 -0
  37. package/js/src/binance.d.ts +4 -0
  38. package/js/src/binance.js +161 -39
  39. package/js/src/bingx.js +15 -9
  40. package/js/src/bitfinex.js +1 -1
  41. package/js/src/bitget.js +3 -3
  42. package/js/src/bitmart.js +3 -3
  43. package/js/src/bitmex.js +1 -1
  44. package/js/src/blofin.js +22 -0
  45. package/js/src/bybit.js +4 -4
  46. package/js/src/coinbase.js +1 -1
  47. package/js/src/coinex.js +1 -1
  48. package/js/src/cryptocom.js +1 -1
  49. package/js/src/exmo.d.ts +1 -0
  50. package/js/src/exmo.js +18 -8
  51. package/js/src/gate.js +1 -1
  52. package/js/src/hashkey.js +7 -1
  53. package/js/src/htx.js +2 -2
  54. package/js/src/hyperliquid.js +1 -1
  55. package/js/src/kraken.js +1 -1
  56. package/js/src/krakenfutures.js +1 -1
  57. package/js/src/kucoin.js +1 -1
  58. package/js/src/kucoinfutures.js +2 -3
  59. package/js/src/lykke.js +1 -1
  60. package/js/src/mexc.js +2 -2
  61. package/js/src/myokx.js +8 -0
  62. package/js/src/okx.js +4 -4
  63. package/js/src/onetrading.js +2 -1
  64. package/js/src/pro/binance.js +2 -1
  65. package/js/src/pro/myokx.js +5 -0
  66. package/js/src/whitebit.d.ts +2 -1
  67. package/js/src/whitebit.js +34 -8
  68. package/js/src/woo.js +1 -1
  69. package/js/src/woofipro.js +2 -2
  70. package/package.json +1 -1
@@ -1455,10 +1455,16 @@ class hashkey extends hashkey$1 {
1455
1455
  side = isBuyer ? 'buy' : 'sell';
1456
1456
  }
1457
1457
  let takerOrMaker = undefined;
1458
- const isMaker = this.safeBoolN(trade, ['isMaker', 'isMarker', 'ibm']);
1458
+ const isMaker = this.safeBoolN(trade, ['isMaker', 'isMarker']);
1459
1459
  if (isMaker !== undefined) {
1460
1460
  takerOrMaker = isMaker ? 'maker' : 'taker';
1461
1461
  }
1462
+ const isBuyerMaker = this.safeBool(trade, 'ibm');
1463
+ // if public trade
1464
+ if (isBuyerMaker !== undefined) {
1465
+ takerOrMaker = 'taker';
1466
+ side = isBuyerMaker ? 'sell' : 'buy';
1467
+ }
1462
1468
  let feeCost = this.safeString(trade, 'commission');
1463
1469
  let feeCurrncyId = this.safeString(trade, 'commissionAsset');
1464
1470
  const feeInfo = this.safeDict(trade, 'fee');
@@ -1292,7 +1292,7 @@ class htx extends htx$1 {
1292
1292
  'trailing': false,
1293
1293
  'untilDays': 2,
1294
1294
  'limit': 500,
1295
- 'daysBackClosed': 180,
1295
+ 'daysBack': 180,
1296
1296
  'daysBackCanceled': 1 / 12,
1297
1297
  },
1298
1298
  'fetchOHLCV': {
@@ -1333,7 +1333,7 @@ class htx extends htx$1 {
1333
1333
  'trailing': false,
1334
1334
  'untilDays': 2,
1335
1335
  'limit': 50,
1336
- 'daysBackClosed': 90,
1336
+ 'daysBack': 90,
1337
1337
  'daysBackCanceled': 1 / 12,
1338
1338
  },
1339
1339
  'fetchOHLCV': {
@@ -272,7 +272,7 @@ class hyperliquid extends hyperliquid$1 {
272
272
  'fetchClosedOrders': {
273
273
  'marginMode': false,
274
274
  'limit': 2000,
275
- 'daysBackClosed': undefined,
275
+ 'daysBack': undefined,
276
276
  'daysBackCanceled': undefined,
277
277
  'untilDays': undefined,
278
278
  'trigger': false,
@@ -474,7 +474,7 @@ class kraken extends kraken$1 {
474
474
  'fetchClosedOrders': {
475
475
  'marginMode': false,
476
476
  'limit': undefined,
477
- 'daysBackClosed': undefined,
477
+ 'daysBack': undefined,
478
478
  'daysBackCanceled': undefined,
479
479
  'untilDays': 100000,
480
480
  'trigger': false,
@@ -310,7 +310,7 @@ class krakenfutures extends krakenfutures$1 {
310
310
  'fetchClosedOrders': {
311
311
  'marginMode': false,
312
312
  'limit': undefined,
313
- 'daysBackClosed': undefined,
313
+ 'daysBack': undefined,
314
314
  'daysBackCanceled': undefined,
315
315
  'untilDays': undefined,
316
316
  'trigger': false,
@@ -1036,7 +1036,7 @@ class kucoin extends kucoin$1 {
1036
1036
  'fetchClosedOrders': {
1037
1037
  'marginMode': true,
1038
1038
  'limit': 500,
1039
- 'daysBackClosed': undefined,
1039
+ 'daysBack': undefined,
1040
1040
  'daysBackCanceled': undefined,
1041
1041
  'untilDays': 7,
1042
1042
  'trigger': true,
@@ -373,9 +373,8 @@ class kucoinfutures extends kucoinfutures$1 {
373
373
  'stopLossPrice': true,
374
374
  'takeProfitPrice': true,
375
375
  'attachedStopLossTakeProfit': {
376
- 'triggerPrice': undefined,
377
376
  'triggerPriceType': undefined,
378
- 'limitPrice': true,
377
+ 'price': true,
379
378
  },
380
379
  'timeInForce': {
381
380
  'IOC': true,
@@ -415,7 +414,7 @@ class kucoinfutures extends kucoinfutures$1 {
415
414
  'fetchClosedOrders': {
416
415
  'marginMode': false,
417
416
  'limit': 1000,
418
- 'daysBackClosed': undefined,
417
+ 'daysBack': undefined,
419
418
  'daysBackCanceled': undefined,
420
419
  'untilDays': undefined,
421
420
  'trigger': true,
@@ -201,7 +201,7 @@ class lykke extends lykke$1 {
201
201
  // {
202
202
  // "payload":[
203
203
  // {
204
- // "assetId":"115a60c2-0da1-40f9-a7f2-41da723b9074",
204
+ // "assetId":"115a60c2-0da1-40f9-a7f2-41da723b9075",
205
205
  // "name":"Monaco Token",
206
206
  // "symbol":"MCO",
207
207
  // "accuracy":6,
@@ -734,7 +734,7 @@ class mexc extends mexc$1 {
734
734
  'fetchClosedOrders': {
735
735
  'marginMode': true,
736
736
  'limit': 1000,
737
- 'daysBackClosed': 7,
737
+ 'daysBack': 7,
738
738
  'daysBackCanceled': 7,
739
739
  'untilDays': 7,
740
740
  'trigger': false,
@@ -790,7 +790,7 @@ class mexc extends mexc$1 {
790
790
  'fetchClosedOrders': {
791
791
  'marginMode': false,
792
792
  'limit': 100,
793
- 'daysBackClosed': 90,
793
+ 'daysBack': 90,
794
794
  'daysBackCanceled': undefined,
795
795
  'untilDays': 90,
796
796
  'trigger': true,
@@ -28,6 +28,14 @@ class myokx extends okx {
28
28
  'rest': 'https://{hostname}',
29
29
  },
30
30
  },
31
+ 'has': {
32
+ 'CORS': undefined,
33
+ 'spot': true,
34
+ 'margin': undefined,
35
+ 'swap': false,
36
+ 'future': false,
37
+ 'option': false,
38
+ },
31
39
  });
32
40
  }
33
41
  }
@@ -1199,7 +1199,7 @@ class okx extends okx$1 {
1199
1199
  'mark': true,
1200
1200
  'index': true,
1201
1201
  },
1202
- 'limitPrice': true,
1202
+ 'price': true,
1203
1203
  },
1204
1204
  'timeInForce': {
1205
1205
  'IOC': true,
@@ -1239,7 +1239,7 @@ class okx extends okx$1 {
1239
1239
  'fetchClosedOrders': {
1240
1240
  'marginMode': false,
1241
1241
  'limit': 100,
1242
- 'daysBackClosed': 90,
1242
+ 'daysBack': 90,
1243
1243
  'daysBackCanceled': 1 / 12,
1244
1244
  'untilDays': undefined,
1245
1245
  'trigger': true,
@@ -1626,7 +1626,7 @@ class okx extends okx$1 {
1626
1626
  'contractSize': contract ? this.safeNumber(market, 'ctVal') : undefined,
1627
1627
  'expiry': expiry,
1628
1628
  'expiryDatetime': this.iso8601(expiry),
1629
- 'strike': strikePrice,
1629
+ 'strike': this.parseNumber(strikePrice),
1630
1630
  'optionType': optionType,
1631
1631
  'created': this.safeInteger(market, 'listTime'),
1632
1632
  'precision': {
@@ -1833,7 +1833,7 @@ class okx extends okx$1 {
1833
1833
  }
1834
1834
  const firstChain = this.safeDict(chains, 0, {});
1835
1835
  result[code] = {
1836
- 'info': undefined,
1836
+ 'info': chains,
1837
1837
  'code': code,
1838
1838
  'id': currencyId,
1839
1839
  'name': this.safeString(firstChain, 'name'),
@@ -864,7 +864,8 @@ class onetrading extends onetrading$1 {
864
864
  // {"instrument_code":"BTC_EUR","granularity":{"unit":"HOURS","period":1},"high":"9135.7","low":"9002.59","open":"9055.45","close":"9133.98","total_amount":"26.21919","volume":"238278.8724959","time":"2020-05-09T00:59:59.999Z","last_sequence":461521},
865
865
  // ]
866
866
  //
867
- return this.parseOHLCVs(response, market, timeframe, since, limit);
867
+ const ohlcv = this.safeList(response, 'candlesticks');
868
+ return this.parseOHLCVs(ohlcv, market, timeframe, since, limit);
868
869
  }
869
870
  parseTrade(trade, market = undefined) {
870
871
  //
@@ -4271,7 +4271,8 @@ class binance extends binance$1 {
4271
4271
  client.reject(message, id);
4272
4272
  }
4273
4273
  // reset connection if 5xx error
4274
- if (this.safeString(code, 0) === '5') {
4274
+ const codeString = this.safeString(error, 'code');
4275
+ if ((codeString !== undefined) && (codeString[0] === '5')) {
4275
4276
  client.reset(message);
4276
4277
  }
4277
4278
  }
@@ -17,6 +17,11 @@ class myokx extends okx {
17
17
  'ws': 'wss://wseeapap.okx.com:8443/ws/v5',
18
18
  },
19
19
  },
20
+ 'has': {
21
+ 'swap': false,
22
+ 'future': false,
23
+ 'option': false,
24
+ },
20
25
  });
21
26
  }
22
27
  }
@@ -818,9 +818,22 @@ class whitebit extends whitebit$1 {
818
818
  // "last": "55913.88",
819
819
  // "period": 86400
820
820
  // }
821
- market = this.safeMarket(undefined, market);
821
+ // v2
822
+ // {
823
+ // lastUpdateTimestamp: '2025-01-02T09:16:36.000Z',
824
+ // tradingPairs: 'ARB_USDC',
825
+ // lastPrice: '0.7727',
826
+ // lowestAsk: '0.7735',
827
+ // highestBid: '0.7732',
828
+ // baseVolume24h: '1555793.74',
829
+ // quoteVolume24h: '1157602.622406',
830
+ // tradesEnabled: true
831
+ // }
832
+ //
833
+ const marketId = this.safeString(ticker, 'tradingPairs');
834
+ market = this.safeMarket(marketId, market);
822
835
  // last price is provided as "last" or "last_price"
823
- const last = this.safeString2(ticker, 'last', 'last_price');
836
+ const last = this.safeStringN(ticker, ['last', 'last_price', 'lastPrice']);
824
837
  // if "close" is provided, use it, otherwise use <last>
825
838
  const close = this.safeString(ticker, 'close', last);
826
839
  return this.safeTicker({
@@ -829,9 +842,9 @@ class whitebit extends whitebit$1 {
829
842
  'datetime': undefined,
830
843
  'high': this.safeString(ticker, 'high'),
831
844
  'low': this.safeString(ticker, 'low'),
832
- 'bid': this.safeString(ticker, 'bid'),
845
+ 'bid': this.safeString2(ticker, 'bid', 'highestBid'),
833
846
  'bidVolume': undefined,
834
- 'ask': this.safeString(ticker, 'ask'),
847
+ 'ask': this.safeString2(ticker, 'ask', 'lowestAsk'),
835
848
  'askVolume': undefined,
836
849
  'vwap': undefined,
837
850
  'open': this.safeString(ticker, 'open'),
@@ -841,8 +854,8 @@ class whitebit extends whitebit$1 {
841
854
  'change': undefined,
842
855
  'percentage': this.safeString(ticker, 'change'),
843
856
  'average': undefined,
844
- 'baseVolume': this.safeString2(ticker, 'base_volume', 'volume'),
845
- 'quoteVolume': this.safeString2(ticker, 'quote_volume', 'deal'),
857
+ 'baseVolume': this.safeStringN(ticker, ['base_volume', 'volume', 'baseVolume24h']),
858
+ 'quoteVolume': this.safeStringN(ticker, ['quote_volume', 'deal', 'quoteVolume24h']),
846
859
  'info': ticker,
847
860
  }, market);
848
861
  }
@@ -851,14 +864,23 @@ class whitebit extends whitebit$1 {
851
864
  * @name whitebit#fetchTickers
852
865
  * @description fetches price tickers for multiple markets, statistical information calculated over the past 24 hours for each market
853
866
  * @see https://docs.whitebit.com/public/http-v4/#market-activity
854
- * @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
867
+ * @param {string[]} [symbols] unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
855
868
  * @param {object} [params] extra parameters specific to the exchange API endpoint
869
+ * @param {string} [params.method] either v2PublicGetTicker or v4PublicGetTicker default is v4PublicGetTicker
856
870
  * @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
857
871
  */
858
872
  async fetchTickers(symbols = undefined, params = {}) {
859
873
  await this.loadMarkets();
860
874
  symbols = this.marketSymbols(symbols);
861
- const response = await this.v4PublicGetTicker(params);
875
+ let method = 'v4PublicGetTicker';
876
+ [method, params] = this.handleOptionAndParams(params, 'fetchTickers', 'method', method);
877
+ let response = undefined;
878
+ if (method === 'v4PublicGetTicker') {
879
+ response = await this.v4PublicGetTicker(params);
880
+ }
881
+ else {
882
+ response = await this.v2PublicGetTicker(params);
883
+ }
862
884
  //
863
885
  // "BCH_RUB": {
864
886
  // "base_id":1831,
@@ -870,6 +892,10 @@ class whitebit extends whitebit$1 {
870
892
  // "change":"2.12"
871
893
  // },
872
894
  //
895
+ const resultList = this.safeList(response, 'result');
896
+ if (resultList !== undefined) {
897
+ return this.parseTickers(resultList, symbols);
898
+ }
873
899
  const marketIds = Object.keys(response);
874
900
  const result = {};
875
901
  for (let i = 0; i < marketIds.length; i++) {
@@ -368,7 +368,7 @@ class woo extends woo$1 {
368
368
  'fetchClosedOrders': {
369
369
  'marginMode': false,
370
370
  'limit': 500,
371
- 'daysBackClosed': undefined,
371
+ 'daysBack': undefined,
372
372
  'daysBackCanceled': undefined,
373
373
  'untilDays': 100000,
374
374
  'trigger': true,
@@ -350,7 +350,7 @@ class woofipro extends woofipro$1 {
350
350
  'fetchClosedOrders': {
351
351
  'marginMode': false,
352
352
  'limit': 500,
353
- 'daysBackClosed': undefined,
353
+ 'daysBack': undefined,
354
354
  'daysBackCanceled': undefined,
355
355
  'untilDays': 100000,
356
356
  'trigger': true,
@@ -371,7 +371,7 @@ class woofipro extends woofipro$1 {
371
371
  'attachedStopLossTakeProfit': {
372
372
  // todo: implementation needs unification
373
373
  'triggerPriceType': undefined,
374
- 'limitPrice': false,
374
+ 'price': false,
375
375
  },
376
376
  },
377
377
  },
package/js/ccxt.d.ts CHANGED
@@ -4,7 +4,7 @@ import * as functions from './src/base/functions.js';
4
4
  import * as errors from './src/base/errors.js';
5
5
  import type { Int, int, Str, Strings, Num, Bool, IndexType, OrderSide, OrderType, MarketType, SubType, Dict, NullableDict, List, NullableList, Fee, OHLCV, OHLCVC, implicitReturnType, Market, Currency, Dictionary, MinMax, FeeInterface, TradingFeeInterface, MarketInterface, Trade, Order, OrderBook, Ticker, Transaction, Tickers, CurrencyInterface, Balance, BalanceAccount, Account, PartialBalances, Balances, DepositAddress, WithdrawalResponse, DepositAddressResponse, FundingRate, FundingRates, Position, BorrowInterest, LeverageTier, LedgerEntry, DepositWithdrawFeeNetwork, DepositWithdrawFee, TransferEntry, CrossBorrowRate, IsolatedBorrowRate, FundingRateHistory, OpenInterest, Liquidation, OrderRequest, CancellationRequest, FundingHistory, MarketMarginModes, MarginMode, Greeks, Conversion, Option, LastPrice, Leverage, MarginModification, Leverages, LastPrices, Currencies, TradingFees, MarginModes, OptionChain, IsolatedBorrowRates, CrossBorrowRates, LeverageTiers, LongShortRatio, OpenInterests } from './src/base/types.js';
6
6
  import { BaseError, ExchangeError, AuthenticationError, PermissionDenied, AccountNotEnabled, AccountSuspended, ArgumentsRequired, BadRequest, BadSymbol, OperationRejected, NoChange, MarginModeAlreadySet, MarketClosed, ManualInteractionNeeded, InsufficientFunds, InvalidAddress, AddressPending, InvalidOrder, OrderNotFound, OrderNotCached, OrderImmediatelyFillable, OrderNotFillable, DuplicateOrderId, ContractUnavailable, NotSupported, InvalidProxySettings, ExchangeClosedByUser, OperationFailed, NetworkError, DDoSProtection, RateLimitExceeded, ExchangeNotAvailable, OnMaintenance, InvalidNonce, ChecksumError, RequestTimeout, BadResponse, NullResponse, CancelPending, UnsubscribeError } from './src/base/errors.js';
7
- declare const version = "4.4.43";
7
+ declare const version = "4.4.44";
8
8
  import ace from './src/ace.js';
9
9
  import alpaca from './src/alpaca.js';
10
10
  import ascendex from './src/ascendex.js';
package/js/ccxt.js CHANGED
@@ -38,7 +38,7 @@ import * as errors from './src/base/errors.js';
38
38
  import { BaseError, ExchangeError, AuthenticationError, PermissionDenied, AccountNotEnabled, AccountSuspended, ArgumentsRequired, BadRequest, BadSymbol, OperationRejected, NoChange, MarginModeAlreadySet, MarketClosed, ManualInteractionNeeded, InsufficientFunds, InvalidAddress, AddressPending, InvalidOrder, OrderNotFound, OrderNotCached, OrderImmediatelyFillable, OrderNotFillable, DuplicateOrderId, ContractUnavailable, NotSupported, InvalidProxySettings, ExchangeClosedByUser, OperationFailed, NetworkError, DDoSProtection, RateLimitExceeded, ExchangeNotAvailable, OnMaintenance, InvalidNonce, ChecksumError, RequestTimeout, BadResponse, NullResponse, CancelPending, UnsubscribeError } from './src/base/errors.js';
39
39
  //-----------------------------------------------------------------------------
40
40
  // this is updated by vss.js when building
41
- const version = '4.4.44';
41
+ const version = '4.4.45';
42
42
  Exchange.ccxtVersion = version;
43
43
  //-----------------------------------------------------------------------------
44
44
  import ace from './src/ace.js';
@@ -25,6 +25,18 @@ interface Exchange {
25
25
  privateGetTradeOrdersTpslHistory(params?: {}): Promise<implicitReturnType>;
26
26
  privateGetUserQueryApikey(params?: {}): Promise<implicitReturnType>;
27
27
  privateGetAffiliateBasic(params?: {}): Promise<implicitReturnType>;
28
+ privateGetCopytradingInstruments(params?: {}): Promise<implicitReturnType>;
29
+ privateGetCopytradingAccountBalance(params?: {}): Promise<implicitReturnType>;
30
+ privateGetCopytradingAccountPositionsByOrder(params?: {}): Promise<implicitReturnType>;
31
+ privateGetCopytradingAccountPositionsDetailsByOrder(params?: {}): Promise<implicitReturnType>;
32
+ privateGetCopytradingAccountPositionsByContract(params?: {}): Promise<implicitReturnType>;
33
+ privateGetCopytradingAccountPositionMode(params?: {}): Promise<implicitReturnType>;
34
+ privateGetCopytradingAccountLeverageInfo(params?: {}): Promise<implicitReturnType>;
35
+ privateGetCopytradingTradeOrdersPending(params?: {}): Promise<implicitReturnType>;
36
+ privateGetCopytradingTradePendingTpslByContract(params?: {}): Promise<implicitReturnType>;
37
+ privateGetCopytradingTradePositionHistoryByOrder(params?: {}): Promise<implicitReturnType>;
38
+ privateGetCopytradingTradeOrdersHistory(params?: {}): Promise<implicitReturnType>;
39
+ privateGetCopytradingTradePendingTpslByOrder(params?: {}): Promise<implicitReturnType>;
28
40
  privatePostTradeOrder(params?: {}): Promise<implicitReturnType>;
29
41
  privatePostTradeCancelOrder(params?: {}): Promise<implicitReturnType>;
30
42
  privatePostAccountSetLeverage(params?: {}): Promise<implicitReturnType>;
@@ -34,6 +46,16 @@ interface Exchange {
34
46
  privatePostTradeCancelTpsl(params?: {}): Promise<implicitReturnType>;
35
47
  privatePostTradeClosePosition(params?: {}): Promise<implicitReturnType>;
36
48
  privatePostAssetTransfer(params?: {}): Promise<implicitReturnType>;
49
+ privatePostCopytradingAccountSetPositionMode(params?: {}): Promise<implicitReturnType>;
50
+ privatePostCopytradingAccountSetLeverage(params?: {}): Promise<implicitReturnType>;
51
+ privatePostCopytradingTradePlaceOrder(params?: {}): Promise<implicitReturnType>;
52
+ privatePostCopytradingTradeCancelOrder(params?: {}): Promise<implicitReturnType>;
53
+ privatePostCopytradingTradePlaceTpslByContract(params?: {}): Promise<implicitReturnType>;
54
+ privatePostCopytradingTradeCancelTpslByContract(params?: {}): Promise<implicitReturnType>;
55
+ privatePostCopytradingTradePlaceTpslByOrder(params?: {}): Promise<implicitReturnType>;
56
+ privatePostCopytradingTradeCancelTpslByOrder(params?: {}): Promise<implicitReturnType>;
57
+ privatePostCopytradingTradeClosePositionByOrder(params?: {}): Promise<implicitReturnType>;
58
+ privatePostCopytradingTradeClosePositionByContract(params?: {}): Promise<implicitReturnType>;
37
59
  }
38
60
  declare abstract class Exchange extends _Exchange {
39
61
  }
@@ -275,6 +275,8 @@ export default class binance extends Exchange {
275
275
  * @description edit a trade order
276
276
  * @see https://developers.binance.com/docs/derivatives/usds-margined-futures/trade/rest-api/Modify-Order
277
277
  * @see https://developers.binance.com/docs/derivatives/coin-margined-futures/trade/Modify-Order
278
+ * @see https://developers.binance.com/docs/derivatives/portfolio-margin/trade/Modify-UM-Order
279
+ * @see https://developers.binance.com/docs/derivatives/portfolio-margin/trade/Modify-CM-Order
278
280
  * @param {string} id cancel order id
279
281
  * @param {string} symbol unified symbol of the market to create an order in
280
282
  * @param {string} type 'market' or 'limit'
@@ -282,6 +284,7 @@ export default class binance extends Exchange {
282
284
  * @param {float} amount how much of currency you want to trade in units of base currency
283
285
  * @param {float} [price] the price at which the order is to be fulfilled, in units of the quote currency, ignored in market orders
284
286
  * @param {object} [params] extra parameters specific to the exchange API endpoint
287
+ * @param {boolean} [params.portfolioMargin] set to true if you would like to edit an order in a portfolio margin account
285
288
  * @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
286
289
  */
287
290
  editContractOrder(id: string, symbol: string, type: OrderType, side: OrderSide, amount: number, price?: Num, params?: {}): Promise<Order>;
@@ -299,6 +302,7 @@ export default class binance extends Exchange {
299
302
  * @param {float} amount how much of currency you want to trade in units of base currency
300
303
  * @param {float} [price] the price at which the order is to be fulfilled, in units of the quote currency, ignored in market orders
301
304
  * @param {object} [params] extra parameters specific to the exchange API endpoint
305
+ * @param {boolean} [params.portfolioMargin] set to true if you would like to edit an order in a portfolio margin account
302
306
  * @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
303
307
  */
304
308
  editOrder(id: string, symbol: string, type: OrderType, side: OrderSide, amount?: Num, price?: Num, params?: {}): Promise<Order>;