ccxt 4.1.95 → 4.1.97

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 (198) hide show
  1. package/README.md +3 -3
  2. package/build.sh +16 -16
  3. package/dist/ccxt.browser.js +1570 -1401
  4. package/dist/ccxt.browser.min.js +3 -3
  5. package/dist/cjs/ccxt.js +1 -1
  6. package/dist/cjs/src/ace.js +1 -1
  7. package/dist/cjs/src/ascendex.js +1 -1
  8. package/dist/cjs/src/base/Exchange.js +6 -5
  9. package/dist/cjs/src/base/errors.js +8 -1
  10. package/dist/cjs/src/bigone.js +2 -2
  11. package/dist/cjs/src/binance.js +145 -135
  12. package/dist/cjs/src/bingx.js +50 -8
  13. package/dist/cjs/src/bit2c.js +2 -3
  14. package/dist/cjs/src/bitfinex.js +1 -1
  15. package/dist/cjs/src/bitfinex2.js +3 -4
  16. package/dist/cjs/src/bitflyer.js +2 -2
  17. package/dist/cjs/src/bitmart.js +2 -2
  18. package/dist/cjs/src/bitmex.js +2 -2
  19. package/dist/cjs/src/bitopro.js +1 -1
  20. package/dist/cjs/src/bitpanda.js +1 -1
  21. package/dist/cjs/src/bitvavo.js +1 -1
  22. package/dist/cjs/src/blockchaincom.js +1 -1
  23. package/dist/cjs/src/btcalpha.js +2 -2
  24. package/dist/cjs/src/btcbox.js +3 -4
  25. package/dist/cjs/src/btcmarkets.js +2 -2
  26. package/dist/cjs/src/btcturk.js +1 -1
  27. package/dist/cjs/src/bybit.js +2 -2
  28. package/dist/cjs/src/cex.js +1 -1
  29. package/dist/cjs/src/coinbase.js +11 -5
  30. package/dist/cjs/src/coinbasepro.js +2 -2
  31. package/dist/cjs/src/coinex.js +1 -1
  32. package/dist/cjs/src/coinlist.js +1 -1
  33. package/dist/cjs/src/cryptocom.js +2 -1
  34. package/dist/cjs/src/delta.js +25 -0
  35. package/dist/cjs/src/deribit.js +1 -1
  36. package/dist/cjs/src/digifinex.js +1 -1
  37. package/dist/cjs/src/gate.js +3 -3
  38. package/dist/cjs/src/hitbtc.js +1 -1
  39. package/dist/cjs/src/hollaex.js +2 -2
  40. package/dist/cjs/src/htx.js +1 -1
  41. package/dist/cjs/src/huobijp.js +2 -2
  42. package/dist/cjs/src/idex.js +1 -1
  43. package/dist/cjs/src/independentreserve.js +1 -1
  44. package/dist/cjs/src/kraken.js +47 -46
  45. package/dist/cjs/src/krakenfutures.js +53 -26
  46. package/dist/cjs/src/kucoin.js +74 -4
  47. package/dist/cjs/src/kucoinfutures.js +2 -2
  48. package/dist/cjs/src/kuna.js +1 -1
  49. package/dist/cjs/src/latoken.js +1 -1
  50. package/dist/cjs/src/luno.js +2 -2
  51. package/dist/cjs/src/lykke.js +1 -1
  52. package/dist/cjs/src/mexc.js +2 -2
  53. package/dist/cjs/src/ndax.js +1 -1
  54. package/dist/cjs/src/novadax.js +2 -2
  55. package/dist/cjs/src/oceanex.js +1 -1
  56. package/dist/cjs/src/okcoin.js +1 -1
  57. package/dist/cjs/src/okx.js +1 -1
  58. package/dist/cjs/src/poloniexfutures.js +1 -1
  59. package/dist/cjs/src/pro/alpaca.js +1 -1
  60. package/dist/cjs/src/pro/ascendex.js +1 -1
  61. package/dist/cjs/src/pro/binance.js +4 -5
  62. package/dist/cjs/src/pro/bingx.js +6 -3
  63. package/dist/cjs/src/pro/bitfinex.js +3 -4
  64. package/dist/cjs/src/pro/bitfinex2.js +1 -1
  65. package/dist/cjs/src/pro/bitmex.js +1 -1
  66. package/dist/cjs/src/pro/bitpanda.js +1 -1
  67. package/dist/cjs/src/pro/blockchaincom.js +1 -1
  68. package/dist/cjs/src/pro/bybit.js +2 -2
  69. package/dist/cjs/src/pro/cex.js +1 -1
  70. package/dist/cjs/src/pro/coinbase.js +1 -1
  71. package/dist/cjs/src/pro/coinbasepro.js +1 -1
  72. package/dist/cjs/src/pro/deribit.js +1 -1
  73. package/dist/cjs/src/pro/gate.js +3 -3
  74. package/dist/cjs/src/pro/gemini.js +1 -1
  75. package/dist/cjs/src/pro/hollaex.js +1 -1
  76. package/dist/cjs/src/pro/htx.js +1 -1
  77. package/dist/cjs/src/pro/idex.js +1 -1
  78. package/dist/cjs/src/pro/kraken.js +3 -4
  79. package/dist/cjs/src/pro/krakenfutures.js +1 -1
  80. package/dist/cjs/src/pro/kucoinfutures.js +1 -1
  81. package/dist/cjs/src/pro/mexc.js +1 -1
  82. package/dist/cjs/src/pro/okcoin.js +1 -1
  83. package/dist/cjs/src/pro/okx.js +2 -2
  84. package/dist/cjs/src/pro/phemex.js +1 -1
  85. package/dist/cjs/src/pro/poloniexfutures.js +1 -1
  86. package/dist/cjs/src/pro/woo.js +2 -3
  87. package/dist/cjs/src/probit.js +1 -1
  88. package/dist/cjs/src/timex.js +1 -1
  89. package/dist/cjs/src/tokocrypto.js +1 -1
  90. package/dist/cjs/src/upbit.js +1 -1
  91. package/dist/cjs/src/wavesexchange.js +1 -1
  92. package/dist/cjs/src/whitebit.js +1 -1
  93. package/dist/cjs/src/woo.js +1 -1
  94. package/dist/cjs/src/zaif.js +1 -1
  95. package/js/ccxt.d.ts +1 -1
  96. package/js/ccxt.js +1 -1
  97. package/js/src/abstract/bingx.d.ts +2 -0
  98. package/js/src/abstract/kucoin.d.ts +12 -0
  99. package/js/src/abstract/kucoinfutures.d.ts +12 -1
  100. package/js/src/ace.js +1 -1
  101. package/js/src/ascendex.js +1 -1
  102. package/js/src/base/Exchange.d.ts +1 -1
  103. package/js/src/base/Exchange.js +7 -6
  104. package/js/src/base/errorHierarchy.d.ts +1 -0
  105. package/js/src/base/errorHierarchy.js +1 -0
  106. package/js/src/base/errors.d.ts +5 -1
  107. package/js/src/base/errors.js +8 -2
  108. package/js/src/bigone.js +2 -2
  109. package/js/src/binance.js +145 -135
  110. package/js/src/bingx.d.ts +1 -0
  111. package/js/src/bingx.js +50 -8
  112. package/js/src/bit2c.js +2 -3
  113. package/js/src/bitfinex.js +1 -1
  114. package/js/src/bitfinex2.js +3 -4
  115. package/js/src/bitflyer.js +2 -2
  116. package/js/src/bitmart.js +2 -2
  117. package/js/src/bitmex.js +2 -2
  118. package/js/src/bitopro.js +1 -1
  119. package/js/src/bitpanda.js +1 -1
  120. package/js/src/bitso.d.ts +1 -1
  121. package/js/src/bitvavo.js +1 -1
  122. package/js/src/blockchaincom.js +1 -1
  123. package/js/src/btcalpha.js +2 -2
  124. package/js/src/btcbox.js +3 -4
  125. package/js/src/btcmarkets.js +2 -2
  126. package/js/src/btcturk.js +1 -1
  127. package/js/src/bybit.js +2 -2
  128. package/js/src/cex.js +1 -1
  129. package/js/src/coinbase.js +11 -5
  130. package/js/src/coinbasepro.js +2 -2
  131. package/js/src/coinex.js +1 -1
  132. package/js/src/coinlist.js +1 -1
  133. package/js/src/cryptocom.js +2 -1
  134. package/js/src/delta.d.ts +5 -4
  135. package/js/src/delta.js +25 -0
  136. package/js/src/deribit.js +1 -1
  137. package/js/src/digifinex.js +1 -1
  138. package/js/src/gate.js +3 -3
  139. package/js/src/hitbtc.js +1 -1
  140. package/js/src/hollaex.js +2 -2
  141. package/js/src/htx.js +1 -1
  142. package/js/src/huobijp.js +2 -2
  143. package/js/src/idex.js +1 -1
  144. package/js/src/independentreserve.js +1 -1
  145. package/js/src/kraken.js +47 -46
  146. package/js/src/krakenfutures.js +53 -26
  147. package/js/src/kucoin.d.ts +3 -0
  148. package/js/src/kucoin.js +74 -4
  149. package/js/src/kucoinfutures.js +2 -2
  150. package/js/src/kuna.js +1 -1
  151. package/js/src/latoken.js +1 -1
  152. package/js/src/luno.js +2 -2
  153. package/js/src/lykke.js +1 -1
  154. package/js/src/mexc.js +2 -2
  155. package/js/src/ndax.js +1 -1
  156. package/js/src/novadax.js +2 -2
  157. package/js/src/oceanex.js +1 -1
  158. package/js/src/okcoin.js +1 -1
  159. package/js/src/okx.js +1 -1
  160. package/js/src/poloniexfutures.js +1 -1
  161. package/js/src/pro/alpaca.js +1 -1
  162. package/js/src/pro/ascendex.js +1 -1
  163. package/js/src/pro/binance.js +4 -5
  164. package/js/src/pro/bingx.js +6 -3
  165. package/js/src/pro/bitfinex.js +3 -4
  166. package/js/src/pro/bitfinex2.js +1 -1
  167. package/js/src/pro/bitmex.js +1 -1
  168. package/js/src/pro/bitpanda.js +1 -1
  169. package/js/src/pro/blockchaincom.js +1 -1
  170. package/js/src/pro/bybit.js +2 -2
  171. package/js/src/pro/cex.js +1 -1
  172. package/js/src/pro/coinbase.js +1 -1
  173. package/js/src/pro/coinbasepro.js +1 -1
  174. package/js/src/pro/deribit.js +1 -1
  175. package/js/src/pro/gate.js +3 -3
  176. package/js/src/pro/gemini.js +1 -1
  177. package/js/src/pro/hollaex.js +1 -1
  178. package/js/src/pro/htx.js +1 -1
  179. package/js/src/pro/idex.js +1 -1
  180. package/js/src/pro/kraken.js +3 -4
  181. package/js/src/pro/krakenfutures.js +1 -1
  182. package/js/src/pro/kucoinfutures.js +1 -1
  183. package/js/src/pro/mexc.js +1 -1
  184. package/js/src/pro/okcoin.js +1 -1
  185. package/js/src/pro/okx.js +2 -2
  186. package/js/src/pro/phemex.js +1 -1
  187. package/js/src/pro/poloniexfutures.js +1 -1
  188. package/js/src/pro/woo.js +2 -3
  189. package/js/src/probit.js +1 -1
  190. package/js/src/timex.js +1 -1
  191. package/js/src/tokocrypto.js +1 -1
  192. package/js/src/upbit.js +1 -1
  193. package/js/src/wavesexchange.js +1 -1
  194. package/js/src/whitebit.js +1 -1
  195. package/js/src/woo.js +1 -1
  196. package/js/src/zaif.js +1 -1
  197. package/package.json +2 -2
  198. package/skip-tests.json +1 -0
@@ -348,7 +348,7 @@ export default class alpaca extends alpacaRest {
348
348
  * @description watches information on multiple orders made by the user
349
349
  * @param {string} symbol unified market symbol of the market orders were made in
350
350
  * @param {int} [since] the earliest time in ms to fetch orders for
351
- * @param {int} [limit] the maximum number of orde structures to retrieve
351
+ * @param {int} [limit] the maximum number of order structures to retrieve
352
352
  * @param {object} [params] extra parameters specific to the exchange API endpoint
353
353
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure
354
354
  */
@@ -478,7 +478,7 @@ export default class ascendex extends ascendexRest {
478
478
  * @description watches information on multiple orders made by the user
479
479
  * @param {string} symbol unified market symbol of the market orders were made in
480
480
  * @param {int} [since] the earliest time in ms to fetch orders for
481
- * @param {int} [limit] the maximum number of orde structures to retrieve
481
+ * @param {int} [limit] the maximum number of order structures to retrieve
482
482
  * @param {object} [params] extra parameters specific to the exchange API endpoint
483
483
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
484
484
  */
@@ -945,14 +945,13 @@ export default class binance extends binanceRest {
945
945
  event = 'ticker';
946
946
  }
947
947
  let timestamp = undefined;
948
- const now = this.milliseconds();
949
948
  if (event === 'bookTicker') {
950
949
  // take the event timestamp, if available, for spot tickers it is not
951
- timestamp = this.safeInteger(message, 'E', now);
950
+ timestamp = this.safeInteger(message, 'E');
952
951
  }
953
952
  else {
954
953
  // take the timestamp of the closing price for candlestick streams
955
- timestamp = this.safeInteger(message, 'C', now);
954
+ timestamp = this.safeInteger(message, 'C');
956
955
  }
957
956
  const marketId = this.safeString(message, 's');
958
957
  const symbol = this.safeSymbol(marketId, undefined, undefined, marketType);
@@ -1931,7 +1930,7 @@ export default class binance extends binanceRest {
1931
1930
  * @description watches information on multiple orders made by the user
1932
1931
  * @param {string} symbol unified market symbol of the market orders were made in
1933
1932
  * @param {int} [since] the earliest time in ms to fetch orders for
1934
- * @param {int} [limit] the maximum number of orde structures to retrieve
1933
+ * @param {int} [limit] the maximum number of order structures to retrieve
1935
1934
  * @param {object} [params] extra parameters specific to the exchange API endpoint
1936
1935
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
1937
1936
  */
@@ -2487,7 +2486,7 @@ export default class binance extends binanceRest {
2487
2486
  * @description watches information on multiple trades made by the user
2488
2487
  * @param {string} symbol unified market symbol of the market orders were made in
2489
2488
  * @param {int} [since] the earliest time in ms to fetch orders for
2490
- * @param {int} [limit] the maximum number of orde structures to retrieve
2489
+ * @param {int} [limit] the maximum number of order structures to retrieve
2491
2490
  * @param {object} [params] extra parameters specific to the exchange API endpoint
2492
2491
  * @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure
2493
2492
  */
@@ -83,7 +83,7 @@ export default class bingx extends bingxRest {
83
83
  * @see https://bingx-api.github.io/docs/#/swapV2/socket/market.html#Subscribe%20the%20Latest%20Trade%20Detail
84
84
  * @param {string} symbol unified market symbol of the market orders were made in
85
85
  * @param {int} [since] the earliest time in ms to fetch orders for
86
- * @param {int} [limit] the maximum number of orde structures to retrieve
86
+ * @param {int} [limit] the maximum number of order structures to retrieve
87
87
  * @param {object} [params] extra parameters specific to the exchange API endpoint
88
88
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure
89
89
  */
@@ -311,8 +311,11 @@ export default class bingx extends bingxRest {
311
311
  // "t": 1696687440000
312
312
  // }
313
313
  //
314
+ // for spot, opening-time (t) is used instead of closing-time (T), to be compatible with fetchOHLCV
315
+ // for swap, (T) is the opening time
316
+ const timestamp = (market['spot']) ? 't' : 'T';
314
317
  return [
315
- this.safeInteger(ohlcv, 't'),
318
+ this.safeInteger(ohlcv, timestamp),
316
319
  this.safeNumber(ohlcv, 'o'),
317
320
  this.safeNumber(ohlcv, 'h'),
318
321
  this.safeNumber(ohlcv, 'l'),
@@ -440,7 +443,7 @@ export default class bingx extends bingxRest {
440
443
  * @description watches information on multiple orders made by the user
441
444
  * @param {string} symbol unified market symbol of the market orders were made in
442
445
  * @param {int} [since] the earliest time in ms to fetch orders for
443
- * @param {int} [limit] the maximum number of orde structures to retrieve
446
+ * @param {int} [limit] the maximum number of order structures to retrieve
444
447
  * @param {object} [params] extra parameters specific to the exchange API endpoint
445
448
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
446
449
  */
@@ -212,7 +212,6 @@ export default class bitfinex extends bitfinexRest {
212
212
  // 220.05, // 10 LOW float Daily low
213
213
  // ]
214
214
  //
215
- const timestamp = this.milliseconds();
216
215
  const marketId = this.safeString(subscription, 'pair');
217
216
  const symbol = this.safeSymbol(marketId);
218
217
  const channel = 'ticker';
@@ -225,8 +224,8 @@ export default class bitfinex extends bitfinexRest {
225
224
  }
226
225
  const result = {
227
226
  'symbol': symbol,
228
- 'timestamp': timestamp,
229
- 'datetime': this.iso8601(timestamp),
227
+ 'timestamp': undefined,
228
+ 'datetime': undefined,
230
229
  'high': this.safeFloat(message, 9),
231
230
  'low': this.safeFloat(message, 10),
232
231
  'bid': this.safeFloat(message, 1),
@@ -461,7 +460,7 @@ export default class bitfinex extends bitfinexRest {
461
460
  * @description watches information on multiple orders made by the user
462
461
  * @param {string} symbol unified market symbol of the market orders were made in
463
462
  * @param {int} [since] the earliest time in ms to fetch orders for
464
- * @param {int} [limit] the maximum number of orde structures to retrieve
463
+ * @param {int} [limit] the maximum number of order structures to retrieve
465
464
  * @param {object} [params] extra parameters specific to the exchange API endpoint
466
465
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
467
466
  */
@@ -885,7 +885,7 @@ export default class bitfinex2 extends bitfinex2Rest {
885
885
  * @description watches information on multiple orders made by the user
886
886
  * @param {string} symbol unified market symbol of the market orders were made in
887
887
  * @param {int} [since] the earliest time in ms to fetch orders for
888
- * @param {int} [limit] the maximum number of orde structures to retrieve
888
+ * @param {int} [limit] the maximum number of order structures to retrieve
889
889
  * @param {object} [params] extra parameters specific to the exchange API endpoint
890
890
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure
891
891
  */
@@ -805,7 +805,7 @@ export default class bitmex extends bitmexRest {
805
805
  * @description watches information on multiple orders made by the user
806
806
  * @param {string} symbol unified market symbol of the market orders were made in
807
807
  * @param {int} [since] the earliest time in ms to fetch orders for
808
- * @param {int} [limit] the maximum number of orde structures to retrieve
808
+ * @param {int} [limit] the maximum number of order structures to retrieve
809
809
  * @param {object} [params] extra parameters specific to the exchange API endpoint
810
810
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
811
811
  */
@@ -426,7 +426,7 @@ export default class bitpanda extends bitpandaRest {
426
426
  * @description watches information on multiple orders made by the user
427
427
  * @param {string} symbol unified market symbol of the market orders were made in
428
428
  * @param {int} [since] the earliest time in ms to fetch orders for
429
- * @param {int} [limit] the maximum number of orde structures to retrieve
429
+ * @param {int} [limit] the maximum number of order structures to retrieve
430
430
  * @param {object} [params] extra parameters specific to the exchange API endpoint
431
431
  * @param {string} [params.channel] can listen to orders using ACCOUNT_HISTORY or TRADING
432
432
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
@@ -414,7 +414,7 @@ export default class blockchaincom extends blockchaincomRest {
414
414
  * @see https://exchange.blockchain.com/api/#mass-order-status-request-ordermassstatusrequest
415
415
  * @param {string} symbol unified market symbol of the market orders were made in
416
416
  * @param {int} [since] the earliest time in ms to fetch orders for
417
- * @param {int} [limit] the maximum number of orde structures to retrieve
417
+ * @param {int} [limit] the maximum number of order structures to retrieve
418
418
  * @param {object} [params] extra parameters specific to the exchange API endpoint
419
419
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
420
420
  */
@@ -788,7 +788,7 @@ export default class bybit extends bybitRest {
788
788
  * @see https://bybit-exchange.github.io/docs/v5/websocket/private/execution
789
789
  * @param {string} symbol unified market symbol of the market orders were made in
790
790
  * @param {int} [since] the earliest time in ms to fetch orders for
791
- * @param {int} [limit] the maximum number of orde structures to retrieve
791
+ * @param {int} [limit] the maximum number of order structures to retrieve
792
792
  * @param {object} [params] extra parameters specific to the exchange API endpoint
793
793
  * @param {boolean} [params.unifiedMargin] use unified margin account
794
794
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure
@@ -1053,7 +1053,7 @@ export default class bybit extends bybitRest {
1053
1053
  * @see https://bybit-exchange.github.io/docs/v5/websocket/private/order
1054
1054
  * @param {string} symbol unified market symbol of the market orders were made in
1055
1055
  * @param {int} [since] the earliest time in ms to fetch orders for
1056
- * @param {int} [limit] the maximum number of orde structures to retrieve
1056
+ * @param {int} [limit] the maximum number of order structures to retrieve
1057
1057
  * @param {object} [params] extra parameters specific to the exchange API endpoint
1058
1058
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure
1059
1059
  */
package/js/src/pro/cex.js CHANGED
@@ -735,7 +735,7 @@ export default class cex extends cexRest {
735
735
  'rate': undefined,
736
736
  };
737
737
  }
738
- const timestamp = this.safeInteger(data, 'time', this.milliseconds());
738
+ const timestamp = this.safeInteger(data, 'time');
739
739
  order['timestamp'] = timestamp;
740
740
  order['datetime'] = this.iso8601(timestamp);
741
741
  order = this.safeOrder(order);
@@ -270,7 +270,7 @@ export default class coinbase extends coinbaseRest {
270
270
  * @see https://docs.cloud.coinbase.com/advanced-trade-api/docs/ws-channels#user-channel
271
271
  * @param {string} [symbol] unified market symbol of the market orders were made in
272
272
  * @param {int} [since] the earliest time in ms to fetch orders for
273
- * @param {int} [limit] the maximum number of orde structures to retrieve
273
+ * @param {int} [limit] the maximum number of order structures to retrieve
274
274
  * @param {object} [params] extra parameters specific to the exchange API endpoint
275
275
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
276
276
  */
@@ -271,7 +271,7 @@ export default class coinbasepro extends coinbaseproRest {
271
271
  * @description watches information on multiple orders made by the user
272
272
  * @param {string} symbol unified market symbol of the market orders were made in
273
273
  * @param {int} [since] the earliest time in ms to fetch orders for
274
- * @param {int} [limit] the maximum number of orde structures to retrieve
274
+ * @param {int} [limit] the maximum number of order structures to retrieve
275
275
  * @param {object} [params] extra parameters specific to the exchange API endpoint
276
276
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
277
277
  */
@@ -514,7 +514,7 @@ export default class deribit extends deribitRest {
514
514
  * @description watches information on multiple orders made by the user
515
515
  * @param {string} symbol unified market symbol of the market orders were made in
516
516
  * @param {int} [since] the earliest time in ms to fetch orders for
517
- * @param {int} [limit] the maximum number of orde structures to retrieve
517
+ * @param {int} [limit] the maximum number of order structures to retrieve
518
518
  * @param {object} [params] extra parameters specific to the exchange API endpoint
519
519
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure
520
520
  */
@@ -723,7 +723,7 @@ export default class gate extends gateRest {
723
723
  // }
724
724
  //
725
725
  const result = this.safeValue(message, 'result', []);
726
- const timestamp = this.safeInteger(message, 'time');
726
+ const timestamp = this.safeInteger(message, 'time_ms');
727
727
  this.balance['info'] = result;
728
728
  this.balance['timestamp'] = timestamp;
729
729
  this.balance['datetime'] = this.iso8601(timestamp);
@@ -799,7 +799,7 @@ export default class gate extends gateRest {
799
799
  if (this.newUpdates) {
800
800
  return positions;
801
801
  }
802
- return this.filterBySymbolsSinceLimit(this.positions, symbols, since, limit, true);
802
+ return this.filterBySymbolsSinceLimit(this.positions[type], symbols, since, limit, true);
803
803
  }
804
804
  setPositionsCache(client, type, symbols = undefined) {
805
805
  if (this.positions === undefined) {
@@ -894,7 +894,7 @@ export default class gate extends gateRest {
894
894
  * @description watches information on multiple orders made by the user
895
895
  * @param {string} symbol unified market symbol of the market orders were made in
896
896
  * @param {int} [since] the earliest time in ms to fetch orders for
897
- * @param {int} [limit] the maximum number of orde structures to retrieve
897
+ * @param {int} [limit] the maximum number of order structures to retrieve
898
898
  * @param {object} [params] extra parameters specific to the exchange API endpoint
899
899
  * @param {string} [params.type] spot, margin, swap, future, or option. Required if listening to all symbols.
900
900
  * @param {boolean} [params.isInverse] if future, listen to inverse or linear contracts
@@ -380,7 +380,7 @@ export default class gemini extends geminiRest {
380
380
  * @see https://docs.gemini.com/websocket-api/#order-events
381
381
  * @param {string} symbol unified market symbol of the market orders were made in
382
382
  * @param {int} [since] the earliest time in ms to fetch orders for
383
- * @param {int} [limit] the maximum number of orde structures to retrieve
383
+ * @param {int} [limit] the maximum number of order structures to retrieve
384
384
  * @param {object} [params] extra parameters specific to the exchange API endpoint
385
385
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
386
386
  */
@@ -254,7 +254,7 @@ export default class hollaex extends hollaexRest {
254
254
  * @description watches information on multiple orders made by the user
255
255
  * @param {string} symbol unified market symbol of the market orders were made in
256
256
  * @param {int} [since] the earliest time in ms to fetch orders for
257
- * @param {int} [limit] the maximum number of orde structures to retrieve
257
+ * @param {int} [limit] the maximum number of order structures to retrieve
258
258
  * @param {object} [params] extra parameters specific to the exchange API endpoint
259
259
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
260
260
  */
package/js/src/pro/htx.js CHANGED
@@ -770,7 +770,7 @@ export default class htx extends htxRest {
770
770
  * @description watches information on multiple orders made by the user
771
771
  * @param {string} symbol unified market symbol of the market orders were made in
772
772
  * @param {int} [since] the earliest time in ms to fetch orders for
773
- * @param {int} [limit] the maximum number of orde structures to retrieve
773
+ * @param {int} [limit] the maximum number of order structures to retrieve
774
774
  * @param {object} [params] extra parameters specific to the exchange API endpoint
775
775
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
776
776
  */
@@ -512,7 +512,7 @@ export default class idex extends idexRest {
512
512
  * @description watches information on multiple orders made by the user
513
513
  * @param {string} symbol unified market symbol of the market orders were made in
514
514
  * @param {int} [since] the earliest time in ms to fetch orders for
515
- * @param {int} [limit] the maximum number of orde structures to retrieve
515
+ * @param {int} [limit] the maximum number of order structures to retrieve
516
516
  * @param {object} [params] extra parameters specific to the exchange API endpoint
517
517
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
518
518
  */
@@ -325,11 +325,10 @@ export default class kraken extends krakenRest {
325
325
  quoteVolume = Precise.stringMul(baseVolume, vwap);
326
326
  }
327
327
  const last = this.safeString(ticker['c'], 0);
328
- const timestamp = this.milliseconds();
329
328
  const result = this.safeTicker({
330
329
  'symbol': symbol,
331
- 'timestamp': timestamp,
332
- 'datetime': this.iso8601(timestamp),
330
+ 'timestamp': undefined,
331
+ 'datetime': undefined,
333
332
  'high': this.safeString(ticker['h'], 0),
334
333
  'low': this.safeString(ticker['l'], 0),
335
334
  'bid': this.safeString(ticker['b'], 0),
@@ -994,7 +993,7 @@ export default class kraken extends krakenRest {
994
993
  * @param {string} symbol unified market symbol of the market orders were made in
995
994
  * @param {int} [since] the earliest time in ms to fetch orders for
996
995
  * @param {int} [limit] the maximum number of orde structures to retrieve
997
- * @param {object} [params] extra parameters specific to the exchange API endpoint
996
+ * @param {object} [params] maximum number of orderic to the exchange API endpoint
998
997
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
999
998
  */
1000
999
  return await this.watchPrivate('openOrders', symbol, since, limit, params);
@@ -378,7 +378,7 @@ export default class krakenfutures extends krakenfuturesRest {
378
378
  * @see https://docs.futures.kraken.com/#websocket-api-private-feeds-fills
379
379
  * @param {string} symbol unified market symbol of the market orders were made in
380
380
  * @param {int} [since] the earliest time in ms to fetch orders for
381
- * @param {int} [limit] the maximum number of orde structures to retrieve
381
+ * @param {int} [limit] the maximum number of order structures to retrieve
382
382
  * @param {object} [params] extra parameters specific to the exchange API endpoint
383
383
  * @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure}
384
384
  */
@@ -675,7 +675,7 @@ export default class kucoinfutures extends kucoinfuturesRest {
675
675
  * @see https://docs.kucoin.com/futures/#trade-orders-according-to-the-market
676
676
  * @param {string} symbol unified market symbol of the market orders were made in
677
677
  * @param {int} [since] the earliest time in ms to fetch orders for
678
- * @param {int} [limit] the maximum number of orde structures to retrieve
678
+ * @param {int} [limit] the maximum number of order structures to retrieve
679
679
  * @param {object} [params] extra parameters specific to the exchange API endpoint
680
680
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
681
681
  */
@@ -740,7 +740,7 @@ export default class mexc extends mexcRest {
740
740
  * @description watches information on multiple orders made by the user
741
741
  * @param {string} symbol unified market symbol of the market orders were made in
742
742
  * @param {int} [since] the earliest time in ms to fetch orders for
743
- * @param {int} [limit] the maximum number of orde structures to retrieve
743
+ * @param {int} [limit] the maximum number of order structures to retrieve
744
744
  * @param {object} [params] extra parameters specific to the exchange API endpoint
745
745
  * @param {string|undefined} params.type the type of orders to retrieve, can be 'spot' or 'margin'
746
746
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
@@ -91,7 +91,7 @@ export default class okcoin extends okcoinRest {
91
91
  * @description watches information on multiple orders made by the user
92
92
  * @param {string} symbol unified market symbol of the market orders were made in
93
93
  * @param {int} [since] the earliest time in ms to fetch orders for
94
- * @param {int} [limit] the maximum number of orde structures to retrieve
94
+ * @param {int} [limit] the maximum number of order structures to retrieve
95
95
  * @param {object} [params] extra parameters specific to the exchange API endpoint
96
96
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
97
97
  */
package/js/src/pro/okx.js CHANGED
@@ -792,7 +792,7 @@ export default class okx extends okxRest {
792
792
  'side': this.safeString(order, 'side'),
793
793
  'price': this.safeNumber(info, 'fillPx'),
794
794
  'amount': this.safeNumber(info, 'fillSz'),
795
- 'cost': undefined,
795
+ 'cost': this.safeNumber(order, 'cost'),
796
796
  'fee': {
797
797
  'cost': this.safeNumber(info, 'fillFee'),
798
798
  'currency': this.safeCurrencyCode(feeMarketId),
@@ -968,7 +968,7 @@ export default class okx extends okxRest {
968
968
  * @description watches information on multiple orders made by the user
969
969
  * @param {string} [symbol] unified market symbol of the market orders were made in
970
970
  * @param {int} [since] the earliest time in ms to fetch orders for
971
- * @param {int} [limit] the maximum number of orde structures to retrieve
971
+ * @param {int} [limit] the maximum number of order structures to retrieve
972
972
  * @param {object} [params] extra parameters specific to the exchange API endpoint
973
973
  * @param {bool} [params.stop] true if fetching trigger or conditional orders
974
974
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
@@ -889,7 +889,7 @@ export default class phemex extends phemexRest {
889
889
  * @description watches information on multiple orders made by the user
890
890
  * @param {string} symbol unified market symbol of the market orders were made in
891
891
  * @param {int} [since] the earliest time in ms to fetch orders for
892
- * @param {int} [limit] the maximum number of orde structures to retrieve
892
+ * @param {int} [limit] the maximum number of order structures to retrieve
893
893
  * @param {object} [params] extra parameters specific to the exchange API endpoint
894
894
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
895
895
  */
@@ -302,7 +302,7 @@ export default class poloniexfutures extends poloniexfuturesRest {
302
302
  * @see https://futures-docs.poloniex.com/#private-messages
303
303
  * @param {string} symbol filter by unified market symbol of the market orders were made in
304
304
  * @param {int} [since] the earliest time in ms to fetch orders for
305
- * @param {int} [limit] the maximum number of orde structures to retrieve
305
+ * @param {int} [limit] the maximum number of order structures to retrieve
306
306
  * @param {object} [params] extra parameters specific to the exchange API endpoint
307
307
  * @param {string} [params.method] the method to use will default to /contractMarket/tradeOrders. Set to /contractMarket/advancedOrders to watch stop orders
308
308
  * @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
package/js/src/pro/woo.js CHANGED
@@ -146,11 +146,10 @@ export default class woo extends wooRest {
146
146
  // "count": 3689
147
147
  // }
148
148
  //
149
- const timestamp = this.safeInteger(ticker, 'date', this.milliseconds());
150
149
  return this.safeTicker({
151
150
  'symbol': this.safeSymbol(undefined, market),
152
- 'timestamp': timestamp,
153
- 'datetime': this.iso8601(timestamp),
151
+ 'timestamp': undefined,
152
+ 'datetime': undefined,
154
153
  'high': this.safeString(ticker, 'high'),
155
154
  'low': this.safeString(ticker, 'low'),
156
155
  'bid': undefined,
package/js/src/probit.js CHANGED
@@ -1058,7 +1058,7 @@ export default class probit extends Exchange {
1058
1058
  * @description fetches information on multiple closed orders made by the user
1059
1059
  * @param {string} symbol unified market symbol of the market orders were made in
1060
1060
  * @param {int} [since] the earliest time in ms to fetch orders for
1061
- * @param {int} [limit] the maximum number of orde structures to retrieve
1061
+ * @param {int} [limit] the maximum number of order structures to retrieve
1062
1062
  * @param {object} [params] extra parameters specific to the exchange API endpoint
1063
1063
  * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
1064
1064
  */
package/js/src/timex.js CHANGED
@@ -1001,7 +1001,7 @@ export default class timex extends Exchange {
1001
1001
  * @description fetches information on multiple closed orders made by the user
1002
1002
  * @param {string} symbol unified market symbol of the market orders were made in
1003
1003
  * @param {int} [since] the earliest time in ms to fetch orders for
1004
- * @param {int} [limit] the maximum number of orde structures to retrieve
1004
+ * @param {int} [limit] the maximum number of order structures to retrieve
1005
1005
  * @param {object} [params] extra parameters specific to the exchange API endpoint
1006
1006
  * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
1007
1007
  */
@@ -1906,7 +1906,7 @@ export default class tokocrypto extends Exchange {
1906
1906
  * @description fetches information on multiple closed orders made by the user
1907
1907
  * @param {string} symbol unified market symbol of the market orders were made in
1908
1908
  * @param {int} [since] the earliest time in ms to fetch orders for
1909
- * @param {int} [limit] the maximum number of orde structures to retrieve
1909
+ * @param {int} [limit] the maximum number of order structures to retrieve
1910
1910
  * @param {object} [params] extra parameters specific to the exchange API endpoint
1911
1911
  * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
1912
1912
  */
package/js/src/upbit.js CHANGED
@@ -1523,7 +1523,7 @@ export default class upbit extends Exchange {
1523
1523
  * @description fetches information on multiple closed orders made by the user
1524
1524
  * @param {string} symbol unified market symbol of the market orders were made in
1525
1525
  * @param {int} [since] the earliest time in ms to fetch orders for
1526
- * @param {int} [limit] the maximum number of orde structures to retrieve
1526
+ * @param {int} [limit] the maximum number of order structures to retrieve
1527
1527
  * @param {object} [params] extra parameters specific to the exchange API endpoint
1528
1528
  * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
1529
1529
  */
@@ -1635,7 +1635,7 @@ export default class wavesexchange extends Exchange {
1635
1635
  * @description fetches information on multiple closed orders made by the user
1636
1636
  * @param {string} symbol unified market symbol of the market orders were made in
1637
1637
  * @param {int} [since] the earliest time in ms to fetch orders for
1638
- * @param {int} [limit] the maximum number of orde structures to retrieve
1638
+ * @param {int} [limit] the maximum number of order structures to retrieve
1639
1639
  * @param {object} [params] extra parameters specific to the exchange API endpoint
1640
1640
  * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
1641
1641
  */
@@ -1409,7 +1409,7 @@ export default class whitebit extends Exchange {
1409
1409
  * @see https://docs.whitebit.com/private/http-trade-v4/#query-executed-orders
1410
1410
  * @param {string} symbol unified market symbol of the market orders were made in
1411
1411
  * @param {int} [since] the earliest time in ms to fetch orders for
1412
- * @param {int} [limit] the maximum number of orde structures to retrieve
1412
+ * @param {int} [limit] the maximum number of order structures to retrieve
1413
1413
  * @param {object} [params] extra parameters specific to the exchange API endpoint
1414
1414
  * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
1415
1415
  */
package/js/src/woo.js CHANGED
@@ -1192,7 +1192,7 @@ export default class woo extends Exchange {
1192
1192
  * @description fetches information on multiple orders made by the user
1193
1193
  * @param {string} symbol unified market symbol of the market orders were made in
1194
1194
  * @param {int} [since] the earliest time in ms to fetch orders for
1195
- * @param {int} [limit] the maximum number of orde structures to retrieve
1195
+ * @param {int} [limit] the maximum number of order structures to retrieve
1196
1196
  * @param {object} [params] extra parameters specific to the exchange API endpoint
1197
1197
  * @param {boolean} [params.stop] whether the order is a stop/algo order
1198
1198
  * @param {boolean} [params.isTriggered] whether the order has been triggered (false by default)
package/js/src/zaif.js CHANGED
@@ -558,7 +558,7 @@ export default class zaif extends Exchange {
558
558
  * @description fetches information on multiple closed orders made by the user
559
559
  * @param {string} symbol unified market symbol of the market orders were made in
560
560
  * @param {int} [since] the earliest time in ms to fetch orders for
561
- * @param {int} [limit] the maximum number of orde structures to retrieve
561
+ * @param {int} [limit] the maximum number of order structures to retrieve
562
562
  * @param {object} [params] extra parameters specific to the exchange API endpoint
563
563
  * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
564
564
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ccxt",
3
- "version": "4.1.95",
3
+ "version": "4.1.97",
4
4
  "description": "A JavaScript / TypeScript / Python / C# / PHP cryptocurrency trading library with support for 100+ exchanges",
5
5
  "unpkg": "dist/ccxt.browser.js",
6
6
  "type": "module",
@@ -128,7 +128,7 @@
128
128
  "asciichart": "^1.5.25",
129
129
  "assert": "^2.0.0",
130
130
  "ast-transpiler": "^0.0.29",
131
- "docsify": "^4.13.1",
131
+ "docsify": "^4.11.4",
132
132
  "eslint": "8.22.0",
133
133
  "eslint-config-airbnb-base": "15.0.0",
134
134
  "eslint-plugin-import": "2.25.4",
package/skip-tests.json CHANGED
@@ -336,6 +336,7 @@
336
336
  }
337
337
  },
338
338
  "bitrue": {
339
+ "skipWs": true,
339
340
  "skipMethods": {
340
341
  "loadMarkets": {
341
342
  "currencyIdAndCode": "broken currencies",