ccxt 4.3.11 → 4.3.12
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.
- package/README.md +3 -3
- package/dist/cjs/ccxt.js +1 -1
- package/dist/cjs/src/base/Exchange.js +15 -0
- package/dist/cjs/src/bigone.js +22 -22
- package/dist/cjs/src/binance.js +5 -5
- package/dist/cjs/src/bingx.js +2 -2
- package/dist/cjs/src/bitget.js +7 -4
- package/dist/cjs/src/bitmart.js +3 -8
- package/dist/cjs/src/bitmex.js +2 -2
- package/dist/cjs/src/bybit.js +81 -71
- package/dist/cjs/src/coinbase.js +8 -8
- package/dist/cjs/src/coinbaseinternational.js +2 -2
- package/dist/cjs/src/coinex.js +513 -449
- package/dist/cjs/src/coinlist.js +12 -12
- package/dist/cjs/src/coinmetro.js +2 -2
- package/dist/cjs/src/cryptocom.js +16 -16
- package/dist/cjs/src/gate.js +2 -2
- package/dist/cjs/src/hitbtc.js +3 -3
- package/dist/cjs/src/htx.js +3 -7
- package/dist/cjs/src/indodax.js +2 -2
- package/dist/cjs/src/kraken.js +3 -1
- package/dist/cjs/src/kucoin.js +4 -4
- package/dist/cjs/src/kucoinfutures.js +6 -6
- package/dist/cjs/src/mexc.js +5 -5
- package/dist/cjs/src/okx.js +6 -6
- package/dist/cjs/src/poloniexfutures.js +4 -4
- package/dist/cjs/src/pro/bitget.js +140 -89
- package/dist/cjs/src/pro/bybit.js +196 -11
- package/dist/cjs/src/pro/coinbase.js +107 -29
- package/dist/cjs/src/pro/mexc.js +21 -1
- package/dist/cjs/src/probit.js +2 -2
- package/dist/cjs/src/whitebit.js +76 -1
- package/dist/cjs/src/woo.js +2 -2
- package/js/ccxt.d.ts +1 -1
- package/js/ccxt.js +1 -1
- package/js/src/base/Exchange.d.ts +10 -6
- package/js/src/base/Exchange.js +15 -0
- package/js/src/base/types.d.ts +17 -2
- package/js/src/bigone.js +22 -22
- package/js/src/binance.d.ts +2 -9
- package/js/src/binance.js +5 -5
- package/js/src/bingx.js +2 -2
- package/js/src/bitget.d.ts +4 -31
- package/js/src/bitget.js +7 -4
- package/js/src/bitmart.d.ts +4 -24
- package/js/src/bitmart.js +3 -8
- package/js/src/bitmex.js +2 -2
- package/js/src/bybit.d.ts +7 -9
- package/js/src/bybit.js +81 -71
- package/js/src/coinbase.js +8 -8
- package/js/src/coinbaseinternational.js +2 -2
- package/js/src/coinex.d.ts +4 -24
- package/js/src/coinex.js +513 -449
- package/js/src/coinlist.js +12 -12
- package/js/src/coinmetro.js +2 -2
- package/js/src/cryptocom.js +16 -16
- package/js/src/digifinex.d.ts +3 -10
- package/js/src/gate.js +2 -2
- package/js/src/hitbtc.js +3 -3
- package/js/src/htx.d.ts +3 -13
- package/js/src/htx.js +3 -7
- package/js/src/indodax.js +2 -2
- package/js/src/kraken.js +3 -1
- package/js/src/kucoin.js +4 -4
- package/js/src/kucoinfutures.js +6 -6
- package/js/src/mexc.js +5 -5
- package/js/src/okx.d.ts +3 -10
- package/js/src/okx.js +6 -6
- package/js/src/poloniexfutures.js +4 -4
- package/js/src/pro/bitget.js +140 -89
- package/js/src/pro/bybit.d.ts +5 -1
- package/js/src/pro/bybit.js +196 -11
- package/js/src/pro/coinbase.d.ts +4 -0
- package/js/src/pro/coinbase.js +107 -29
- package/js/src/pro/mexc.js +21 -1
- package/js/src/probit.js +2 -2
- package/js/src/whitebit.d.ts +1 -0
- package/js/src/whitebit.js +76 -1
- package/js/src/woo.js +2 -2
- package/package.json +6 -5
- package/dist/cjs/src/flowbtc.js +0 -35
package/dist/cjs/src/coinlist.js
CHANGED
|
@@ -686,9 +686,9 @@ class coinlist extends coinlist$1 {
|
|
|
686
686
|
request['end_time'] = this.iso8601(this.milliseconds());
|
|
687
687
|
}
|
|
688
688
|
}
|
|
689
|
-
const until = this.
|
|
689
|
+
const until = this.safeInteger(params, 'until');
|
|
690
690
|
if (until !== undefined) {
|
|
691
|
-
params = this.omit(params, ['
|
|
691
|
+
params = this.omit(params, ['until']);
|
|
692
692
|
request['end_time'] = this.iso8601(until);
|
|
693
693
|
}
|
|
694
694
|
const response = await this.publicGetV1SymbolsSymbolCandles(this.extend(request, params));
|
|
@@ -764,9 +764,9 @@ class coinlist extends coinlist$1 {
|
|
|
764
764
|
if (limit !== undefined) {
|
|
765
765
|
request['count'] = Math.min(limit, 500);
|
|
766
766
|
}
|
|
767
|
-
const until = this.
|
|
767
|
+
const until = this.safeInteger(params, 'until');
|
|
768
768
|
if (until !== undefined) {
|
|
769
|
-
params = this.omit(params, ['
|
|
769
|
+
params = this.omit(params, ['until']);
|
|
770
770
|
request['end_time'] = this.iso8601(until);
|
|
771
771
|
}
|
|
772
772
|
const response = await this.publicGetV1SymbolsSymbolAuctions(this.extend(request, params));
|
|
@@ -1167,9 +1167,9 @@ class coinlist extends coinlist$1 {
|
|
|
1167
1167
|
if (limit !== undefined) {
|
|
1168
1168
|
request['count'] = limit;
|
|
1169
1169
|
}
|
|
1170
|
-
const until = this.
|
|
1170
|
+
const until = this.safeInteger(params, 'until');
|
|
1171
1171
|
if (until !== undefined) {
|
|
1172
|
-
params = this.omit(params, ['
|
|
1172
|
+
params = this.omit(params, ['until']);
|
|
1173
1173
|
request['end_time'] = this.iso8601(until);
|
|
1174
1174
|
}
|
|
1175
1175
|
const response = await this.privateGetV1Fills(this.extend(request, params));
|
|
@@ -1255,9 +1255,9 @@ class coinlist extends coinlist$1 {
|
|
|
1255
1255
|
if (limit !== undefined) {
|
|
1256
1256
|
request['count'] = limit;
|
|
1257
1257
|
}
|
|
1258
|
-
const until = this.
|
|
1258
|
+
const until = this.safeInteger(params, 'until');
|
|
1259
1259
|
if (until !== undefined) {
|
|
1260
|
-
params = this.omit(params, ['
|
|
1260
|
+
params = this.omit(params, ['until']);
|
|
1261
1261
|
request['end_time'] = this.iso8601(until);
|
|
1262
1262
|
}
|
|
1263
1263
|
const response = await this.privateGetV1Orders(this.extend(request, params));
|
|
@@ -1791,9 +1791,9 @@ class coinlist extends coinlist$1 {
|
|
|
1791
1791
|
if (limit !== undefined) {
|
|
1792
1792
|
request['count'] = limit;
|
|
1793
1793
|
}
|
|
1794
|
-
const until = this.
|
|
1794
|
+
const until = this.safeInteger(params, 'until');
|
|
1795
1795
|
if (until !== undefined) {
|
|
1796
|
-
params = this.omit(params, ['
|
|
1796
|
+
params = this.omit(params, ['until']);
|
|
1797
1797
|
request['end_time'] = this.iso8601(until);
|
|
1798
1798
|
}
|
|
1799
1799
|
const response = await this.privateGetV1Transfers(this.extend(request, params));
|
|
@@ -2093,9 +2093,9 @@ class coinlist extends coinlist$1 {
|
|
|
2093
2093
|
if (limit !== undefined) {
|
|
2094
2094
|
request['count'] = limit;
|
|
2095
2095
|
}
|
|
2096
|
-
const until = this.
|
|
2096
|
+
const until = this.safeInteger(params, 'until');
|
|
2097
2097
|
if (until !== undefined) {
|
|
2098
|
-
params = this.omit(params, ['
|
|
2098
|
+
params = this.omit(params, ['until']);
|
|
2099
2099
|
request['end_time'] = this.iso8601(until);
|
|
2100
2100
|
}
|
|
2101
2101
|
params = this.omit(params, ['trader_id', 'traderId']);
|
|
@@ -506,9 +506,9 @@ class coinmetro extends coinmetro$1 {
|
|
|
506
506
|
else {
|
|
507
507
|
request['from'] = ':from'; // this endpoint doesn't accept empty from and to params (setting them into the value described in the documentation)
|
|
508
508
|
}
|
|
509
|
-
until = this.
|
|
509
|
+
until = this.safeInteger(params, 'until', until);
|
|
510
510
|
if (until !== undefined) {
|
|
511
|
-
params = this.omit(params, ['
|
|
511
|
+
params = this.omit(params, ['until']);
|
|
512
512
|
request['to'] = until;
|
|
513
513
|
}
|
|
514
514
|
else {
|
|
@@ -677,8 +677,8 @@ class cryptocom extends cryptocom$1 {
|
|
|
677
677
|
if (limit !== undefined) {
|
|
678
678
|
request['limit'] = limit;
|
|
679
679
|
}
|
|
680
|
-
const until = this.
|
|
681
|
-
params = this.omit(params, ['until'
|
|
680
|
+
const until = this.safeInteger(params, 'until');
|
|
681
|
+
params = this.omit(params, ['until']);
|
|
682
682
|
if (until !== undefined) {
|
|
683
683
|
request['end_time'] = until;
|
|
684
684
|
}
|
|
@@ -756,8 +756,8 @@ class cryptocom extends cryptocom$1 {
|
|
|
756
756
|
if (limit !== undefined) {
|
|
757
757
|
request['count'] = limit;
|
|
758
758
|
}
|
|
759
|
-
const until = this.
|
|
760
|
-
params = this.omit(params, ['until'
|
|
759
|
+
const until = this.safeInteger(params, 'until');
|
|
760
|
+
params = this.omit(params, ['until']);
|
|
761
761
|
if (until !== undefined) {
|
|
762
762
|
request['end_ts'] = until;
|
|
763
763
|
}
|
|
@@ -818,8 +818,8 @@ class cryptocom extends cryptocom$1 {
|
|
|
818
818
|
if (limit !== undefined) {
|
|
819
819
|
request['count'] = limit;
|
|
820
820
|
}
|
|
821
|
-
const until = this.
|
|
822
|
-
params = this.omit(params, ['until'
|
|
821
|
+
const until = this.safeInteger(params, 'until');
|
|
822
|
+
params = this.omit(params, ['until']);
|
|
823
823
|
if (until !== undefined) {
|
|
824
824
|
request['end_ts'] = until;
|
|
825
825
|
}
|
|
@@ -1591,8 +1591,8 @@ class cryptocom extends cryptocom$1 {
|
|
|
1591
1591
|
if (limit !== undefined) {
|
|
1592
1592
|
request['limit'] = limit;
|
|
1593
1593
|
}
|
|
1594
|
-
const until = this.
|
|
1595
|
-
params = this.omit(params, ['until'
|
|
1594
|
+
const until = this.safeInteger(params, 'until');
|
|
1595
|
+
params = this.omit(params, ['until']);
|
|
1596
1596
|
if (until !== undefined) {
|
|
1597
1597
|
request['end_time'] = until;
|
|
1598
1598
|
}
|
|
@@ -1814,8 +1814,8 @@ class cryptocom extends cryptocom$1 {
|
|
|
1814
1814
|
if (limit !== undefined) {
|
|
1815
1815
|
request['page_size'] = limit;
|
|
1816
1816
|
}
|
|
1817
|
-
const until = this.
|
|
1818
|
-
params = this.omit(params, ['until'
|
|
1817
|
+
const until = this.safeInteger(params, 'until');
|
|
1818
|
+
params = this.omit(params, ['until']);
|
|
1819
1819
|
if (until !== undefined) {
|
|
1820
1820
|
request['end_ts'] = until;
|
|
1821
1821
|
}
|
|
@@ -1873,8 +1873,8 @@ class cryptocom extends cryptocom$1 {
|
|
|
1873
1873
|
if (limit !== undefined) {
|
|
1874
1874
|
request['page_size'] = limit;
|
|
1875
1875
|
}
|
|
1876
|
-
const until = this.
|
|
1877
|
-
params = this.omit(params, ['until'
|
|
1876
|
+
const until = this.safeInteger(params, 'until');
|
|
1877
|
+
params = this.omit(params, ['until']);
|
|
1878
1878
|
if (until !== undefined) {
|
|
1879
1879
|
request['end_ts'] = until;
|
|
1880
1880
|
}
|
|
@@ -2387,8 +2387,8 @@ class cryptocom extends cryptocom$1 {
|
|
|
2387
2387
|
if (limit !== undefined) {
|
|
2388
2388
|
request['limit'] = limit;
|
|
2389
2389
|
}
|
|
2390
|
-
const until = this.
|
|
2391
|
-
params = this.omit(params, ['until'
|
|
2390
|
+
const until = this.safeInteger(params, 'until');
|
|
2391
|
+
params = this.omit(params, ['until']);
|
|
2392
2392
|
if (until !== undefined) {
|
|
2393
2393
|
request['end_time'] = until;
|
|
2394
2394
|
}
|
|
@@ -2710,8 +2710,8 @@ class cryptocom extends cryptocom$1 {
|
|
|
2710
2710
|
if (limit !== undefined) {
|
|
2711
2711
|
request['count'] = limit;
|
|
2712
2712
|
}
|
|
2713
|
-
const until = this.
|
|
2714
|
-
params = this.omit(params, ['until'
|
|
2713
|
+
const until = this.safeInteger(params, 'until');
|
|
2714
|
+
params = this.omit(params, ['until']);
|
|
2715
2715
|
if (until !== undefined) {
|
|
2716
2716
|
request['end_ts'] = until;
|
|
2717
2717
|
}
|
package/dist/cjs/src/gate.js
CHANGED
|
@@ -3252,8 +3252,8 @@ class gate extends gate$1 {
|
|
|
3252
3252
|
let marginMode = undefined;
|
|
3253
3253
|
let request = {};
|
|
3254
3254
|
const market = (symbol !== undefined) ? this.market(symbol) : undefined;
|
|
3255
|
-
const until = this.
|
|
3256
|
-
params = this.omit(params, ['until'
|
|
3255
|
+
const until = this.safeInteger(params, 'until');
|
|
3256
|
+
params = this.omit(params, ['until']);
|
|
3257
3257
|
[type, params] = this.handleMarketTypeAndParams('fetchMyTrades', market, params);
|
|
3258
3258
|
const contract = (type === 'swap') || (type === 'future') || (type === 'option');
|
|
3259
3259
|
if (contract) {
|
package/dist/cjs/src/hitbtc.js
CHANGED
|
@@ -1734,7 +1734,7 @@ class hitbtc extends hitbtc$1 {
|
|
|
1734
1734
|
if (since !== undefined) {
|
|
1735
1735
|
request['from'] = this.iso8601(since);
|
|
1736
1736
|
}
|
|
1737
|
-
[request, params] = this.handleUntilOption('
|
|
1737
|
+
[request, params] = this.handleUntilOption('until', request, params);
|
|
1738
1738
|
if (limit !== undefined) {
|
|
1739
1739
|
request['limit'] = Math.min(limit, 1000);
|
|
1740
1740
|
}
|
|
@@ -2806,11 +2806,11 @@ class hitbtc extends hitbtc$1 {
|
|
|
2806
2806
|
// 'symbols': Comma separated list of symbol codes,
|
|
2807
2807
|
// 'sort': 'DESC' or 'ASC'
|
|
2808
2808
|
// 'from': 'Datetime or Number',
|
|
2809
|
-
// '
|
|
2809
|
+
// 'until': 'Datetime or Number',
|
|
2810
2810
|
// 'limit': 100,
|
|
2811
2811
|
// 'offset': 0,
|
|
2812
2812
|
};
|
|
2813
|
-
[request, params] = this.handleUntilOption('
|
|
2813
|
+
[request, params] = this.handleUntilOption('until', request, params);
|
|
2814
2814
|
if (symbol !== undefined) {
|
|
2815
2815
|
market = this.market(symbol);
|
|
2816
2816
|
symbol = market['symbol'];
|
package/dist/cjs/src/htx.js
CHANGED
|
@@ -6754,11 +6754,7 @@ class htx extends htx$1 {
|
|
|
6754
6754
|
// }
|
|
6755
6755
|
//
|
|
6756
6756
|
const data = this.safeValue(response, 'data', []);
|
|
6757
|
-
|
|
6758
|
-
for (let i = 0; i < data.length; i++) {
|
|
6759
|
-
rates.push(this.parseIsolatedBorrowRate(data[i]));
|
|
6760
|
-
}
|
|
6761
|
-
return rates;
|
|
6757
|
+
return this.parseIsolatedBorrowRates(data);
|
|
6762
6758
|
}
|
|
6763
6759
|
parseIsolatedBorrowRate(info, market = undefined) {
|
|
6764
6760
|
//
|
|
@@ -8749,8 +8745,8 @@ class htx extends htx$1 {
|
|
|
8749
8745
|
if (symbol === undefined) {
|
|
8750
8746
|
throw new errors.ArgumentsRequired(this.id + ' fetchSettlementHistory() requires a symbol argument');
|
|
8751
8747
|
}
|
|
8752
|
-
const until = this.
|
|
8753
|
-
params = this.omit(params, ['until'
|
|
8748
|
+
const until = this.safeInteger(params, 'until');
|
|
8749
|
+
params = this.omit(params, ['until']);
|
|
8754
8750
|
const market = this.market(symbol);
|
|
8755
8751
|
const request = {};
|
|
8756
8752
|
if (market['future']) {
|
package/dist/cjs/src/indodax.js
CHANGED
|
@@ -589,8 +589,8 @@ class indodax extends indodax$1 {
|
|
|
589
589
|
const timeframes = this.options['timeframes'];
|
|
590
590
|
const selectedTimeframe = this.safeString(timeframes, timeframe, timeframe);
|
|
591
591
|
const now = this.seconds();
|
|
592
|
-
const until = this.
|
|
593
|
-
params = this.omit(params, ['until'
|
|
592
|
+
const until = this.safeInteger(params, 'until', now);
|
|
593
|
+
params = this.omit(params, ['until']);
|
|
594
594
|
const request = {
|
|
595
595
|
'to': until,
|
|
596
596
|
'tf': selectedTimeframe,
|
package/dist/cjs/src/kraken.js
CHANGED
|
@@ -534,6 +534,8 @@ class kraken extends kraken$1 {
|
|
|
534
534
|
const leverageBuy = this.safeValue(market, 'leverage_buy', []);
|
|
535
535
|
const leverageBuyLength = leverageBuy.length;
|
|
536
536
|
const precisionPrice = this.parseNumber(this.parsePrecision(this.safeString(market, 'pair_decimals')));
|
|
537
|
+
const status = this.safeString(market, 'status');
|
|
538
|
+
const isActive = status === 'online';
|
|
537
539
|
result.push({
|
|
538
540
|
'id': id,
|
|
539
541
|
'wsId': this.safeString(market, 'wsname'),
|
|
@@ -552,7 +554,7 @@ class kraken extends kraken$1 {
|
|
|
552
554
|
'swap': false,
|
|
553
555
|
'future': false,
|
|
554
556
|
'option': false,
|
|
555
|
-
'active':
|
|
557
|
+
'active': isActive,
|
|
556
558
|
'contract': false,
|
|
557
559
|
'linear': undefined,
|
|
558
560
|
'inverse': undefined,
|
package/dist/cjs/src/kucoin.js
CHANGED
|
@@ -2427,10 +2427,10 @@ class kucoin extends kucoin$1 {
|
|
|
2427
2427
|
*/
|
|
2428
2428
|
await this.loadMarkets();
|
|
2429
2429
|
let lowercaseStatus = status.toLowerCase();
|
|
2430
|
-
const until = this.
|
|
2430
|
+
const until = this.safeInteger(params, 'until');
|
|
2431
2431
|
const stop = this.safeBool(params, 'stop', false);
|
|
2432
2432
|
const hf = this.safeBool(params, 'hf', false);
|
|
2433
|
-
params = this.omit(params, ['stop', 'hf', '
|
|
2433
|
+
params = this.omit(params, ['stop', 'hf', 'until']);
|
|
2434
2434
|
const [marginMode, query] = this.handleMarginModeAndParams('fetchOrdersByStatus', params);
|
|
2435
2435
|
if (lowercaseStatus === 'open') {
|
|
2436
2436
|
lowercaseStatus = 'active';
|
|
@@ -2535,7 +2535,7 @@ class kucoin extends kucoin$1 {
|
|
|
2535
2535
|
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
2536
2536
|
* @param {int} [limit] the maximum number of order structures to retrieve
|
|
2537
2537
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
2538
|
-
* @param {int} [params.
|
|
2538
|
+
* @param {int} [params.until] end time in ms
|
|
2539
2539
|
* @param {string} [params.side] buy or sell
|
|
2540
2540
|
* @param {string} [params.type] limit, market, limit_stop or market_stop
|
|
2541
2541
|
* @param {string} [params.tradeType] TRADE for spot trading, MARGIN_TRADE for Margin Trading
|
|
@@ -2565,7 +2565,7 @@ class kucoin extends kucoin$1 {
|
|
|
2565
2565
|
* @param {int} [since] the earliest time in ms to fetch open orders for
|
|
2566
2566
|
* @param {int} [limit] the maximum number of open orders structures to retrieve
|
|
2567
2567
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
2568
|
-
* @param {int} [params.
|
|
2568
|
+
* @param {int} [params.until] end time in ms
|
|
2569
2569
|
* @param {bool} [params.stop] true if fetching stop orders
|
|
2570
2570
|
* @param {string} [params.side] buy or sell
|
|
2571
2571
|
* @param {string} [params.type] limit, market, limit_stop or market_stop
|
|
@@ -1766,8 +1766,8 @@ class kucoinfutures extends kucoinfutures$1 {
|
|
|
1766
1766
|
return await this.fetchPaginatedCallDynamic('fetchOrdersByStatus', symbol, since, limit, params);
|
|
1767
1767
|
}
|
|
1768
1768
|
const stop = this.safeValue2(params, 'stop', 'trigger');
|
|
1769
|
-
const until = this.
|
|
1770
|
-
params = this.omit(params, ['stop', 'until', '
|
|
1769
|
+
const until = this.safeInteger(params, 'until');
|
|
1770
|
+
params = this.omit(params, ['stop', 'until', 'trigger']);
|
|
1771
1771
|
if (status === 'closed') {
|
|
1772
1772
|
status = 'done';
|
|
1773
1773
|
}
|
|
@@ -1864,7 +1864,7 @@ class kucoinfutures extends kucoinfutures$1 {
|
|
|
1864
1864
|
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
1865
1865
|
* @param {int} [limit] the maximum number of order structures to retrieve
|
|
1866
1866
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
1867
|
-
* @param {int} [params.
|
|
1867
|
+
* @param {int} [params.until] end time in ms
|
|
1868
1868
|
* @param {string} [params.side] buy or sell
|
|
1869
1869
|
* @param {string} [params.type] limit, or market
|
|
1870
1870
|
* @param {boolean} [params.paginate] default false, when true will automatically paginate by calling this endpoint multiple times. See in the docs all the [availble parameters](https://github.com/ccxt/ccxt/wiki/Manual#pagination-params)
|
|
@@ -1889,7 +1889,7 @@ class kucoinfutures extends kucoinfutures$1 {
|
|
|
1889
1889
|
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
1890
1890
|
* @param {int} [limit] the maximum number of order structures to retrieve
|
|
1891
1891
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
1892
|
-
* @param {int} [params.
|
|
1892
|
+
* @param {int} [params.until] end time in ms
|
|
1893
1893
|
* @param {string} [params.side] buy or sell
|
|
1894
1894
|
* @param {string} [params.type] limit, or market
|
|
1895
1895
|
* @param {boolean} [params.trigger] set to true to retrieve untriggered stop orders
|
|
@@ -2735,8 +2735,8 @@ class kucoinfutures extends kucoinfutures$1 {
|
|
|
2735
2735
|
'from': 0,
|
|
2736
2736
|
'to': this.milliseconds(),
|
|
2737
2737
|
};
|
|
2738
|
-
const until = this.
|
|
2739
|
-
params = this.omit(params, ['until'
|
|
2738
|
+
const until = this.safeInteger(params, 'until');
|
|
2739
|
+
params = this.omit(params, ['until']);
|
|
2740
2740
|
if (since !== undefined) {
|
|
2741
2741
|
request['from'] = since;
|
|
2742
2742
|
if (until === undefined) {
|
package/dist/cjs/src/mexc.js
CHANGED
|
@@ -1483,7 +1483,7 @@ class mexc extends mexc$1 {
|
|
|
1483
1483
|
}
|
|
1484
1484
|
let trades = undefined;
|
|
1485
1485
|
if (market['spot']) {
|
|
1486
|
-
const until = this.safeIntegerN(params, ['endTime', 'until'
|
|
1486
|
+
const until = this.safeIntegerN(params, ['endTime', 'until']);
|
|
1487
1487
|
if (since !== undefined) {
|
|
1488
1488
|
request['startTime'] = since;
|
|
1489
1489
|
if (until === undefined) {
|
|
@@ -1768,7 +1768,7 @@ class mexc extends mexc$1 {
|
|
|
1768
1768
|
};
|
|
1769
1769
|
let candles = undefined;
|
|
1770
1770
|
if (market['spot']) {
|
|
1771
|
-
const until = this.safeIntegerN(params, ['until', 'endTime'
|
|
1771
|
+
const until = this.safeIntegerN(params, ['until', 'endTime']);
|
|
1772
1772
|
if (since !== undefined) {
|
|
1773
1773
|
request['startTime'] = since;
|
|
1774
1774
|
if (until === undefined) {
|
|
@@ -1782,7 +1782,7 @@ class mexc extends mexc$1 {
|
|
|
1782
1782
|
request['limit'] = limit;
|
|
1783
1783
|
}
|
|
1784
1784
|
if (until !== undefined) {
|
|
1785
|
-
params = this.omit(params, ['until'
|
|
1785
|
+
params = this.omit(params, ['until']);
|
|
1786
1786
|
request['endTime'] = until;
|
|
1787
1787
|
}
|
|
1788
1788
|
const response = await this.spotPublicGetKlines(this.extend(request, params));
|
|
@@ -1803,12 +1803,12 @@ class mexc extends mexc$1 {
|
|
|
1803
1803
|
candles = response;
|
|
1804
1804
|
}
|
|
1805
1805
|
else if (market['swap']) {
|
|
1806
|
-
const until = this.safeIntegerProductN(params, ['until', 'endTime'
|
|
1806
|
+
const until = this.safeIntegerProductN(params, ['until', 'endTime'], 0.001);
|
|
1807
1807
|
if (since !== undefined) {
|
|
1808
1808
|
request['start'] = this.parseToInt(since / 1000);
|
|
1809
1809
|
}
|
|
1810
1810
|
if (until !== undefined) {
|
|
1811
|
-
params = this.omit(params, ['until'
|
|
1811
|
+
params = this.omit(params, ['until']);
|
|
1812
1812
|
request['end'] = until;
|
|
1813
1813
|
}
|
|
1814
1814
|
const priceType = this.safeString(params, 'price', 'default');
|
package/dist/cjs/src/okx.js
CHANGED
|
@@ -4027,10 +4027,10 @@ class okx extends okx$1 {
|
|
|
4027
4027
|
if (since !== undefined) {
|
|
4028
4028
|
request['begin'] = since;
|
|
4029
4029
|
}
|
|
4030
|
-
const until = this.
|
|
4030
|
+
const until = this.safeInteger(query, 'until');
|
|
4031
4031
|
if (until !== undefined) {
|
|
4032
4032
|
request['end'] = until;
|
|
4033
|
-
query = this.omit(query, ['until'
|
|
4033
|
+
query = this.omit(query, ['until']);
|
|
4034
4034
|
}
|
|
4035
4035
|
}
|
|
4036
4036
|
const send = this.omit(query, ['method', 'stop', 'trigger', 'trailing']);
|
|
@@ -4216,10 +4216,10 @@ class okx extends okx$1 {
|
|
|
4216
4216
|
if (since !== undefined) {
|
|
4217
4217
|
request['begin'] = since;
|
|
4218
4218
|
}
|
|
4219
|
-
const until = this.
|
|
4219
|
+
const until = this.safeInteger(query, 'until');
|
|
4220
4220
|
if (until !== undefined) {
|
|
4221
4221
|
request['end'] = until;
|
|
4222
|
-
query = this.omit(query, ['until'
|
|
4222
|
+
query = this.omit(query, ['until']);
|
|
4223
4223
|
}
|
|
4224
4224
|
request['state'] = 'filled';
|
|
4225
4225
|
}
|
|
@@ -7121,10 +7121,10 @@ class okx extends okx$1 {
|
|
|
7121
7121
|
if (since !== undefined) {
|
|
7122
7122
|
request['begin'] = since;
|
|
7123
7123
|
}
|
|
7124
|
-
const until = this.
|
|
7124
|
+
const until = this.safeInteger(params, 'until');
|
|
7125
7125
|
if (until !== undefined) {
|
|
7126
7126
|
request['end'] = until;
|
|
7127
|
-
params = this.omit(params, ['until'
|
|
7127
|
+
params = this.omit(params, ['until']);
|
|
7128
7128
|
}
|
|
7129
7129
|
response = await this.publicGetRubikStatContractsOpenInterestVolume(this.extend(request, params));
|
|
7130
7130
|
}
|
|
@@ -1277,8 +1277,8 @@ class poloniexfutures extends poloniexfutures$1 {
|
|
|
1277
1277
|
*/
|
|
1278
1278
|
await this.loadMarkets();
|
|
1279
1279
|
const stop = this.safeValue2(params, 'stop', 'trigger');
|
|
1280
|
-
const until = this.
|
|
1281
|
-
params = this.omit(params, ['
|
|
1280
|
+
const until = this.safeInteger(params, 'until');
|
|
1281
|
+
params = this.omit(params, ['trigger', 'stop', 'until']);
|
|
1282
1282
|
if (status === 'closed') {
|
|
1283
1283
|
status = 'done';
|
|
1284
1284
|
}
|
|
@@ -1378,7 +1378,7 @@ class poloniexfutures extends poloniexfutures$1 {
|
|
|
1378
1378
|
* @param {int} [since] the earliest time in ms to fetch open orders for
|
|
1379
1379
|
* @param {int} [limit] the maximum number of open orders structures to retrieve
|
|
1380
1380
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
1381
|
-
* @param {int} [params.
|
|
1381
|
+
* @param {int} [params.until] end time in ms
|
|
1382
1382
|
* @param {string} [params.side] buy or sell
|
|
1383
1383
|
* @param {string} [params.type] limit, or market
|
|
1384
1384
|
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
@@ -1396,7 +1396,7 @@ class poloniexfutures extends poloniexfutures$1 {
|
|
|
1396
1396
|
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
1397
1397
|
* @param {int} [limit] the maximum number of order structures to retrieve
|
|
1398
1398
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
1399
|
-
* @param {int} [params.
|
|
1399
|
+
* @param {int} [params.until] end time in ms
|
|
1400
1400
|
* @param {string} [params.side] buy or sell
|
|
1401
1401
|
* @param {string} [params.type] limit, or market
|
|
1402
1402
|
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|