ccxt 4.1.55 → 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/CONTRIBUTING.md +1 -1
- package/README.md +6 -6
- package/build.sh +30 -8
- package/dist/ccxt.browser.js +5592 -4907
- package/dist/ccxt.browser.min.js +13 -13
- 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 +17 -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 +129 -94
- 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 +101 -78
- 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 +135 -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 +92 -84
- package/dist/cjs/src/p2b.js +80 -83
- 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/bitbank.d.ts +1 -0
- package/js/src/abstract/bybit.d.ts +1 -0
- package/js/src/abstract/cryptocom.d.ts +0 -20
- package/js/src/abstract/htx.d.ts +3 -0
- package/js/src/abstract/huobi.d.ts +3 -0
- package/js/src/abstract/huobipro.d.ts +3 -0
- package/js/src/abstract/okex.d.ts +3 -1
- package/js/src/abstract/okex5.d.ts +3 -1
- package/js/src/abstract/okx.d.ts +3 -1
- 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 +17 -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 +129 -94
- 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 +101 -78
- 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 +135 -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 +92 -84
- package/js/src/p2b.d.ts +8 -7
- package/js/src/p2b.js +80 -82
- 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 +2 -2
- package/js/src/bitstamp1.d.ts +0 -28
- package/js/src/bitstamp1.js +0 -430
- package/js/src/lbank2.d.ts +0 -90
- package/js/src/lbank2.js +0 -2779
|
@@ -112,7 +112,7 @@ class coinbasepro extends coinbasepro$1 {
|
|
|
112
112
|
* @description watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
113
113
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
114
114
|
* @param {object} [params] extra parameters specific to the coinbasepro api endpoint
|
|
115
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
115
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
116
116
|
*/
|
|
117
117
|
const name = 'ticker';
|
|
118
118
|
return await this.subscribe(name, symbol, name, params);
|
|
@@ -126,7 +126,7 @@ class coinbasepro extends coinbasepro$1 {
|
|
|
126
126
|
* @param {string[]} [symbols] unified symbol of the market to fetch the ticker for
|
|
127
127
|
* @param {object} [params] extra parameters specific to the okx api endpoint
|
|
128
128
|
* @param {string} [params.channel] the channel to subscribe to, tickers by default. Can be tickers, sprd-tickers, index-tickers, block-tickers
|
|
129
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
129
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
130
130
|
*/
|
|
131
131
|
await this.loadMarkets();
|
|
132
132
|
const symbolsLength = symbols.length;
|
|
@@ -150,7 +150,7 @@ class coinbasepro extends coinbasepro$1 {
|
|
|
150
150
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
151
151
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
152
152
|
* @param {object} [params] extra parameters specific to the coinbasepro api endpoint
|
|
153
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
153
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
154
154
|
*/
|
|
155
155
|
await this.loadMarkets();
|
|
156
156
|
symbol = this.symbol(symbol);
|
|
@@ -197,9 +197,11 @@ class coinbasepro extends coinbasepro$1 {
|
|
|
197
197
|
* @param {int} [since] the earliest time in ms to fetch trades for
|
|
198
198
|
* @param {int} [limit] the maximum number of trade structures to retrieve
|
|
199
199
|
* @param {object} [params] extra parameters specific to the coinbasepro api endpoint
|
|
200
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
200
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure
|
|
201
201
|
*/
|
|
202
|
-
|
|
202
|
+
if (symbol === undefined) {
|
|
203
|
+
throw new errors.ArgumentsRequired(this.id + ' watchMyTrades() requires a symbol argument');
|
|
204
|
+
}
|
|
203
205
|
await this.loadMarkets();
|
|
204
206
|
symbol = this.symbol(symbol);
|
|
205
207
|
const name = 'user';
|
|
@@ -220,7 +222,7 @@ class coinbasepro extends coinbasepro$1 {
|
|
|
220
222
|
* @param {int} [since] the earliest time in ms to fetch trades for
|
|
221
223
|
* @param {int} [limit] the maximum number of trade structures to retrieve
|
|
222
224
|
* @param {object} [params] extra parameters specific to the coinbasepro api endpoint
|
|
223
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
225
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure
|
|
224
226
|
*/
|
|
225
227
|
symbols = this.marketSymbols(symbols, undefined, false);
|
|
226
228
|
await this.loadMarkets();
|
|
@@ -244,7 +246,7 @@ class coinbasepro extends coinbasepro$1 {
|
|
|
244
246
|
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
245
247
|
* @param {int} [limit] the maximum number of trade structures to retrieve
|
|
246
248
|
* @param {object} [params] extra parameters specific to the coinbasepro api endpoint
|
|
247
|
-
* @returns {object[]} a list of [order structures]{@link https://
|
|
249
|
+
* @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
248
250
|
*/
|
|
249
251
|
symbols = this.marketSymbols(symbols, undefined, false);
|
|
250
252
|
await this.loadMarkets();
|
|
@@ -268,7 +270,7 @@ class coinbasepro extends coinbasepro$1 {
|
|
|
268
270
|
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
269
271
|
* @param {int} [limit] the maximum number of orde structures to retrieve
|
|
270
272
|
* @param {object} [params] extra parameters specific to the coinbasepro api endpoint
|
|
271
|
-
* @returns {object[]} a list of [order structures]{@link https://
|
|
273
|
+
* @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
272
274
|
*/
|
|
273
275
|
if (symbol === undefined) {
|
|
274
276
|
throw new errors.BadSymbol(this.id + ' watchMyTrades requires a symbol');
|
|
@@ -292,7 +294,7 @@ class coinbasepro extends coinbasepro$1 {
|
|
|
292
294
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
293
295
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
294
296
|
* @param {object} [params] extra parameters specific to the coinbasepro api endpoint
|
|
295
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
297
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
296
298
|
*/
|
|
297
299
|
const name = 'level2';
|
|
298
300
|
await this.loadMarkets();
|
|
@@ -496,7 +498,6 @@ class coinbasepro extends coinbasepro$1 {
|
|
|
496
498
|
'rate': feeRate,
|
|
497
499
|
'cost': feeCost,
|
|
498
500
|
'currency': feeCurrency,
|
|
499
|
-
'type': undefined,
|
|
500
501
|
};
|
|
501
502
|
return parsed;
|
|
502
503
|
}
|
|
@@ -224,7 +224,7 @@ class coinex extends coinex$1 {
|
|
|
224
224
|
* @name coinex#watchBalance
|
|
225
225
|
* @description watch balance and get the amount of funds available for trading or funds locked in orders
|
|
226
226
|
* @param {object} [params] extra parameters specific to the coinex api endpoint
|
|
227
|
-
* @returns {object} a [balance structure]{@link https://
|
|
227
|
+
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
228
228
|
*/
|
|
229
229
|
await this.loadMarkets();
|
|
230
230
|
await this.authenticate(params);
|
|
@@ -265,11 +265,9 @@ class coinex extends coinex$1 {
|
|
|
265
265
|
const code = this.safeCurrencyCode(currencyId);
|
|
266
266
|
const available = this.safeString(first[currencyId], 'available');
|
|
267
267
|
const frozen = this.safeString(first[currencyId], 'frozen');
|
|
268
|
-
const total = Precise["default"].stringAdd(available, frozen);
|
|
269
268
|
const account = this.account();
|
|
270
|
-
account['free'] =
|
|
271
|
-
account['used'] =
|
|
272
|
-
account['total'] = this.parseNumber(total);
|
|
269
|
+
account['free'] = available;
|
|
270
|
+
account['used'] = frozen;
|
|
273
271
|
this.balance[code] = account;
|
|
274
272
|
this.balance = this.safeBalance(this.balance);
|
|
275
273
|
}
|
|
@@ -406,7 +404,7 @@ class coinex extends coinex$1 {
|
|
|
406
404
|
* @description watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
407
405
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
408
406
|
* @param {object} [params] extra parameters specific to the coinex api endpoint
|
|
409
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
407
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
410
408
|
*/
|
|
411
409
|
return await this.watchTickers([symbol], params);
|
|
412
410
|
}
|
|
@@ -418,7 +416,7 @@ class coinex extends coinex$1 {
|
|
|
418
416
|
* @description watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for all markets of a specific list
|
|
419
417
|
* @param {string[]} symbols unified symbol of the market to fetch the ticker for
|
|
420
418
|
* @param {object} [params] extra parameters specific to the coinex api endpoint
|
|
421
|
-
* @returns {object} a dictionary of [ticker structures]{@link https://
|
|
419
|
+
* @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
422
420
|
*/
|
|
423
421
|
await this.loadMarkets();
|
|
424
422
|
symbols = this.marketSymbols(symbols);
|
|
@@ -452,7 +450,7 @@ class coinex extends coinex$1 {
|
|
|
452
450
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
453
451
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
454
452
|
* @param {object} [params] extra parameters specific to the coinex api endpoint
|
|
455
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
453
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
456
454
|
*/
|
|
457
455
|
await this.loadMarkets();
|
|
458
456
|
const market = this.market(symbol);
|
|
@@ -483,7 +481,7 @@ class coinex extends coinex$1 {
|
|
|
483
481
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
484
482
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
485
483
|
* @param {object} [params] extra parameters specific to the coinex api endpoint
|
|
486
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
484
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
487
485
|
*/
|
|
488
486
|
await this.loadMarkets();
|
|
489
487
|
const market = this.market(symbol);
|
|
@@ -71,7 +71,7 @@ class cryptocom extends cryptocom$1 {
|
|
|
71
71
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
72
72
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
73
73
|
* @param {object} [params] extra parameters specific to the cryptocom api endpoint
|
|
74
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
74
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
75
75
|
*/
|
|
76
76
|
await this.loadMarkets();
|
|
77
77
|
const market = this.market(symbol);
|
|
@@ -154,7 +154,7 @@ class cryptocom extends cryptocom$1 {
|
|
|
154
154
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
155
155
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
156
156
|
* @param {object} [params] extra parameters specific to the cryptocom api endpoint
|
|
157
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
157
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
158
158
|
*/
|
|
159
159
|
await this.loadMarkets();
|
|
160
160
|
const market = this.market(symbol);
|
|
@@ -254,7 +254,7 @@ class cryptocom extends cryptocom$1 {
|
|
|
254
254
|
* @param {int} [since] the earliest time in ms to fetch trades for
|
|
255
255
|
* @param {int} [limit] the maximum number of trade structures to retrieve
|
|
256
256
|
* @param {object} [params] extra parameters specific to the cryptocom api endpoint
|
|
257
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
257
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure
|
|
258
258
|
*/
|
|
259
259
|
await this.loadMarkets();
|
|
260
260
|
let market = undefined;
|
|
@@ -278,7 +278,7 @@ class cryptocom extends cryptocom$1 {
|
|
|
278
278
|
* @see https://exchange-docs.crypto.com/exchange/v1/rest-ws/index.html#ticker-instrument_name
|
|
279
279
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
280
280
|
* @param {object} [params] extra parameters specific to the cryptocom api endpoint
|
|
281
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
281
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
282
282
|
*/
|
|
283
283
|
await this.loadMarkets();
|
|
284
284
|
const market = this.market(symbol);
|
|
@@ -386,7 +386,7 @@ class cryptocom extends cryptocom$1 {
|
|
|
386
386
|
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
387
387
|
* @param {int} [limit] the maximum number of order structures to retrieve
|
|
388
388
|
* @param {object} [params] extra parameters specific to the cryptocom api endpoint
|
|
389
|
-
* @returns {object[]} a list of [order structures]{@link https://
|
|
389
|
+
* @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
390
390
|
*/
|
|
391
391
|
await this.loadMarkets();
|
|
392
392
|
let market = undefined;
|
|
@@ -583,7 +583,7 @@ class cryptocom extends cryptocom$1 {
|
|
|
583
583
|
* @description watch balance and get the amount of funds available for trading or funds locked in orders
|
|
584
584
|
* @see https://exchange-docs.crypto.com/exchange/v1/rest-ws/index.html#user-balance
|
|
585
585
|
* @param {object} [params] extra parameters specific to the cryptocom api endpoint
|
|
586
|
-
* @returns {object} a [balance structure]{@link https://
|
|
586
|
+
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
587
587
|
*/
|
|
588
588
|
const messageHash = 'user.balance';
|
|
589
589
|
return await this.watchPrivateSubscribe(messageHash, params);
|
|
@@ -664,7 +664,7 @@ class cryptocom extends cryptocom$1 {
|
|
|
664
664
|
* @param {float} amount how much of currency you want to trade in units of base currency
|
|
665
665
|
* @param {float} [price] the price at which the order is to be fullfilled, in units of the quote currency, ignored in market orders
|
|
666
666
|
* @param {object} [params] extra parameters specific to the cryptocom api endpoint
|
|
667
|
-
* @returns {object} an [order structure]{@link https://
|
|
667
|
+
* @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
668
668
|
*/
|
|
669
669
|
await this.loadMarkets();
|
|
670
670
|
params = this.createOrderRequest(symbol, type, side, amount, price, params);
|
|
@@ -701,7 +701,7 @@ class cryptocom extends cryptocom$1 {
|
|
|
701
701
|
* @param {string} id the order id of the order to cancel
|
|
702
702
|
* @param {string} [symbol] unified symbol of the market the order was made in
|
|
703
703
|
* @param {object} [params] extra parameters specific to the cryptocom api endpoint
|
|
704
|
-
* @returns {object} An [order structure]{@link https://
|
|
704
|
+
* @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
705
705
|
*/
|
|
706
706
|
await this.loadMarkets();
|
|
707
707
|
params = this.extend({
|
|
@@ -722,7 +722,7 @@ class cryptocom extends cryptocom$1 {
|
|
|
722
722
|
* @see https://exchange-docs.crypto.com/exchange/v1/rest-ws/index.html#private-cancel-all-orders
|
|
723
723
|
* @param {string} symbol unified market symbol of the orders to cancel
|
|
724
724
|
* @param {object} [params] extra parameters specific to the cryptocom api endpoint
|
|
725
|
-
* @returns {object} Returns exchange raw message {@link https://
|
|
725
|
+
* @returns {object} Returns exchange raw message {@link https://docs.ccxt.com/#/?id=order-structure}
|
|
726
726
|
*/
|
|
727
727
|
await this.loadMarkets();
|
|
728
728
|
let market = undefined;
|
|
@@ -329,7 +329,7 @@ class currencycom extends currencycom$1 {
|
|
|
329
329
|
* @name currencycom#watchBalance
|
|
330
330
|
* @description watch balance and get the amount of funds available for trading or funds locked in orders
|
|
331
331
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
332
|
-
* @returns {object} a [balance structure]{@link https://
|
|
332
|
+
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
333
333
|
*/
|
|
334
334
|
await this.loadMarkets();
|
|
335
335
|
return await this.watchPrivate('/api/v1/account', params);
|
|
@@ -341,7 +341,7 @@ class currencycom extends currencycom$1 {
|
|
|
341
341
|
* @description watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
342
342
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
343
343
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
344
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
344
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
345
345
|
*/
|
|
346
346
|
await this.loadMarkets();
|
|
347
347
|
const market = this.market(symbol);
|
|
@@ -372,7 +372,7 @@ class currencycom extends currencycom$1 {
|
|
|
372
372
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
373
373
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
374
374
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
375
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
375
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
376
376
|
*/
|
|
377
377
|
await this.loadMarkets();
|
|
378
378
|
symbol = this.symbol(symbol);
|
|
@@ -390,7 +390,7 @@ class currencycom extends currencycom$1 {
|
|
|
390
390
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
391
391
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
392
392
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
393
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
393
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
394
394
|
*/
|
|
395
395
|
await this.loadMarkets();
|
|
396
396
|
symbol = this.symbol(symbol);
|
|
@@ -61,7 +61,7 @@ class deribit extends deribit$1 {
|
|
|
61
61
|
* @see https://docs.deribit.com/#user-portfolio-currency
|
|
62
62
|
* @description watch balance and get the amount of funds available for trading or funds locked in orders
|
|
63
63
|
* @param {object} [params] extra parameters specific to the deribit api endpoint
|
|
64
|
-
* @returns {object} a [balance structure]{@link https://
|
|
64
|
+
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
65
65
|
*/
|
|
66
66
|
await this.authenticate(params);
|
|
67
67
|
const messageHash = 'balance';
|
|
@@ -146,7 +146,7 @@ class deribit extends deribit$1 {
|
|
|
146
146
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
147
147
|
* @param {object} [params] extra parameters specific to the deribit api endpoint
|
|
148
148
|
* @param {str} [params.interval] specify aggregation and frequency of notifications. Possible values: 100ms, raw
|
|
149
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
149
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
150
150
|
*/
|
|
151
151
|
await this.loadMarkets();
|
|
152
152
|
const market = this.market(symbol);
|
|
@@ -219,7 +219,7 @@ class deribit extends deribit$1 {
|
|
|
219
219
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
220
220
|
* @param {object} [params] extra parameters specific to the deribit api endpoint
|
|
221
221
|
* @param {str} [params.interval] specify aggregation and frequency of notifications. Possible values: 100ms, raw
|
|
222
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
222
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
223
223
|
*/
|
|
224
224
|
await this.loadMarkets();
|
|
225
225
|
const market = this.market(symbol);
|
|
@@ -299,7 +299,7 @@ class deribit extends deribit$1 {
|
|
|
299
299
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
300
300
|
* @param {object} [params] extra parameters specific to the deribit api endpoint
|
|
301
301
|
* @param {str} [params.interval] specify aggregation and frequency of notifications. Possible values: 100ms, raw
|
|
302
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
302
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
303
303
|
*/
|
|
304
304
|
await this.authenticate(params);
|
|
305
305
|
if (symbol !== undefined) {
|
|
@@ -381,7 +381,7 @@ class deribit extends deribit$1 {
|
|
|
381
381
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
382
382
|
* @param {object} [params] extra parameters specific to the deribit api endpoint
|
|
383
383
|
* @param {string} [params.interval] Frequency of notifications. Events will be aggregated over this interval. Possible values: 100ms, raw
|
|
384
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
384
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
385
385
|
*/
|
|
386
386
|
await this.loadMarkets();
|
|
387
387
|
const market = this.market(symbol);
|
|
@@ -511,7 +511,7 @@ class deribit extends deribit$1 {
|
|
|
511
511
|
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
512
512
|
* @param {int} [limit] the maximum number of orde structures to retrieve
|
|
513
513
|
* @param {object} [params] extra parameters specific to the deribit api endpoint
|
|
514
|
-
* @returns {object[]} a list of [order structures]{@link https://
|
|
514
|
+
* @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure
|
|
515
515
|
*/
|
|
516
516
|
await this.loadMarkets();
|
|
517
517
|
await this.authenticate(params);
|
package/dist/cjs/src/pro/exmo.js
CHANGED
|
@@ -46,7 +46,7 @@ class exmo extends exmo$1 {
|
|
|
46
46
|
* @name exmo#watchBalance
|
|
47
47
|
* @description watch balance and get the amount of funds available for trading or funds locked in orders
|
|
48
48
|
* @param {object} [params] extra parameters specific to the exmo api endpoint
|
|
49
|
-
* @returns {object} a [balance structure]{@link https://
|
|
49
|
+
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
50
50
|
*/
|
|
51
51
|
await this.authenticate(params);
|
|
52
52
|
const [type, query] = this.handleMarketTypeAndParams('watchBalance', undefined, params);
|
|
@@ -149,11 +149,9 @@ class exmo extends exmo$1 {
|
|
|
149
149
|
for (let i = 0; i < currencies.length; i++) {
|
|
150
150
|
const currencyId = currencies[i];
|
|
151
151
|
const code = this.safeCurrencyCode(currencyId);
|
|
152
|
-
const free = balances[currencyId];
|
|
153
|
-
const used = reserved[currencyId];
|
|
154
152
|
const account = this.account();
|
|
155
|
-
account['free'] = this.
|
|
156
|
-
account['used'] = this.
|
|
153
|
+
account['free'] = this.safeString(balances, currencyId);
|
|
154
|
+
account['used'] = this.safeString(reserved, currencyId);
|
|
157
155
|
this.balance[code] = account;
|
|
158
156
|
}
|
|
159
157
|
}
|
|
@@ -161,8 +159,8 @@ class exmo extends exmo$1 {
|
|
|
161
159
|
const currencyId = this.safeString(data, 'currency');
|
|
162
160
|
const code = this.safeCurrencyCode(currencyId);
|
|
163
161
|
const account = this.account();
|
|
164
|
-
account['free'] = this.
|
|
165
|
-
account['used'] = this.
|
|
162
|
+
account['free'] = this.safeString(data, 'balance');
|
|
163
|
+
account['used'] = this.safeString(data, 'reserved');
|
|
166
164
|
this.balance[code] = account;
|
|
167
165
|
}
|
|
168
166
|
this.balance = this.safeBalance(this.balance);
|
|
@@ -190,9 +188,9 @@ class exmo extends exmo$1 {
|
|
|
190
188
|
const code = this.safeCurrencyCode(currencyId);
|
|
191
189
|
const wallet = this.safeValue(data, currencyId);
|
|
192
190
|
const account = this.account();
|
|
193
|
-
account['free'] = this.
|
|
194
|
-
account['used'] = this.
|
|
195
|
-
account['total'] = this.
|
|
191
|
+
account['free'] = this.safeString(wallet, 'free');
|
|
192
|
+
account['used'] = this.safeString(wallet, 'used');
|
|
193
|
+
account['total'] = this.safeString(wallet, 'balance');
|
|
196
194
|
this.balance[code] = account;
|
|
197
195
|
this.balance = this.safeBalance(this.balance);
|
|
198
196
|
}
|
|
@@ -204,7 +202,7 @@ class exmo extends exmo$1 {
|
|
|
204
202
|
* @description watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
205
203
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
206
204
|
* @param {object} [params] extra parameters specific to the exmo api endpoint
|
|
207
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
205
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
208
206
|
*/
|
|
209
207
|
await this.loadMarkets();
|
|
210
208
|
const market = this.market(symbol);
|
|
@@ -261,7 +259,7 @@ class exmo extends exmo$1 {
|
|
|
261
259
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
262
260
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
263
261
|
* @param {object} [params] extra parameters specific to the exmo api endpoint
|
|
264
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
262
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
265
263
|
*/
|
|
266
264
|
await this.loadMarkets();
|
|
267
265
|
const market = this.market(symbol);
|
|
@@ -325,7 +323,7 @@ class exmo extends exmo$1 {
|
|
|
325
323
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
326
324
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
327
325
|
* @param {object} [params] extra parameters specific to the exmo api endpoint
|
|
328
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
326
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
329
327
|
*/
|
|
330
328
|
await this.loadMarkets();
|
|
331
329
|
await this.authenticate(params);
|
|
@@ -454,7 +452,7 @@ class exmo extends exmo$1 {
|
|
|
454
452
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
455
453
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
456
454
|
* @param {object} [params] extra parameters specific to the exmo api endpoint
|
|
457
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
455
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
458
456
|
*/
|
|
459
457
|
await this.loadMarkets();
|
|
460
458
|
const market = this.market(symbol);
|
package/dist/cjs/src/pro/gate.js
CHANGED
|
@@ -98,7 +98,7 @@ class gate extends gate$1 {
|
|
|
98
98
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
99
99
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
100
100
|
* @param {object} [params] extra parameters specific to the gate api endpoint
|
|
101
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
101
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
102
102
|
*/
|
|
103
103
|
await this.loadMarkets();
|
|
104
104
|
const market = this.market(symbol);
|
|
@@ -275,7 +275,7 @@ class gate extends gate$1 {
|
|
|
275
275
|
* @description watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
276
276
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
277
277
|
* @param {object} [params] extra parameters specific to the gate api endpoint
|
|
278
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
278
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
279
279
|
*/
|
|
280
280
|
await this.loadMarkets();
|
|
281
281
|
const market = this.market(symbol);
|
|
@@ -296,7 +296,7 @@ class gate extends gate$1 {
|
|
|
296
296
|
* @description watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for all markets of a specific list
|
|
297
297
|
* @param {string[]} symbols unified symbol of the market to fetch the ticker for
|
|
298
298
|
* @param {object} [params] extra parameters specific to the gate api endpoint
|
|
299
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
299
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
300
300
|
*/
|
|
301
301
|
await this.loadMarkets();
|
|
302
302
|
symbols = this.marketSymbols(symbols);
|
|
@@ -383,7 +383,7 @@ class gate extends gate$1 {
|
|
|
383
383
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
384
384
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
385
385
|
* @param {object} [params] extra parameters specific to the gate api endpoint
|
|
386
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
386
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
387
387
|
*/
|
|
388
388
|
await this.loadMarkets();
|
|
389
389
|
const market = this.market(symbol);
|
|
@@ -557,7 +557,7 @@ class gate extends gate$1 {
|
|
|
557
557
|
* @param {int} [since] the earliest time in ms to fetch trades for
|
|
558
558
|
* @param {int} [limit] the maximum number of trade structures to retrieve
|
|
559
559
|
* @param {object} [params] extra parameters specific to the gate api endpoint
|
|
560
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
560
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure
|
|
561
561
|
*/
|
|
562
562
|
await this.loadMarkets();
|
|
563
563
|
let subType = undefined;
|
|
@@ -647,7 +647,7 @@ class gate extends gate$1 {
|
|
|
647
647
|
* @name gate#watchBalance
|
|
648
648
|
* @description watch balance and get the amount of funds available for trading or funds locked in orders
|
|
649
649
|
* @param {object} [params] extra parameters specific to the gate api endpoint
|
|
650
|
-
* @returns {object} a [balance structure]{@link https://
|
|
650
|
+
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
651
651
|
*/
|
|
652
652
|
await this.loadMarkets();
|
|
653
653
|
let type = undefined;
|
|
@@ -905,7 +905,7 @@ class gate extends gate$1 {
|
|
|
905
905
|
* @param {object} [params] extra parameters specific to the gate api endpoint
|
|
906
906
|
* @param {string} [params.type] spot, margin, swap, future, or option. Required if listening to all symbols.
|
|
907
907
|
* @param {boolean} [params.isInverse] if future, listen to inverse or linear contracts
|
|
908
|
-
* @returns {object[]} a list of [order structures]{@link https://
|
|
908
|
+
* @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure
|
|
909
909
|
*/
|
|
910
910
|
await this.loadMarkets();
|
|
911
911
|
let market = undefined;
|
|
@@ -42,7 +42,7 @@ class gemini extends gemini$1 {
|
|
|
42
42
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
43
43
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
44
44
|
* @param {object} [params] extra parameters specific to the gemini api endpoint
|
|
45
|
-
* @returns {object[]} a list of [trade structures]{@link https://
|
|
45
|
+
* @returns {object[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
46
46
|
*/
|
|
47
47
|
await this.loadMarkets();
|
|
48
48
|
const market = this.market(symbol);
|
|
@@ -283,7 +283,7 @@ class gemini extends gemini$1 {
|
|
|
283
283
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
284
284
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
285
285
|
* @param {object} [params] extra parameters specific to the gemini api endpoint
|
|
286
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
286
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
287
287
|
*/
|
|
288
288
|
await this.loadMarkets();
|
|
289
289
|
const market = this.market(symbol);
|
|
@@ -379,7 +379,7 @@ class gemini extends gemini$1 {
|
|
|
379
379
|
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
380
380
|
* @param {int} [limit] the maximum number of orde structures to retrieve
|
|
381
381
|
* @param {object} [params] extra parameters specific to the gemini api endpoint
|
|
382
|
-
* @returns {object[]} a list of [order structures]{@link https://
|
|
382
|
+
* @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
383
383
|
*/
|
|
384
384
|
const url = this.urls['api']['ws'] + '/v1/order/events?eventTypeFilter=initial&eventTypeFilter=accepted&eventTypeFilter=rejected&eventTypeFilter=fill&eventTypeFilter=cancelled&eventTypeFilter=booked';
|
|
385
385
|
await this.loadMarkets();
|