ccxt 4.1.56 → 4.1.57
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/.git-templates/hooks/pre-push +2 -2
- package/README.md +3 -3
- package/build.sh +30 -18
- package/dist/ccxt.browser.js +3872 -3202
- package/dist/ccxt.browser.min.js +10 -10
- package/dist/cjs/ccxt.js +1 -1
- package/dist/cjs/src/ace.js +17 -13
- package/dist/cjs/src/alpaca.js +6 -6
- package/dist/cjs/src/ascendex.js +35 -29
- package/dist/cjs/src/base/Exchange.js +39 -26
- package/dist/cjs/src/base/Precise.js +1 -3
- package/dist/cjs/src/bigone.js +24 -20
- package/dist/cjs/src/binance.js +97 -76
- package/dist/cjs/src/bingx.js +63 -44
- package/dist/cjs/src/bit2c.js +18 -15
- package/dist/cjs/src/bitbank.js +16 -15
- package/dist/cjs/src/bitbns.js +28 -18
- package/dist/cjs/src/bitfinex.js +23 -21
- package/dist/cjs/src/bitfinex2.js +32 -28
- package/dist/cjs/src/bitflyer.js +28 -20
- package/dist/cjs/src/bitforex.js +25 -18
- package/dist/cjs/src/bitget.js +184 -147
- package/dist/cjs/src/bithumb.js +23 -16
- package/dist/cjs/src/bitmart.js +106 -85
- package/dist/cjs/src/bitmex.js +104 -64
- package/dist/cjs/src/bitopro.js +38 -26
- package/dist/cjs/src/bitpanda.js +24 -23
- package/dist/cjs/src/bitrue.js +33 -24
- package/dist/cjs/src/bitso.js +24 -23
- package/dist/cjs/src/bitstamp.js +24 -23
- package/dist/cjs/src/bittrex.js +30 -29
- package/dist/cjs/src/bitvavo.js +38 -30
- package/dist/cjs/src/bl3p.js +11 -10
- package/dist/cjs/src/blockchaincom.js +20 -20
- package/dist/cjs/src/btcalpha.js +18 -17
- package/dist/cjs/src/btcbox.js +13 -12
- package/dist/cjs/src/btcmarkets.js +20 -19
- package/dist/cjs/src/btcturk.js +14 -13
- package/dist/cjs/src/bybit.js +84 -54
- package/dist/cjs/src/cex.js +16 -14
- package/dist/cjs/src/coinbase.js +29 -27
- package/dist/cjs/src/coinbasepro.js +27 -25
- package/dist/cjs/src/coincheck.js +15 -14
- package/dist/cjs/src/coinex.js +100 -77
- package/dist/cjs/src/coinlist.js +28 -27
- package/dist/cjs/src/coinmate.js +20 -17
- package/dist/cjs/src/coinone.js +21 -16
- package/dist/cjs/src/coinsph.js +37 -28
- package/dist/cjs/src/coinspot.js +12 -11
- package/dist/cjs/src/cryptocom.js +40 -202
- package/dist/cjs/src/currencycom.js +32 -25
- package/dist/cjs/src/delta.js +34 -28
- package/dist/cjs/src/deribit.js +39 -36
- package/dist/cjs/src/digifinex.js +64 -44
- package/dist/cjs/src/exmo.js +29 -27
- package/dist/cjs/src/gate.js +67 -53
- package/dist/cjs/src/gemini.js +23 -20
- package/dist/cjs/src/hitbtc.js +65 -56
- package/dist/cjs/src/hollaex.js +30 -27
- package/dist/cjs/src/htx.js +132 -143
- package/dist/cjs/src/huobijp.js +22 -20
- package/dist/cjs/src/idex.js +22 -21
- package/dist/cjs/src/independentreserve.js +15 -14
- package/dist/cjs/src/indodax.js +30 -26
- package/dist/cjs/src/kraken.js +29 -27
- package/dist/cjs/src/krakenfutures.js +29 -22
- package/dist/cjs/src/kucoin.js +48 -43
- package/dist/cjs/src/kucoinfutures.js +33 -28
- package/dist/cjs/src/kuna.js +25 -24
- package/dist/cjs/src/latoken.js +24 -22
- package/dist/cjs/src/lbank.js +45 -30
- package/dist/cjs/src/luno.js +22 -19
- package/dist/cjs/src/lykke.js +19 -17
- package/dist/cjs/src/mercado.js +30 -19
- package/dist/cjs/src/mexc.js +60 -49
- package/dist/cjs/src/ndax.js +23 -22
- package/dist/cjs/src/novadax.js +23 -22
- package/dist/cjs/src/oceanex.js +22 -19
- package/dist/cjs/src/okcoin.js +29 -23
- package/dist/cjs/src/okx.js +87 -82
- package/dist/cjs/src/p2b.js +79 -82
- package/dist/cjs/src/paymium.js +10 -10
- package/dist/cjs/src/phemex.js +63 -40
- package/dist/cjs/src/poloniex.js +22 -22
- package/dist/cjs/src/poloniexfutures.js +23 -19
- package/dist/cjs/src/pro/alpaca.js +5 -5
- package/dist/cjs/src/pro/ascendex.js +4 -4
- package/dist/cjs/src/pro/binance.js +16 -16
- package/dist/cjs/src/pro/bingx.js +1 -1
- package/dist/cjs/src/pro/bitfinex.js +4 -4
- package/dist/cjs/src/pro/bitfinex2.js +6 -6
- package/dist/cjs/src/pro/bitget.js +7 -7
- package/dist/cjs/src/pro/bitmart.js +7 -5
- package/dist/cjs/src/pro/bitmex.js +6 -6
- package/dist/cjs/src/pro/bitopro.js +4 -4
- package/dist/cjs/src/pro/bitpanda.js +6 -6
- package/dist/cjs/src/pro/bitrue.js +2 -2
- package/dist/cjs/src/pro/bitstamp.js +6 -4
- package/dist/cjs/src/pro/bittrex.js +6 -6
- package/dist/cjs/src/pro/bitvavo.js +11 -7
- package/dist/cjs/src/pro/blockchaincom.js +8 -8
- package/dist/cjs/src/pro/bybit.js +7 -7
- package/dist/cjs/src/pro/cex.js +13 -9
- package/dist/cjs/src/pro/coinbase.js +5 -5
- package/dist/cjs/src/pro/coinbasepro.js +11 -10
- package/dist/cjs/src/pro/coinex.js +7 -9
- package/dist/cjs/src/pro/cryptocom.js +9 -9
- package/dist/cjs/src/pro/currencycom.js +4 -4
- package/dist/cjs/src/pro/deribit.js +6 -6
- package/dist/cjs/src/pro/exmo.js +12 -14
- package/dist/cjs/src/pro/gate.js +7 -7
- package/dist/cjs/src/pro/gemini.js +3 -3
- package/dist/cjs/src/pro/hitbtc.js +263 -4
- package/dist/cjs/src/pro/hollaex.js +5 -5
- package/dist/cjs/src/pro/htx.js +6 -6
- package/dist/cjs/src/pro/huobijp.js +3 -3
- package/dist/cjs/src/pro/idex.js +4 -4
- package/dist/cjs/src/pro/independentreserve.js +2 -2
- package/dist/cjs/src/pro/kraken.js +10 -10
- package/dist/cjs/src/pro/krakenfutures.js +41 -17
- package/dist/cjs/src/pro/kucoin.js +7 -7
- package/dist/cjs/src/pro/kucoinfutures.js +8 -6
- package/dist/cjs/src/pro/luno.js +2 -2
- package/dist/cjs/src/pro/mexc.js +6 -6
- package/dist/cjs/src/pro/ndax.js +3 -3
- package/dist/cjs/src/pro/okcoin.js +5 -5
- package/dist/cjs/src/pro/okx.js +12 -12
- package/dist/cjs/src/pro/phemex.js +6 -6
- package/dist/cjs/src/pro/poloniex.js +7 -7
- package/dist/cjs/src/pro/poloniexfutures.js +5 -5
- package/dist/cjs/src/pro/probit.js +6 -6
- package/dist/cjs/src/pro/upbit.js +3 -3
- package/dist/cjs/src/pro/wazirx.js +8 -8
- package/dist/cjs/src/pro/whitebit.js +12 -8
- package/dist/cjs/src/pro/woo.js +1 -1
- package/dist/cjs/src/probit.js +28 -23
- package/dist/cjs/src/tidex.js +16 -15
- package/dist/cjs/src/timex.js +19 -18
- package/dist/cjs/src/tokocrypto.js +27 -22
- package/dist/cjs/src/upbit.js +19 -19
- package/dist/cjs/src/wavesexchange.js +22 -19
- package/dist/cjs/src/wazirx.js +24 -17
- package/dist/cjs/src/whitebit.js +33 -27
- package/dist/cjs/src/woo.js +44 -34
- package/dist/cjs/src/yobit.js +25 -20
- package/dist/cjs/src/zaif.js +9 -9
- package/dist/cjs/src/zonda.js +18 -17
- package/js/ccxt.d.ts +1 -1
- package/js/ccxt.js +1 -1
- package/js/src/abstract/bybit.d.ts +1 -0
- package/js/src/abstract/cryptocom.d.ts +0 -20
- package/js/src/ace.js +18 -14
- package/js/src/alpaca.js +6 -6
- package/js/src/ascendex.js +35 -29
- package/js/src/base/Exchange.d.ts +37 -34
- package/js/src/base/Exchange.js +39 -26
- package/js/src/base/Precise.d.ts +4 -4
- package/js/src/base/Precise.js +1 -3
- package/js/src/base/functions/type.d.ts +25 -25
- package/js/src/base/types.d.ts +21 -14
- package/js/src/bigone.js +25 -21
- package/js/src/binance.d.ts +2 -2
- package/js/src/binance.js +97 -76
- package/js/src/bingx.js +63 -44
- package/js/src/bit2c.js +19 -16
- package/js/src/bitbank.js +16 -15
- package/js/src/bitbns.js +28 -18
- package/js/src/bitfinex.js +23 -21
- package/js/src/bitfinex2.js +32 -28
- package/js/src/bitflyer.js +28 -20
- package/js/src/bitforex.js +26 -19
- package/js/src/bitget.d.ts +25 -3
- package/js/src/bitget.js +184 -147
- package/js/src/bithumb.js +23 -16
- package/js/src/bitmart.d.ts +1 -1
- package/js/src/bitmart.js +106 -85
- package/js/src/bitmex.d.ts +2 -2
- package/js/src/bitmex.js +104 -64
- package/js/src/bitopro.js +38 -26
- package/js/src/bitpanda.js +24 -23
- package/js/src/bitrue.js +33 -24
- package/js/src/bitso.js +24 -23
- package/js/src/bitstamp.d.ts +2 -2
- package/js/src/bitstamp.js +24 -23
- package/js/src/bittrex.js +30 -29
- package/js/src/bitvavo.js +38 -30
- package/js/src/bl3p.js +11 -10
- package/js/src/blockchaincom.js +20 -20
- package/js/src/btcalpha.js +18 -17
- package/js/src/btcbox.js +13 -12
- package/js/src/btcmarkets.js +20 -19
- package/js/src/btcturk.js +14 -13
- package/js/src/bybit.d.ts +1 -1
- package/js/src/bybit.js +84 -54
- package/js/src/cex.js +16 -14
- package/js/src/coinbase.js +29 -27
- package/js/src/coinbasepro.js +27 -25
- package/js/src/coincheck.js +15 -14
- package/js/src/coinex.d.ts +1 -1
- package/js/src/coinex.js +100 -77
- package/js/src/coinlist.js +28 -27
- package/js/src/coinmate.js +21 -18
- package/js/src/coinone.js +21 -16
- package/js/src/coinsph.js +37 -28
- package/js/src/coinspot.js +12 -11
- package/js/src/cryptocom.d.ts +0 -23
- package/js/src/cryptocom.js +40 -202
- package/js/src/currencycom.js +32 -25
- package/js/src/delta.js +35 -29
- package/js/src/deribit.js +39 -36
- package/js/src/digifinex.d.ts +2 -2
- package/js/src/digifinex.js +65 -45
- package/js/src/exmo.js +29 -27
- package/js/src/gate.d.ts +1 -1
- package/js/src/gate.js +67 -53
- package/js/src/gemini.js +23 -20
- package/js/src/hitbtc.d.ts +1 -0
- package/js/src/hitbtc.js +65 -56
- package/js/src/hollaex.js +30 -27
- package/js/src/htx.d.ts +11 -3
- package/js/src/htx.js +132 -143
- package/js/src/huobijp.js +23 -21
- package/js/src/idex.js +22 -21
- package/js/src/independentreserve.js +15 -14
- package/js/src/indodax.js +30 -26
- package/js/src/kraken.js +29 -27
- package/js/src/krakenfutures.js +29 -22
- package/js/src/kucoin.d.ts +1 -1
- package/js/src/kucoin.js +48 -43
- package/js/src/kucoinfutures.js +33 -28
- package/js/src/kuna.js +25 -24
- package/js/src/latoken.js +25 -23
- package/js/src/lbank.js +46 -31
- package/js/src/luno.js +22 -19
- package/js/src/lykke.js +19 -17
- package/js/src/mercado.js +30 -19
- package/js/src/mexc.d.ts +1 -1
- package/js/src/mexc.js +60 -49
- package/js/src/ndax.js +23 -22
- package/js/src/novadax.js +23 -22
- package/js/src/oceanex.js +22 -19
- package/js/src/okcoin.js +29 -23
- package/js/src/okx.d.ts +2 -2
- package/js/src/okx.js +87 -82
- package/js/src/p2b.d.ts +8 -7
- package/js/src/p2b.js +79 -81
- package/js/src/paymium.js +10 -10
- package/js/src/phemex.js +63 -40
- package/js/src/poloniex.js +22 -22
- package/js/src/poloniexfutures.js +23 -19
- package/js/src/pro/alpaca.js +5 -5
- package/js/src/pro/ascendex.js +4 -4
- package/js/src/pro/binance.js +16 -16
- package/js/src/pro/bingx.js +1 -1
- package/js/src/pro/bitfinex.js +4 -4
- package/js/src/pro/bitfinex2.d.ts +1 -1
- package/js/src/pro/bitfinex2.js +6 -6
- package/js/src/pro/bitget.js +7 -7
- package/js/src/pro/bitmart.js +7 -5
- package/js/src/pro/bitmex.js +6 -6
- package/js/src/pro/bitopro.js +4 -4
- package/js/src/pro/bitpanda.js +6 -6
- package/js/src/pro/bitrue.js +2 -2
- package/js/src/pro/bitstamp.js +7 -5
- package/js/src/pro/bittrex.js +6 -6
- package/js/src/pro/bitvavo.js +12 -8
- package/js/src/pro/blockchaincom.js +8 -8
- package/js/src/pro/bybit.js +7 -7
- package/js/src/pro/cex.js +14 -10
- package/js/src/pro/coinbase.js +5 -5
- package/js/src/pro/coinbasepro.js +12 -11
- package/js/src/pro/coinex.js +7 -9
- package/js/src/pro/cryptocom.js +9 -9
- package/js/src/pro/currencycom.js +4 -4
- package/js/src/pro/deribit.js +6 -6
- package/js/src/pro/exmo.js +12 -14
- package/js/src/pro/gate.js +7 -7
- package/js/src/pro/gemini.js +3 -3
- package/js/src/pro/hitbtc.d.ts +8 -1
- package/js/src/pro/hitbtc.js +264 -5
- package/js/src/pro/hollaex.js +5 -5
- package/js/src/pro/htx.js +6 -6
- package/js/src/pro/huobijp.js +3 -3
- package/js/src/pro/idex.js +4 -4
- package/js/src/pro/independentreserve.js +2 -2
- package/js/src/pro/kraken.js +10 -10
- package/js/src/pro/krakenfutures.d.ts +1 -0
- package/js/src/pro/krakenfutures.js +42 -18
- package/js/src/pro/kucoin.js +7 -7
- package/js/src/pro/kucoinfutures.js +8 -6
- package/js/src/pro/luno.js +2 -2
- package/js/src/pro/mexc.js +6 -6
- package/js/src/pro/ndax.js +3 -3
- package/js/src/pro/okcoin.js +5 -5
- package/js/src/pro/okx.js +12 -12
- package/js/src/pro/phemex.js +6 -6
- package/js/src/pro/poloniex.js +7 -7
- package/js/src/pro/poloniexfutures.js +5 -5
- package/js/src/pro/probit.js +6 -6
- package/js/src/pro/upbit.js +3 -3
- package/js/src/pro/wazirx.js +8 -8
- package/js/src/pro/whitebit.js +13 -9
- package/js/src/pro/woo.js +1 -1
- package/js/src/probit.js +29 -24
- package/js/src/tidex.js +16 -15
- package/js/src/timex.js +19 -18
- package/js/src/tokocrypto.js +28 -23
- package/js/src/upbit.js +19 -19
- package/js/src/wavesexchange.js +23 -20
- package/js/src/wazirx.js +25 -18
- package/js/src/whitebit.js +33 -27
- package/js/src/woo.js +45 -35
- package/js/src/yobit.js +25 -20
- package/js/src/zaif.js +9 -9
- package/js/src/zonda.js +18 -17
- package/package.json +1 -1
package/dist/cjs/src/yobit.js
CHANGED
|
@@ -38,11 +38,10 @@ class yobit extends yobit$1 {
|
|
|
38
38
|
'createStopMarketOrder': false,
|
|
39
39
|
'createStopOrder': false,
|
|
40
40
|
'fetchBalance': true,
|
|
41
|
-
'fetchBorrowRate': false,
|
|
42
41
|
'fetchBorrowRateHistories': false,
|
|
43
42
|
'fetchBorrowRateHistory': false,
|
|
44
|
-
'
|
|
45
|
-
'
|
|
43
|
+
'fetchCrossBorrowRate': false,
|
|
44
|
+
'fetchCrossBorrowRates': false,
|
|
46
45
|
'fetchDepositAddress': true,
|
|
47
46
|
'fetchDeposits': false,
|
|
48
47
|
'fetchFundingHistory': false,
|
|
@@ -50,6 +49,8 @@ class yobit extends yobit$1 {
|
|
|
50
49
|
'fetchFundingRateHistory': false,
|
|
51
50
|
'fetchFundingRates': false,
|
|
52
51
|
'fetchIndexOHLCV': false,
|
|
52
|
+
'fetchIsolatedBorrowRate': false,
|
|
53
|
+
'fetchIsolatedBorrowRates': false,
|
|
53
54
|
'fetchLeverage': false,
|
|
54
55
|
'fetchLeverageTiers': false,
|
|
55
56
|
'fetchMarginMode': false,
|
|
@@ -305,7 +306,7 @@ class yobit extends yobit$1 {
|
|
|
305
306
|
* @see https://yobit.net/en/api
|
|
306
307
|
* @description query for balance and get the amount of funds available for trading or funds locked in orders
|
|
307
308
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
308
|
-
* @returns {object} a [balance structure]{@link https://
|
|
309
|
+
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
309
310
|
*/
|
|
310
311
|
await this.loadMarkets();
|
|
311
312
|
const response = await this.privatePostGetInfo(params);
|
|
@@ -442,7 +443,7 @@ class yobit extends yobit$1 {
|
|
|
442
443
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
443
444
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
444
445
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
445
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
446
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
446
447
|
*/
|
|
447
448
|
await this.loadMarkets();
|
|
448
449
|
const market = this.market(symbol);
|
|
@@ -469,7 +470,7 @@ class yobit extends yobit$1 {
|
|
|
469
470
|
* @param {string[]|undefined} symbols list of unified market symbols, all symbols fetched if undefined, default is undefined
|
|
470
471
|
* @param {int} [limit] max number of entries per orderbook to return, default is undefined
|
|
471
472
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
472
|
-
* @returns {object} a dictionary of [order book structures]{@link https://
|
|
473
|
+
* @returns {object} a dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbol
|
|
473
474
|
*/
|
|
474
475
|
await this.loadMarkets();
|
|
475
476
|
let ids = undefined;
|
|
@@ -549,7 +550,7 @@ class yobit extends yobit$1 {
|
|
|
549
550
|
* @description fetches price tickers for multiple markets, statistical calculations with the information calculated over the past 24 hours each market
|
|
550
551
|
* @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
|
|
551
552
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
552
|
-
* @returns {object} a dictionary of [ticker structures]{@link https://
|
|
553
|
+
* @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
553
554
|
*/
|
|
554
555
|
if (symbols === undefined) {
|
|
555
556
|
throw new errors.ArgumentsRequired(this.id + ' fetchTickers() requires "symbols" argument');
|
|
@@ -595,7 +596,7 @@ class yobit extends yobit$1 {
|
|
|
595
596
|
* @description fetches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
596
597
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
597
598
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
598
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
599
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
599
600
|
*/
|
|
600
601
|
const tickers = await this.fetchTickers([symbol], params);
|
|
601
602
|
return tickers[symbol];
|
|
@@ -689,7 +690,7 @@ class yobit extends yobit$1 {
|
|
|
689
690
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
690
691
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
691
692
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
692
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://
|
|
693
|
+
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
693
694
|
*/
|
|
694
695
|
await this.loadMarkets();
|
|
695
696
|
const market = this.market(symbol);
|
|
@@ -729,7 +730,7 @@ class yobit extends yobit$1 {
|
|
|
729
730
|
* @see https://yobit.net/en/api
|
|
730
731
|
* @description fetch the trading fees for multiple markets
|
|
731
732
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
732
|
-
* @returns {object} a dictionary of [fee structures]{@link https://
|
|
733
|
+
* @returns {object} a dictionary of [fee structures]{@link https://docs.ccxt.com/#/?id=fee-structure} indexed by market symbols
|
|
733
734
|
*/
|
|
734
735
|
await this.loadMarkets();
|
|
735
736
|
const response = await this.publicGetInfo(params);
|
|
@@ -786,7 +787,7 @@ class yobit extends yobit$1 {
|
|
|
786
787
|
* @param {float} amount how much of currency you want to trade in units of base currency
|
|
787
788
|
* @param {float} [price] the price at which the order is to be fullfilled, in units of the quote currency, ignored in market orders
|
|
788
789
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
789
|
-
* @returns {object} an [order structure]{@link https://
|
|
790
|
+
* @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
790
791
|
*/
|
|
791
792
|
if (type === 'market') {
|
|
792
793
|
throw new errors.ExchangeError(this.id + ' createOrder() allows limit orders only');
|
|
@@ -833,7 +834,7 @@ class yobit extends yobit$1 {
|
|
|
833
834
|
* @param {string} id order id
|
|
834
835
|
* @param {string} symbol not used by yobit cancelOrder ()
|
|
835
836
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
836
|
-
* @returns {object} An [order structure]{@link https://
|
|
837
|
+
* @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
837
838
|
*/
|
|
838
839
|
await this.loadMarkets();
|
|
839
840
|
const request = {
|
|
@@ -982,7 +983,7 @@ class yobit extends yobit$1 {
|
|
|
982
983
|
* @description fetches information on an order made by the user
|
|
983
984
|
* @param {string} symbol not used by yobit fetchOrder
|
|
984
985
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
985
|
-
* @returns {object} An [order structure]{@link https://
|
|
986
|
+
* @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
986
987
|
*/
|
|
987
988
|
await this.loadMarkets();
|
|
988
989
|
const request = {
|
|
@@ -1019,9 +1020,11 @@ class yobit extends yobit$1 {
|
|
|
1019
1020
|
* @param {int} [since] the earliest time in ms to fetch open orders for
|
|
1020
1021
|
* @param {int} [limit] the maximum number of open order structures to retrieve
|
|
1021
1022
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
1022
|
-
* @returns {Order[]} a list of [order structures]{@link https://
|
|
1023
|
+
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
1023
1024
|
*/
|
|
1024
|
-
|
|
1025
|
+
if (symbol === undefined) {
|
|
1026
|
+
throw new errors.ArgumentsRequired(this.id + ' fetchOpenOrders() requires a symbol argument');
|
|
1027
|
+
}
|
|
1025
1028
|
await this.loadMarkets();
|
|
1026
1029
|
const request = {};
|
|
1027
1030
|
const market = undefined;
|
|
@@ -1066,9 +1069,11 @@ class yobit extends yobit$1 {
|
|
|
1066
1069
|
* @param {int} [since] the earliest time in ms to fetch trades for
|
|
1067
1070
|
* @param {int} [limit] the maximum number of trades structures to retrieve
|
|
1068
1071
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
1069
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://
|
|
1072
|
+
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure}
|
|
1070
1073
|
*/
|
|
1071
|
-
|
|
1074
|
+
if (symbol === undefined) {
|
|
1075
|
+
throw new errors.ArgumentsRequired(this.id + ' fetchMyTrades() requires a symbol argument');
|
|
1076
|
+
}
|
|
1072
1077
|
await this.loadMarkets();
|
|
1073
1078
|
const market = this.market(symbol);
|
|
1074
1079
|
// some derived classes use camelcase notation for request fields
|
|
@@ -1125,7 +1130,7 @@ class yobit extends yobit$1 {
|
|
|
1125
1130
|
* @description create a currency deposit address
|
|
1126
1131
|
* @param {string} code unified currency code of the currency for the deposit address
|
|
1127
1132
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
1128
|
-
* @returns {object} an [address structure]{@link https://
|
|
1133
|
+
* @returns {object} an [address structure]{@link https://docs.ccxt.com/#/?id=address-structure}
|
|
1129
1134
|
*/
|
|
1130
1135
|
const request = {
|
|
1131
1136
|
'need_new': 1,
|
|
@@ -1148,7 +1153,7 @@ class yobit extends yobit$1 {
|
|
|
1148
1153
|
* @description fetch the deposit address for a currency associated with this account
|
|
1149
1154
|
* @param {string} code unified currency code
|
|
1150
1155
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
1151
|
-
* @returns {object} an [address structure]{@link https://
|
|
1156
|
+
* @returns {object} an [address structure]{@link https://docs.ccxt.com/#/?id=address-structure}
|
|
1152
1157
|
*/
|
|
1153
1158
|
await this.loadMarkets();
|
|
1154
1159
|
const currency = this.currency(code);
|
|
@@ -1188,7 +1193,7 @@ class yobit extends yobit$1 {
|
|
|
1188
1193
|
* @param {string} address the address to withdraw to
|
|
1189
1194
|
* @param {string} tag
|
|
1190
1195
|
* @param {object} [params] extra parameters specific to the yobit api endpoint
|
|
1191
|
-
* @returns {object} a [transaction structure]{@link https://
|
|
1196
|
+
* @returns {object} a [transaction structure]{@link https://docs.ccxt.com/#/?id=transaction-structure}
|
|
1192
1197
|
*/
|
|
1193
1198
|
[tag, params] = this.handleWithdrawTagAndParams(tag, params);
|
|
1194
1199
|
this.checkAddress(address);
|
package/dist/cjs/src/zaif.js
CHANGED
|
@@ -261,7 +261,7 @@ class zaif extends zaif$1 {
|
|
|
261
261
|
* @see https://zaif-api-document.readthedocs.io/ja/latest/TradingAPI.html#id10
|
|
262
262
|
* @description query for balance and get the amount of funds available for trading or funds locked in orders
|
|
263
263
|
* @param {object} [params] extra parameters specific to the zaif api endpoint
|
|
264
|
-
* @returns {object} a [balance structure]{@link https://
|
|
264
|
+
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
265
265
|
*/
|
|
266
266
|
await this.loadMarkets();
|
|
267
267
|
const response = await this.privatePostGetInfo(params);
|
|
@@ -276,7 +276,7 @@ class zaif extends zaif$1 {
|
|
|
276
276
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
277
277
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
278
278
|
* @param {object} [params] extra parameters specific to the zaif api endpoint
|
|
279
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
279
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
280
280
|
*/
|
|
281
281
|
await this.loadMarkets();
|
|
282
282
|
const market = this.market(symbol);
|
|
@@ -335,7 +335,7 @@ class zaif extends zaif$1 {
|
|
|
335
335
|
* @description fetches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
336
336
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
337
337
|
* @param {object} [params] extra parameters specific to the zaif api endpoint
|
|
338
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
338
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
339
339
|
*/
|
|
340
340
|
await this.loadMarkets();
|
|
341
341
|
const market = this.market(symbol);
|
|
@@ -403,7 +403,7 @@ class zaif extends zaif$1 {
|
|
|
403
403
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
404
404
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
405
405
|
* @param {object} [params] extra parameters specific to the zaif api endpoint
|
|
406
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://
|
|
406
|
+
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
407
407
|
*/
|
|
408
408
|
await this.loadMarkets();
|
|
409
409
|
const market = this.market(symbol);
|
|
@@ -444,7 +444,7 @@ class zaif extends zaif$1 {
|
|
|
444
444
|
* @param {float} amount how much of currency you want to trade in units of base currency
|
|
445
445
|
* @param {float} [price] the price at which the order is to be fullfilled, in units of the quote currency, ignored in market orders
|
|
446
446
|
* @param {object} [params] extra parameters specific to the zaif api endpoint
|
|
447
|
-
* @returns {object} an [order structure]{@link https://
|
|
447
|
+
* @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
448
448
|
*/
|
|
449
449
|
await this.loadMarkets();
|
|
450
450
|
if (type !== 'limit') {
|
|
@@ -472,7 +472,7 @@ class zaif extends zaif$1 {
|
|
|
472
472
|
* @param {string} id order id
|
|
473
473
|
* @param {string} symbol not used by zaif cancelOrder ()
|
|
474
474
|
* @param {object} [params] extra parameters specific to the zaif api endpoint
|
|
475
|
-
* @returns {object} An [order structure]{@link https://
|
|
475
|
+
* @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
476
476
|
*/
|
|
477
477
|
const request = {
|
|
478
478
|
'order_id': id,
|
|
@@ -533,7 +533,7 @@ class zaif extends zaif$1 {
|
|
|
533
533
|
* @param {int} [since] the earliest time in ms to fetch open orders for
|
|
534
534
|
* @param {int} [limit] the maximum number of open orders structures to retrieve
|
|
535
535
|
* @param {object} [params] extra parameters specific to the zaif api endpoint
|
|
536
|
-
* @returns {Order[]} a list of [order structures]{@link https://
|
|
536
|
+
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
537
537
|
*/
|
|
538
538
|
await this.loadMarkets();
|
|
539
539
|
let market = undefined;
|
|
@@ -558,7 +558,7 @@ class zaif extends zaif$1 {
|
|
|
558
558
|
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
559
559
|
* @param {int} [limit] the maximum number of orde structures to retrieve
|
|
560
560
|
* @param {object} [params] extra parameters specific to the zaif api endpoint
|
|
561
|
-
* @returns {Order[]} a list of [order structures]{@link https://
|
|
561
|
+
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
562
562
|
*/
|
|
563
563
|
await this.loadMarkets();
|
|
564
564
|
let market = undefined;
|
|
@@ -590,7 +590,7 @@ class zaif extends zaif$1 {
|
|
|
590
590
|
* @param {string} address the address to withdraw to
|
|
591
591
|
* @param {string} tag
|
|
592
592
|
* @param {object} [params] extra parameters specific to the zaif api endpoint
|
|
593
|
-
* @returns {object} a [transaction structure]{@link https://
|
|
593
|
+
* @returns {object} a [transaction structure]{@link https://docs.ccxt.com/#/?id=transaction-structure}
|
|
594
594
|
*/
|
|
595
595
|
[tag, params] = this.handleWithdrawTagAndParams(tag, params);
|
|
596
596
|
this.checkAddress(address);
|
package/dist/cjs/src/zonda.js
CHANGED
|
@@ -34,11 +34,10 @@ class zonda extends zonda$1 {
|
|
|
34
34
|
'createOrder': true,
|
|
35
35
|
'createReduceOnlyOrder': false,
|
|
36
36
|
'fetchBalance': true,
|
|
37
|
-
'fetchBorrowRate': false,
|
|
38
37
|
'fetchBorrowRateHistories': false,
|
|
39
38
|
'fetchBorrowRateHistory': false,
|
|
40
|
-
'
|
|
41
|
-
'
|
|
39
|
+
'fetchCrossBorrowRate': false,
|
|
40
|
+
'fetchCrossBorrowRates': false,
|
|
42
41
|
'fetchDeposit': false,
|
|
43
42
|
'fetchDepositAddress': true,
|
|
44
43
|
'fetchDepositAddresses': true,
|
|
@@ -48,6 +47,8 @@ class zonda extends zonda$1 {
|
|
|
48
47
|
'fetchFundingRateHistory': false,
|
|
49
48
|
'fetchFundingRates': false,
|
|
50
49
|
'fetchIndexOHLCV': false,
|
|
50
|
+
'fetchIsolatedBorrowRate': false,
|
|
51
|
+
'fetchIsolatedBorrowRates': false,
|
|
51
52
|
'fetchLedger': true,
|
|
52
53
|
'fetchLeverage': false,
|
|
53
54
|
'fetchLeverageTiers': false,
|
|
@@ -404,7 +405,7 @@ class zonda extends zonda$1 {
|
|
|
404
405
|
* @param {int} [since] the earliest time in ms to fetch open orders for
|
|
405
406
|
* @param {int} [limit] the maximum number of open orders structures to retrieve
|
|
406
407
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
407
|
-
* @returns {Order[]} a list of [order structures]{@link https://
|
|
408
|
+
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
408
409
|
*/
|
|
409
410
|
await this.loadMarkets();
|
|
410
411
|
const request = {};
|
|
@@ -472,7 +473,7 @@ class zonda extends zonda$1 {
|
|
|
472
473
|
* @param {int} [since] the earliest time in ms to fetch trades for
|
|
473
474
|
* @param {int} [limit] the maximum number of trades structures to retrieve
|
|
474
475
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
475
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://
|
|
476
|
+
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure}
|
|
476
477
|
*/
|
|
477
478
|
await this.loadMarkets();
|
|
478
479
|
const request = {};
|
|
@@ -534,7 +535,7 @@ class zonda extends zonda$1 {
|
|
|
534
535
|
* @see https://docs.zondacrypto.exchange/reference/list-of-wallets
|
|
535
536
|
* @description query for balance and get the amount of funds available for trading or funds locked in orders
|
|
536
537
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
537
|
-
* @returns {object} a [balance structure]{@link https://
|
|
538
|
+
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
538
539
|
*/
|
|
539
540
|
await this.loadMarkets();
|
|
540
541
|
const response = await this.v1_01PrivateGetBalancesBITBAYBalance(params);
|
|
@@ -549,7 +550,7 @@ class zonda extends zonda$1 {
|
|
|
549
550
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
550
551
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
551
552
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
552
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
553
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
553
554
|
*/
|
|
554
555
|
await this.loadMarkets();
|
|
555
556
|
const market = this.market(symbol);
|
|
@@ -661,7 +662,7 @@ class zonda extends zonda$1 {
|
|
|
661
662
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
662
663
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
663
664
|
* @param {string} [params.method] v1_01PublicGetTradingTickerSymbol (default) or v1_01PublicGetTradingStatsSymbol
|
|
664
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
665
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
665
666
|
*/
|
|
666
667
|
await this.loadMarkets();
|
|
667
668
|
const market = this.market(symbol);
|
|
@@ -734,7 +735,7 @@ class zonda extends zonda$1 {
|
|
|
734
735
|
* @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
|
|
735
736
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
736
737
|
* @param {string} [params.method] v1_01PublicGetTradingTicker (default) or v1_01PublicGetTradingStats
|
|
737
|
-
* @returns {object} a dictionary of [ticker structures]{@link https://
|
|
738
|
+
* @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
738
739
|
*/
|
|
739
740
|
await this.loadMarkets();
|
|
740
741
|
const method = 'v1_01PublicGetTradingTicker';
|
|
@@ -809,7 +810,7 @@ class zonda extends zonda$1 {
|
|
|
809
810
|
* @param {int} [since] timestamp in ms of the earliest ledger entry, default is undefined
|
|
810
811
|
* @param {int} [limit] max number of ledger entrys to return, default is undefined
|
|
811
812
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
812
|
-
* @returns {object} a [ledger structure]{@link https://
|
|
813
|
+
* @returns {object} a [ledger structure]{@link https://docs.ccxt.com/#/?id=ledger-structure}
|
|
813
814
|
*/
|
|
814
815
|
const balanceCurrencies = [];
|
|
815
816
|
if (code !== undefined) {
|
|
@@ -1309,7 +1310,7 @@ class zonda extends zonda$1 {
|
|
|
1309
1310
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
1310
1311
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
1311
1312
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
1312
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://
|
|
1313
|
+
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
1313
1314
|
*/
|
|
1314
1315
|
await this.loadMarkets();
|
|
1315
1316
|
const market = this.market(symbol);
|
|
@@ -1338,7 +1339,7 @@ class zonda extends zonda$1 {
|
|
|
1338
1339
|
* @param {float} amount how much of currency you want to trade in units of base currency
|
|
1339
1340
|
* @param {float} [price] the price at which the order is to be fullfilled, in units of the quote currency, ignored in market orders
|
|
1340
1341
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
1341
|
-
* @returns {object} an [order structure]{@link https://
|
|
1342
|
+
* @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
1342
1343
|
*/
|
|
1343
1344
|
await this.loadMarkets();
|
|
1344
1345
|
const market = this.market(symbol);
|
|
@@ -1466,7 +1467,7 @@ class zonda extends zonda$1 {
|
|
|
1466
1467
|
* @param {string} id order id
|
|
1467
1468
|
* @param {string} symbol unified symbol of the market the order was made in
|
|
1468
1469
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
1469
|
-
* @returns {object} An [order structure]{@link https://
|
|
1470
|
+
* @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
1470
1471
|
*/
|
|
1471
1472
|
const side = this.safeString(params, 'side');
|
|
1472
1473
|
if (side === undefined) {
|
|
@@ -1527,7 +1528,7 @@ class zonda extends zonda$1 {
|
|
|
1527
1528
|
* @param {string} code unified currency code
|
|
1528
1529
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
1529
1530
|
* @param {string} [params.walletId] Wallet id to filter deposit adresses.
|
|
1530
|
-
* @returns {object} an [address structure]{@link https://
|
|
1531
|
+
* @returns {object} an [address structure]{@link https://docs.ccxt.com/#/?id=address-structure}
|
|
1531
1532
|
*/
|
|
1532
1533
|
await this.loadMarkets();
|
|
1533
1534
|
const currency = this.currency(code);
|
|
@@ -1560,7 +1561,7 @@ class zonda extends zonda$1 {
|
|
|
1560
1561
|
* @description fetch deposit addresses for multiple currencies and chain types
|
|
1561
1562
|
* @param {string[]|undefined} codes zonda does not support filtering filtering by multiple codes and will ignore this parameter.
|
|
1562
1563
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
1563
|
-
* @returns {object} a list of [address structures]{@link https://
|
|
1564
|
+
* @returns {object} a list of [address structures]{@link https://docs.ccxt.com/#/?id=address-structure}
|
|
1564
1565
|
*/
|
|
1565
1566
|
await this.loadMarkets();
|
|
1566
1567
|
const response = await this.v1_01PrivateGetApiPaymentsDepositsCryptoAddresses(params);
|
|
@@ -1591,7 +1592,7 @@ class zonda extends zonda$1 {
|
|
|
1591
1592
|
* @param {string} fromAccount account to transfer from
|
|
1592
1593
|
* @param {string} toAccount account to transfer to
|
|
1593
1594
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
1594
|
-
* @returns {object} a [transfer structure]{@link https://
|
|
1595
|
+
* @returns {object} a [transfer structure]{@link https://docs.ccxt.com/#/?id=transfer-structure}
|
|
1595
1596
|
*/
|
|
1596
1597
|
await this.loadMarkets();
|
|
1597
1598
|
const currency = this.currency(code);
|
|
@@ -1703,7 +1704,7 @@ class zonda extends zonda$1 {
|
|
|
1703
1704
|
* @param {string} address the address to withdraw to
|
|
1704
1705
|
* @param {string} tag
|
|
1705
1706
|
* @param {object} [params] extra parameters specific to the zonda api endpoint
|
|
1706
|
-
* @returns {object} a [transaction structure]{@link https://
|
|
1707
|
+
* @returns {object} a [transaction structure]{@link https://docs.ccxt.com/#/?id=transaction-structure}
|
|
1707
1708
|
*/
|
|
1708
1709
|
[tag, params] = this.handleWithdrawTagAndParams(tag, params);
|
|
1709
1710
|
this.checkAddress(address);
|
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 { Market, Trade, Fee, Ticker, OrderBook, Order, Transaction, Tickers, Currency, Balance, DepositAddress, WithdrawalResponse, DepositAddressResponse, OHLCV, Balances, PartialBalances, Dictionary, MinMax, Position, FundingRateHistory, Liquidation, FundingHistory, MarginMode, Greeks } from './src/base/types.js';
|
|
6
6
|
import { BaseError, ExchangeError, PermissionDenied, AccountNotEnabled, AccountSuspended, ArgumentsRequired, BadRequest, BadSymbol, MarginModeAlreadySet, BadResponse, NullResponse, InsufficientFunds, InvalidAddress, InvalidOrder, OrderNotFound, OrderNotCached, CancelPending, OrderImmediatelyFillable, OrderNotFillable, DuplicateOrderId, NotSupported, NetworkError, DDoSProtection, RateLimitExceeded, ExchangeNotAvailable, OnMaintenance, InvalidNonce, RequestTimeout, AuthenticationError, AddressPending, NoChange } from './src/base/errors.js';
|
|
7
|
-
declare const version = "4.1.
|
|
7
|
+
declare const version = "4.1.56";
|
|
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, PermissionDenied, AccountNotEnabled, AccountSuspended, ArgumentsRequired, BadRequest, BadSymbol, MarginModeAlreadySet, BadResponse, NullResponse, InsufficientFunds, InvalidAddress, InvalidOrder, OrderNotFound, OrderNotCached, CancelPending, OrderImmediatelyFillable, OrderNotFillable, DuplicateOrderId, NotSupported, NetworkError, DDoSProtection, RateLimitExceeded, ExchangeNotAvailable, OnMaintenance, InvalidNonce, RequestTimeout, AuthenticationError, AddressPending, NoChange } from './src/base/errors.js';
|
|
39
39
|
//-----------------------------------------------------------------------------
|
|
40
40
|
// this is updated by vss.js when building
|
|
41
|
-
const version = '4.1.
|
|
41
|
+
const version = '4.1.57';
|
|
42
42
|
Exchange.ccxtVersion = version;
|
|
43
43
|
//-----------------------------------------------------------------------------
|
|
44
44
|
import ace from './src/ace.js';
|
|
@@ -256,6 +256,7 @@ interface Exchange {
|
|
|
256
256
|
privatePostV5PositionConfirmPendingMmr(params?: {}): Promise<implicitReturnType>;
|
|
257
257
|
privatePostV5AccountUpgradeToUta(params?: {}): Promise<implicitReturnType>;
|
|
258
258
|
privatePostV5AccountSetMarginMode(params?: {}): Promise<implicitReturnType>;
|
|
259
|
+
privatePostV5AccountSetHedgingMode(params?: {}): Promise<implicitReturnType>;
|
|
259
260
|
privatePostV5AccountMmpModify(params?: {}): Promise<implicitReturnType>;
|
|
260
261
|
privatePostV5AccountMmpReset(params?: {}): Promise<implicitReturnType>;
|
|
261
262
|
privatePostV5AssetTransferInterTransfer(params?: {}): Promise<implicitReturnType>;
|
|
@@ -61,26 +61,6 @@ interface Exchange {
|
|
|
61
61
|
v2PrivatePostPrivateGetOpenOrders(params?: {}): Promise<implicitReturnType>;
|
|
62
62
|
v2PrivatePostPrivateGetOrderDetail(params?: {}): Promise<implicitReturnType>;
|
|
63
63
|
v2PrivatePostPrivateGetTrades(params?: {}): Promise<implicitReturnType>;
|
|
64
|
-
v2PrivatePostPrivateMarginGetUserConfig(params?: {}): Promise<implicitReturnType>;
|
|
65
|
-
v2PrivatePostPrivateMarginGetAccountSummary(params?: {}): Promise<implicitReturnType>;
|
|
66
|
-
v2PrivatePostPrivateMarginTransfer(params?: {}): Promise<implicitReturnType>;
|
|
67
|
-
v2PrivatePostPrivateMarginBorrow(params?: {}): Promise<implicitReturnType>;
|
|
68
|
-
v2PrivatePostPrivateMarginRepay(params?: {}): Promise<implicitReturnType>;
|
|
69
|
-
v2PrivatePostPrivateMarginGetTransferHistory(params?: {}): Promise<implicitReturnType>;
|
|
70
|
-
v2PrivatePostPrivateMarginGetBorrowHistory(params?: {}): Promise<implicitReturnType>;
|
|
71
|
-
v2PrivatePostPrivateMarginGetInterestHistory(params?: {}): Promise<implicitReturnType>;
|
|
72
|
-
v2PrivatePostPrivateMarginGetRepayHistory(params?: {}): Promise<implicitReturnType>;
|
|
73
|
-
v2PrivatePostPrivateMarginGetLiquidationHistory(params?: {}): Promise<implicitReturnType>;
|
|
74
|
-
v2PrivatePostPrivateMarginGetLiquidationOrders(params?: {}): Promise<implicitReturnType>;
|
|
75
|
-
v2PrivatePostPrivateMarginCreateOrder(params?: {}): Promise<implicitReturnType>;
|
|
76
|
-
v2PrivatePostPrivateMarginCancelOrder(params?: {}): Promise<implicitReturnType>;
|
|
77
|
-
v2PrivatePostPrivateMarginCancelAllOrders(params?: {}): Promise<implicitReturnType>;
|
|
78
|
-
v2PrivatePostPrivateMarginGetOrderHistory(params?: {}): Promise<implicitReturnType>;
|
|
79
|
-
v2PrivatePostPrivateMarginGetOpenOrders(params?: {}): Promise<implicitReturnType>;
|
|
80
|
-
v2PrivatePostPrivateMarginGetOrderDetail(params?: {}): Promise<implicitReturnType>;
|
|
81
|
-
v2PrivatePostPrivateMarginGetTrades(params?: {}): Promise<implicitReturnType>;
|
|
82
|
-
v2PrivatePostPrivateDerivTransfer(params?: {}): Promise<implicitReturnType>;
|
|
83
|
-
v2PrivatePostPrivateDerivGetTransferHistory(params?: {}): Promise<implicitReturnType>;
|
|
84
64
|
v2PrivatePostPrivateGetAccounts(params?: {}): Promise<implicitReturnType>;
|
|
85
65
|
v2PrivatePostPrivateGetSubaccountBalances(params?: {}): Promise<implicitReturnType>;
|
|
86
66
|
v2PrivatePostPrivateCreateSubaccountTransfer(params?: {}): Promise<implicitReturnType>;
|
package/js/src/ace.js
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
// ---------------------------------------------------------------------------
|
|
8
8
|
import Exchange from './abstract/ace.js';
|
|
9
|
-
import { BadRequest, AuthenticationError, InsufficientFunds, InvalidOrder } from './base/errors.js';
|
|
9
|
+
import { BadRequest, AuthenticationError, InsufficientFunds, InvalidOrder, ArgumentsRequired } from './base/errors.js';
|
|
10
10
|
import { Precise } from './base/Precise.js';
|
|
11
11
|
import { TICK_SIZE } from './base/functions/number.js';
|
|
12
12
|
import { sha256 } from './static_dependencies/noble-hashes/sha256.js';
|
|
@@ -37,11 +37,11 @@ export default class ace extends Exchange {
|
|
|
37
37
|
'createOrder': true,
|
|
38
38
|
'editOrder': false,
|
|
39
39
|
'fetchBalance': true,
|
|
40
|
-
'fetchBorrowRate': false,
|
|
41
40
|
'fetchBorrowRateHistories': false,
|
|
42
41
|
'fetchBorrowRateHistory': false,
|
|
43
|
-
'fetchBorrowRates': false,
|
|
44
42
|
'fetchClosedOrders': false,
|
|
43
|
+
'fetchCrossBorrowRate': false,
|
|
44
|
+
'fetchCrossBorrowRates': false,
|
|
45
45
|
'fetchCurrencies': false,
|
|
46
46
|
'fetchDepositAddress': false,
|
|
47
47
|
'fetchDeposits': false,
|
|
@@ -50,6 +50,8 @@ export default class ace extends Exchange {
|
|
|
50
50
|
'fetchFundingRateHistory': false,
|
|
51
51
|
'fetchFundingRates': false,
|
|
52
52
|
'fetchIndexOHLCV': false,
|
|
53
|
+
'fetchIsolatedBorrowRate': false,
|
|
54
|
+
'fetchIsolatedBorrowRates': false,
|
|
53
55
|
'fetchMarginMode': false,
|
|
54
56
|
'fetchMarkets': true,
|
|
55
57
|
'fetchMarkOHLCV': false,
|
|
@@ -289,7 +291,7 @@ export default class ace extends Exchange {
|
|
|
289
291
|
* @see https://github.com/ace-exchange/ace-official-api-docs/blob/master/api_v2.md#oapi-api---trade-data
|
|
290
292
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
291
293
|
* @param {object} [params] extra parameters specific to the ace api endpoint
|
|
292
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
294
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
293
295
|
*/
|
|
294
296
|
await this.loadMarkets();
|
|
295
297
|
const market = this.market(symbol);
|
|
@@ -315,7 +317,7 @@ export default class ace extends Exchange {
|
|
|
315
317
|
* @see https://github.com/ace-exchange/ace-official-api-docs/blob/master/api_v2.md#oapi-api---trade-data
|
|
316
318
|
* @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
|
|
317
319
|
* @param {object} [params] extra parameters specific to the ace api endpoint
|
|
318
|
-
* @returns {object} a dictionary of [ticker structures]{@link https://
|
|
320
|
+
* @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
319
321
|
*/
|
|
320
322
|
await this.loadMarkets();
|
|
321
323
|
const response = await this.publicGetOapiV2ListTradePrice();
|
|
@@ -348,7 +350,7 @@ export default class ace extends Exchange {
|
|
|
348
350
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
349
351
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
350
352
|
* @param {object} [params] extra parameters specific to the ace api endpoint
|
|
351
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
353
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
352
354
|
*/
|
|
353
355
|
await this.loadMarkets();
|
|
354
356
|
const market = this.market(symbol);
|
|
@@ -594,7 +596,7 @@ export default class ace extends Exchange {
|
|
|
594
596
|
* @param {float} amount how much of currency you want to trade in units of base currency
|
|
595
597
|
* @param {float} [price] the price at which the order is to be fullfilled, in units of the quote currency, ignored in market orders
|
|
596
598
|
* @param {object} [params] extra parameters specific to the ace api endpoint
|
|
597
|
-
* @returns {object} an [order structure]{@link https://
|
|
599
|
+
* @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
598
600
|
*/
|
|
599
601
|
await this.loadMarkets();
|
|
600
602
|
const market = this.market(symbol);
|
|
@@ -631,7 +633,7 @@ export default class ace extends Exchange {
|
|
|
631
633
|
* @param {string} id order id
|
|
632
634
|
* @param {string} symbol unified symbol of the market the order was made in
|
|
633
635
|
* @param {object} [params] extra parameters specific to the ace api endpoint
|
|
634
|
-
* @returns {object} An [order structure]{@link https://
|
|
636
|
+
* @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
635
637
|
*/
|
|
636
638
|
await this.loadMarkets();
|
|
637
639
|
const request = {
|
|
@@ -656,7 +658,7 @@ export default class ace extends Exchange {
|
|
|
656
658
|
* @see https://github.com/ace-exchange/ace-official-api-docs/blob/master/api_v2.md#open-api---order-status
|
|
657
659
|
* @param {string} symbol unified symbol of the market the order was made in
|
|
658
660
|
* @param {object} [params] extra parameters specific to the ace api endpoint
|
|
659
|
-
* @returns {object} An [order structure]{@link https://
|
|
661
|
+
* @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
660
662
|
*/
|
|
661
663
|
await this.loadMarkets();
|
|
662
664
|
const request = {
|
|
@@ -698,9 +700,11 @@ export default class ace extends Exchange {
|
|
|
698
700
|
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
699
701
|
* @param {int} [limit] the maximum number of orde structures to retrieve
|
|
700
702
|
* @param {object} [params] extra parameters specific to the ace api endpoint
|
|
701
|
-
* @returns {Order[]} a list of [order structures]{@link https://
|
|
703
|
+
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
702
704
|
*/
|
|
703
|
-
|
|
705
|
+
if (symbol === undefined) {
|
|
706
|
+
throw new ArgumentsRequired(this.id + ' fetchOpenOrders() requires a symbol argument');
|
|
707
|
+
}
|
|
704
708
|
await this.loadMarkets();
|
|
705
709
|
const market = this.market(symbol);
|
|
706
710
|
const request = {
|
|
@@ -834,7 +838,7 @@ export default class ace extends Exchange {
|
|
|
834
838
|
* @param {int} [since] the earliest time in ms to fetch trades for
|
|
835
839
|
* @param {int} [limit] the maximum number of trades to retrieve
|
|
836
840
|
* @param {object} [params] extra parameters specific to the ace api endpoint
|
|
837
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
841
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure}
|
|
838
842
|
*/
|
|
839
843
|
await this.loadMarkets();
|
|
840
844
|
const market = this.safeMarket(symbol);
|
|
@@ -889,7 +893,7 @@ export default class ace extends Exchange {
|
|
|
889
893
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
890
894
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
891
895
|
* @param {object} [params] extra parameters specific to the ace api endpoint
|
|
892
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://
|
|
896
|
+
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
893
897
|
*/
|
|
894
898
|
await this.loadMarkets();
|
|
895
899
|
const market = this.safeMarket(symbol);
|
|
@@ -974,7 +978,7 @@ export default class ace extends Exchange {
|
|
|
974
978
|
* @description query for balance and get the amount of funds available for trading or funds locked in orders
|
|
975
979
|
* @see https://github.com/ace-exchange/ace-official-api-docs/blob/master/api_v2.md#open-api---account-balance
|
|
976
980
|
* @param {object} [params] extra parameters specific to the ace api endpoint
|
|
977
|
-
* @returns {object} a [balance structure]{@link https://
|
|
981
|
+
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
978
982
|
*/
|
|
979
983
|
await this.loadMarkets();
|
|
980
984
|
const response = await this.privatePostV2CoinCustomerAccount(params);
|