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
package/js/src/currencycom.js
CHANGED
|
@@ -48,13 +48,12 @@ export default class currencycom extends Exchange {
|
|
|
48
48
|
'fetchAccounts': true,
|
|
49
49
|
'fetchBalance': true,
|
|
50
50
|
'fetchBidsAsks': undefined,
|
|
51
|
-
'fetchBorrowRate': undefined,
|
|
52
51
|
'fetchBorrowRateHistory': undefined,
|
|
53
|
-
'fetchBorrowRates': undefined,
|
|
54
|
-
'fetchBorrowRatesPerSymbol': undefined,
|
|
55
52
|
'fetchCanceledOrders': undefined,
|
|
56
53
|
'fetchClosedOrder': undefined,
|
|
57
54
|
'fetchClosedOrders': undefined,
|
|
55
|
+
'fetchCrossBorrowRate': false,
|
|
56
|
+
'fetchCrossBorrowRates': false,
|
|
58
57
|
'fetchCurrencies': true,
|
|
59
58
|
'fetchDeposit': undefined,
|
|
60
59
|
'fetchDepositAddress': true,
|
|
@@ -67,6 +66,8 @@ export default class currencycom extends Exchange {
|
|
|
67
66
|
'fetchFundingRateHistory': false,
|
|
68
67
|
'fetchFundingRates': false,
|
|
69
68
|
'fetchIndexOHLCV': false,
|
|
69
|
+
'fetchIsolatedBorrowRate': false,
|
|
70
|
+
'fetchIsolatedBorrowRates': false,
|
|
70
71
|
'fetchL2OrderBook': true,
|
|
71
72
|
'fetchLedger': true,
|
|
72
73
|
'fetchLedgerEntry': false,
|
|
@@ -582,7 +583,7 @@ export default class currencycom extends Exchange {
|
|
|
582
583
|
* @name currencycom#fetchAccounts
|
|
583
584
|
* @description fetch all the accounts associated with a profile
|
|
584
585
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
585
|
-
* @returns {object} a dictionary of [account structures]{@link https://
|
|
586
|
+
* @returns {object} a dictionary of [account structures]{@link https://docs.ccxt.com/#/?id=account-structure} indexed by the account type
|
|
586
587
|
*/
|
|
587
588
|
const response = await this.privateGetV2Account(params);
|
|
588
589
|
//
|
|
@@ -638,7 +639,7 @@ export default class currencycom extends Exchange {
|
|
|
638
639
|
* @name currencycom#fetchTradingFees
|
|
639
640
|
* @description fetch the trading fees for multiple markets
|
|
640
641
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
641
|
-
* @returns {object} a dictionary of [fee structures]{@link https://
|
|
642
|
+
* @returns {object} a dictionary of [fee structures]{@link https://docs.ccxt.com/#/?id=fee-structure} indexed by market symbols
|
|
642
643
|
*/
|
|
643
644
|
await this.loadMarkets();
|
|
644
645
|
const response = await this.privateGetV2Account(params);
|
|
@@ -714,7 +715,7 @@ export default class currencycom extends Exchange {
|
|
|
714
715
|
* @name currencycom#fetchBalance
|
|
715
716
|
* @description query for balance and get the amount of funds available for trading or funds locked in orders
|
|
716
717
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
717
|
-
* @returns {object} a [balance structure]{@link https://
|
|
718
|
+
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
718
719
|
*/
|
|
719
720
|
await this.loadMarkets();
|
|
720
721
|
const response = await this.privateGetV2Account(params);
|
|
@@ -759,7 +760,7 @@ export default class currencycom extends Exchange {
|
|
|
759
760
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
760
761
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
761
762
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
762
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
763
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
763
764
|
*/
|
|
764
765
|
await this.loadMarkets();
|
|
765
766
|
const market = this.market(symbol);
|
|
@@ -874,7 +875,7 @@ export default class currencycom extends Exchange {
|
|
|
874
875
|
* @description fetches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
875
876
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
876
877
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
877
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
878
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
878
879
|
*/
|
|
879
880
|
await this.loadMarkets();
|
|
880
881
|
const market = this.market(symbol);
|
|
@@ -911,7 +912,7 @@ export default class currencycom extends Exchange {
|
|
|
911
912
|
* @description fetches price tickers for multiple markets, statistical calculations with the information calculated over the past 24 hours each market
|
|
912
913
|
* @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
|
|
913
914
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
914
|
-
* @returns {object} a dictionary of [ticker structures]{@link https://
|
|
915
|
+
* @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
915
916
|
*/
|
|
916
917
|
await this.loadMarkets();
|
|
917
918
|
const response = await this.publicGetV2Ticker24hr(params);
|
|
@@ -1076,7 +1077,7 @@ export default class currencycom extends Exchange {
|
|
|
1076
1077
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
1077
1078
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
1078
1079
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1079
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://
|
|
1080
|
+
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
1080
1081
|
*/
|
|
1081
1082
|
await this.loadMarkets();
|
|
1082
1083
|
const market = this.market(symbol);
|
|
@@ -1262,7 +1263,7 @@ export default class currencycom extends Exchange {
|
|
|
1262
1263
|
* @param {float} amount how much of currency you want to trade in units of base currency
|
|
1263
1264
|
* @param {float} [price] the price at which the order is to be fullfilled, in units of the quote currency, ignored in market orders
|
|
1264
1265
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1265
|
-
* @returns {object} an [order structure]{@link https://
|
|
1266
|
+
* @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
1266
1267
|
*/
|
|
1267
1268
|
await this.loadMarkets();
|
|
1268
1269
|
const market = this.market(symbol);
|
|
@@ -1355,9 +1356,11 @@ export default class currencycom extends Exchange {
|
|
|
1355
1356
|
* @see https://apitradedoc.currency.com/swagger-ui.html#/rest-api/getOrderUsingGET
|
|
1356
1357
|
* @param {string} symbol unified symbol of the market the order was made in
|
|
1357
1358
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1358
|
-
* @returns {object} An [order structure]{@link https://
|
|
1359
|
+
* @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
1359
1360
|
*/
|
|
1360
|
-
|
|
1361
|
+
if (symbol === undefined) {
|
|
1362
|
+
throw new ArgumentsRequired(this.id + ' fetchOrder() requires a symbol argument');
|
|
1363
|
+
}
|
|
1361
1364
|
await this.loadMarkets();
|
|
1362
1365
|
const market = this.market(symbol);
|
|
1363
1366
|
const request = {
|
|
@@ -1398,7 +1401,7 @@ export default class currencycom extends Exchange {
|
|
|
1398
1401
|
* @param {int} [since] the earliest time in ms to fetch open orders for
|
|
1399
1402
|
* @param {int} [limit] the maximum number of open orders structures to retrieve
|
|
1400
1403
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1401
|
-
* @returns {Order[]} a list of [order structures]{@link https://
|
|
1404
|
+
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
1402
1405
|
*/
|
|
1403
1406
|
await this.loadMarkets();
|
|
1404
1407
|
let market = undefined;
|
|
@@ -1443,9 +1446,11 @@ export default class currencycom extends Exchange {
|
|
|
1443
1446
|
* @param {string} id order id
|
|
1444
1447
|
* @param {string} symbol unified symbol of the market the order was made in
|
|
1445
1448
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1446
|
-
* @returns {object} An [order structure]{@link https://
|
|
1449
|
+
* @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
1447
1450
|
*/
|
|
1448
|
-
|
|
1451
|
+
if (symbol === undefined) {
|
|
1452
|
+
throw new ArgumentsRequired(this.id + ' cancelOrder() requires a symbol argument');
|
|
1453
|
+
}
|
|
1449
1454
|
await this.loadMarkets();
|
|
1450
1455
|
const market = this.market(symbol);
|
|
1451
1456
|
const origClientOrderId = this.safeValue(params, 'origClientOrderId');
|
|
@@ -1485,9 +1490,11 @@ export default class currencycom extends Exchange {
|
|
|
1485
1490
|
* @param {int} [since] the earliest time in ms to fetch trades for
|
|
1486
1491
|
* @param {int} [limit] the maximum number of trades structures to retrieve
|
|
1487
1492
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1488
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://
|
|
1493
|
+
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure}
|
|
1489
1494
|
*/
|
|
1490
|
-
|
|
1495
|
+
if (symbol === undefined) {
|
|
1496
|
+
throw new ArgumentsRequired(this.id + ' fetchMyTrades() requires a symbol argument');
|
|
1497
|
+
}
|
|
1491
1498
|
await this.loadMarkets();
|
|
1492
1499
|
const market = this.market(symbol);
|
|
1493
1500
|
const request = {
|
|
@@ -1526,7 +1533,7 @@ export default class currencycom extends Exchange {
|
|
|
1526
1533
|
* @param {int} [since] the earliest time in ms to fetch deposits for
|
|
1527
1534
|
* @param {int} [limit] the maximum number of deposits structures to retrieve
|
|
1528
1535
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1529
|
-
* @returns {object[]} a list of [transaction structures]{@link https://
|
|
1536
|
+
* @returns {object[]} a list of [transaction structures]{@link https://docs.ccxt.com/#/?id=transaction-structure}
|
|
1530
1537
|
*/
|
|
1531
1538
|
return await this.fetchTransactionsByMethod('privateGetV2Deposits', code, since, limit, params);
|
|
1532
1539
|
}
|
|
@@ -1539,7 +1546,7 @@ export default class currencycom extends Exchange {
|
|
|
1539
1546
|
* @param {int} [since] the earliest time in ms to fetch withdrawals for
|
|
1540
1547
|
* @param {int} [limit] the maximum number of withdrawals structures to retrieve
|
|
1541
1548
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1542
|
-
* @returns {object[]} a list of [transaction structures]{@link https://
|
|
1549
|
+
* @returns {object[]} a list of [transaction structures]{@link https://docs.ccxt.com/#/?id=transaction-structure}
|
|
1543
1550
|
*/
|
|
1544
1551
|
return await this.fetchTransactionsByMethod('privateGetV2Withdrawals', code, since, limit, params);
|
|
1545
1552
|
}
|
|
@@ -1552,7 +1559,7 @@ export default class currencycom extends Exchange {
|
|
|
1552
1559
|
* @param {int} [since] timestamp in ms of the earliest deposit/withdrawal, default is undefined
|
|
1553
1560
|
* @param {int} [limit] max number of deposit/withdrawals to return, default is undefined
|
|
1554
1561
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1555
|
-
* @returns {object} a list of [transaction structure]{@link https://
|
|
1562
|
+
* @returns {object} a list of [transaction structure]{@link https://docs.ccxt.com/#/?id=transaction-structure}
|
|
1556
1563
|
*/
|
|
1557
1564
|
return await this.fetchTransactionsByMethod('privateGetV2Transactions', code, since, limit, params);
|
|
1558
1565
|
}
|
|
@@ -1662,7 +1669,7 @@ export default class currencycom extends Exchange {
|
|
|
1662
1669
|
* @param {int} [since] timestamp in ms of the earliest ledger entry, default is undefined
|
|
1663
1670
|
* @param {int} [limit] max number of ledger entrys to return, default is undefined
|
|
1664
1671
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1665
|
-
* @returns {object} a [ledger structure]{@link https://
|
|
1672
|
+
* @returns {object} a [ledger structure]{@link https://docs.ccxt.com/#/?id=ledger-structure}
|
|
1666
1673
|
*/
|
|
1667
1674
|
await this.loadMarkets();
|
|
1668
1675
|
const request = {};
|
|
@@ -1761,7 +1768,7 @@ export default class currencycom extends Exchange {
|
|
|
1761
1768
|
* @description fetch the set leverage for a market
|
|
1762
1769
|
* @param {string} symbol unified market symbol
|
|
1763
1770
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1764
|
-
* @returns {object} a [leverage structure]{@link https://
|
|
1771
|
+
* @returns {object} a [leverage structure]{@link https://docs.ccxt.com/#/?id=leverage-structure}
|
|
1765
1772
|
*/
|
|
1766
1773
|
await this.loadMarkets();
|
|
1767
1774
|
const market = this.market(symbol);
|
|
@@ -1784,7 +1791,7 @@ export default class currencycom extends Exchange {
|
|
|
1784
1791
|
* @description fetch the deposit address for a currency associated with this account
|
|
1785
1792
|
* @param {string} code unified currency code
|
|
1786
1793
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1787
|
-
* @returns {object} an [address structure]{@link https://
|
|
1794
|
+
* @returns {object} an [address structure]{@link https://docs.ccxt.com/#/?id=address-structure}
|
|
1788
1795
|
*/
|
|
1789
1796
|
await this.loadMarkets();
|
|
1790
1797
|
const currency = this.currency(code);
|
|
@@ -1850,7 +1857,7 @@ export default class currencycom extends Exchange {
|
|
|
1850
1857
|
* @description fetch all open positions
|
|
1851
1858
|
* @param {string[]|undefined} symbols list of unified market symbols
|
|
1852
1859
|
* @param {object} [params] extra parameters specific to the currencycom api endpoint
|
|
1853
|
-
* @returns {object[]} a list of [position structure]{@link https://
|
|
1860
|
+
* @returns {object[]} a list of [position structure]{@link https://docs.ccxt.com/#/?id=position-structure}
|
|
1854
1861
|
*/
|
|
1855
1862
|
await this.loadMarkets();
|
|
1856
1863
|
const response = await this.privateGetV2TradingPositions(params);
|
package/js/src/delta.js
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
// ---------------------------------------------------------------------------
|
|
8
8
|
import Exchange from './abstract/delta.js';
|
|
9
|
-
import { ExchangeError, InsufficientFunds, BadRequest, BadSymbol, InvalidOrder, AuthenticationError, OrderNotFound, ExchangeNotAvailable } from './base/errors.js';
|
|
9
|
+
import { ExchangeError, InsufficientFunds, BadRequest, BadSymbol, InvalidOrder, AuthenticationError, OrderNotFound, ExchangeNotAvailable, ArgumentsRequired } from './base/errors.js';
|
|
10
10
|
import { TICK_SIZE } from './base/functions/number.js';
|
|
11
11
|
import { Precise } from './base/Precise.js';
|
|
12
12
|
import { sha256 } from './static_dependencies/noble-hashes/sha256.js';
|
|
@@ -361,7 +361,7 @@ export default class delta extends Exchange {
|
|
|
361
361
|
* @name delta#fetchStatus
|
|
362
362
|
* @description the latest known information on the availability of the exchange API
|
|
363
363
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
364
|
-
* @returns {object} a [status structure]{@link https://
|
|
364
|
+
* @returns {object} a [status structure]{@link https://docs.ccxt.com/#/?id=exchange-status-structure}
|
|
365
365
|
*/
|
|
366
366
|
const response = await this.publicGetSettings(params);
|
|
367
367
|
//
|
|
@@ -981,7 +981,7 @@ export default class delta extends Exchange {
|
|
|
981
981
|
* @see https://docs.delta.exchange/#get-ticker-for-a-product-by-symbol
|
|
982
982
|
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
983
983
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
984
|
-
* @returns {object} a [ticker structure]{@link https://
|
|
984
|
+
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
985
985
|
*/
|
|
986
986
|
await this.loadMarkets();
|
|
987
987
|
const market = this.market(symbol);
|
|
@@ -1124,7 +1124,7 @@ export default class delta extends Exchange {
|
|
|
1124
1124
|
* @see https://docs.delta.exchange/#get-tickers-for-products
|
|
1125
1125
|
* @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
|
|
1126
1126
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
1127
|
-
* @returns {object} a dictionary of [ticker structures]{@link https://
|
|
1127
|
+
* @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
1128
1128
|
*/
|
|
1129
1129
|
await this.loadMarkets();
|
|
1130
1130
|
symbols = this.marketSymbols(symbols);
|
|
@@ -1277,7 +1277,7 @@ export default class delta extends Exchange {
|
|
|
1277
1277
|
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
1278
1278
|
* @param {int} [limit] the maximum amount of order book entries to return
|
|
1279
1279
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
1280
|
-
* @returns {object} A dictionary of [order book structures]{@link https://
|
|
1280
|
+
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
1281
1281
|
*/
|
|
1282
1282
|
await this.loadMarkets();
|
|
1283
1283
|
const market = this.market(symbol);
|
|
@@ -1419,7 +1419,7 @@ export default class delta extends Exchange {
|
|
|
1419
1419
|
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
1420
1420
|
* @param {int} [limit] the maximum amount of trades to fetch
|
|
1421
1421
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
1422
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://
|
|
1422
|
+
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
|
|
1423
1423
|
*/
|
|
1424
1424
|
await this.loadMarkets();
|
|
1425
1425
|
const market = this.market(symbol);
|
|
@@ -1543,7 +1543,7 @@ export default class delta extends Exchange {
|
|
|
1543
1543
|
* @description query for balance and get the amount of funds available for trading or funds locked in orders
|
|
1544
1544
|
* @see https://docs.delta.exchange/#get-wallet-balances
|
|
1545
1545
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
1546
|
-
* @returns {object} a [balance structure]{@link https://
|
|
1546
|
+
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
|
|
1547
1547
|
*/
|
|
1548
1548
|
await this.loadMarkets();
|
|
1549
1549
|
const response = await this.privateGetWalletBalances(params);
|
|
@@ -1578,7 +1578,7 @@ export default class delta extends Exchange {
|
|
|
1578
1578
|
* @see https://docs.delta.exchange/#get-position
|
|
1579
1579
|
* @param {string} symbol unified market symbol of the market the position is held in, default is undefined
|
|
1580
1580
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
1581
|
-
* @returns {object} a [position structure]{@link https://
|
|
1581
|
+
* @returns {object} a [position structure]{@link https://docs.ccxt.com/#/?id=position-structure}
|
|
1582
1582
|
*/
|
|
1583
1583
|
await this.loadMarkets();
|
|
1584
1584
|
const market = this.market(symbol);
|
|
@@ -1607,7 +1607,7 @@ export default class delta extends Exchange {
|
|
|
1607
1607
|
* @see https://docs.delta.exchange/#get-margined-positions
|
|
1608
1608
|
* @param {string[]|undefined} symbols list of unified market symbols
|
|
1609
1609
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
1610
|
-
* @returns {object[]} a list of [position structure]{@link https://
|
|
1610
|
+
* @returns {object[]} a list of [position structure]{@link https://docs.ccxt.com/#/?id=position-structure}
|
|
1611
1611
|
*/
|
|
1612
1612
|
await this.loadMarkets();
|
|
1613
1613
|
const response = await this.privateGetPositionsMargined(params);
|
|
@@ -1813,7 +1813,7 @@ export default class delta extends Exchange {
|
|
|
1813
1813
|
* @param {float} [price] the price at which the order is to be fullfilled, in units of the quote currency, ignored in market orders
|
|
1814
1814
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
1815
1815
|
* @param {bool} [params.reduceOnly] *contract only* indicates if this order is to reduce the size of a position
|
|
1816
|
-
* @returns {object} an [order structure]{@link https://
|
|
1816
|
+
* @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
1817
1817
|
*/
|
|
1818
1818
|
await this.loadMarkets();
|
|
1819
1819
|
const orderType = type + '_order';
|
|
@@ -1895,7 +1895,7 @@ export default class delta extends Exchange {
|
|
|
1895
1895
|
* @param {float} amount how much of the currency you want to trade in units of the base currency
|
|
1896
1896
|
* @param {float} [price] the price at which the order is to be fullfilled, in units of the quote currency
|
|
1897
1897
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
1898
|
-
* @returns {object} an [order structure]{@link https://
|
|
1898
|
+
* @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
1899
1899
|
*/
|
|
1900
1900
|
await this.loadMarkets();
|
|
1901
1901
|
const market = this.market(symbol);
|
|
@@ -1941,9 +1941,11 @@ export default class delta extends Exchange {
|
|
|
1941
1941
|
* @param {string} id order id
|
|
1942
1942
|
* @param {string} symbol unified symbol of the market the order was made in
|
|
1943
1943
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
1944
|
-
* @returns {object} An [order structure]{@link https://
|
|
1944
|
+
* @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
1945
1945
|
*/
|
|
1946
|
-
|
|
1946
|
+
if (symbol === undefined) {
|
|
1947
|
+
throw new ArgumentsRequired(this.id + ' cancelOrder() requires a symbol argument');
|
|
1948
|
+
}
|
|
1947
1949
|
await this.loadMarkets();
|
|
1948
1950
|
const market = this.market(symbol);
|
|
1949
1951
|
const request = {
|
|
@@ -1998,9 +2000,11 @@ export default class delta extends Exchange {
|
|
|
1998
2000
|
* @see https://docs.delta.exchange/#cancel-all-open-orders
|
|
1999
2001
|
* @param {string} symbol unified market symbol of the market to cancel orders in
|
|
2000
2002
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
2001
|
-
* @returns {object[]} a list of [order structures]{@link https://
|
|
2003
|
+
* @returns {object[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
2002
2004
|
*/
|
|
2003
|
-
|
|
2005
|
+
if (symbol === undefined) {
|
|
2006
|
+
throw new ArgumentsRequired(this.id + ' cancelAllOrders() requires a symbol argument');
|
|
2007
|
+
}
|
|
2004
2008
|
await this.loadMarkets();
|
|
2005
2009
|
const market = this.market(symbol);
|
|
2006
2010
|
const request = {
|
|
@@ -2027,7 +2031,7 @@ export default class delta extends Exchange {
|
|
|
2027
2031
|
* @param {int} [since] the earliest time in ms to fetch open orders for
|
|
2028
2032
|
* @param {int} [limit] the maximum number of open order structures to retrieve
|
|
2029
2033
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
2030
|
-
* @returns {Order[]} a list of [order structures]{@link https://
|
|
2034
|
+
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
2031
2035
|
*/
|
|
2032
2036
|
return await this.fetchOrdersWithMethod('privateGetOrders', symbol, since, limit, params);
|
|
2033
2037
|
}
|
|
@@ -2041,7 +2045,7 @@ export default class delta extends Exchange {
|
|
|
2041
2045
|
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
2042
2046
|
* @param {int} [limit] the maximum number of order structures to retrieve
|
|
2043
2047
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
2044
|
-
* @returns {Order[]} a list of [order structures]{@link https://
|
|
2048
|
+
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
|
|
2045
2049
|
*/
|
|
2046
2050
|
return await this.fetchOrdersWithMethod('privateGetOrdersHistory', symbol, since, limit, params);
|
|
2047
2051
|
}
|
|
@@ -2105,7 +2109,7 @@ export default class delta extends Exchange {
|
|
|
2105
2109
|
* @param {int} [since] the earliest time in ms to fetch trades for
|
|
2106
2110
|
* @param {int} [limit] the maximum number of trades structures to retrieve
|
|
2107
2111
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
2108
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://
|
|
2112
|
+
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure}
|
|
2109
2113
|
*/
|
|
2110
2114
|
await this.loadMarkets();
|
|
2111
2115
|
const request = {
|
|
@@ -2187,7 +2191,7 @@ export default class delta extends Exchange {
|
|
|
2187
2191
|
* @param {int} [since] timestamp in ms of the earliest ledger entry, default is undefined
|
|
2188
2192
|
* @param {int} [limit] max number of ledger entrys to return, default is undefined
|
|
2189
2193
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
2190
|
-
* @returns {object} a [ledger structure]{@link https://
|
|
2194
|
+
* @returns {object} a [ledger structure]{@link https://docs.ccxt.com/#/?id=ledger-structure}
|
|
2191
2195
|
*/
|
|
2192
2196
|
await this.loadMarkets();
|
|
2193
2197
|
const request = {
|
|
@@ -2310,7 +2314,7 @@ export default class delta extends Exchange {
|
|
|
2310
2314
|
* @param {string} code unified currency code
|
|
2311
2315
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
2312
2316
|
* @param {string} [params.network] unified network code
|
|
2313
|
-
* @returns {object} an [address structure]{@link https://
|
|
2317
|
+
* @returns {object} an [address structure]{@link https://docs.ccxt.com/#/?id=address-structure}
|
|
2314
2318
|
*/
|
|
2315
2319
|
await this.loadMarkets();
|
|
2316
2320
|
const currency = this.currency(code);
|
|
@@ -2378,7 +2382,7 @@ export default class delta extends Exchange {
|
|
|
2378
2382
|
* @see https://docs.delta.exchange/#get-ticker-for-a-product-by-symbol
|
|
2379
2383
|
* @param {string} symbol unified market symbol
|
|
2380
2384
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
2381
|
-
* @returns {object} a [funding rate structure]{@link https://
|
|
2385
|
+
* @returns {object} a [funding rate structure]{@link https://docs.ccxt.com/#/?id=funding-rate-structure}
|
|
2382
2386
|
*/
|
|
2383
2387
|
await this.loadMarkets();
|
|
2384
2388
|
const market = this.market(symbol);
|
|
@@ -2445,7 +2449,7 @@ export default class delta extends Exchange {
|
|
|
2445
2449
|
* @see https://docs.delta.exchange/#get-tickers-for-products
|
|
2446
2450
|
* @param {string[]|undefined} symbols list of unified market symbols
|
|
2447
2451
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
2448
|
-
* @returns {object} a dictionary of [funding rates structures]{@link https://
|
|
2452
|
+
* @returns {object} a dictionary of [funding rates structures]{@link https://docs.ccxt.com/#/?id=funding-rates-structure}, indexe by market symbols
|
|
2449
2453
|
*/
|
|
2450
2454
|
await this.loadMarkets();
|
|
2451
2455
|
symbols = this.marketSymbols(symbols);
|
|
@@ -2580,7 +2584,7 @@ export default class delta extends Exchange {
|
|
|
2580
2584
|
* @param {string} symbol unified market symbol
|
|
2581
2585
|
* @param {float} amount amount of margin to add
|
|
2582
2586
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
2583
|
-
* @returns {object} a [margin structure]{@link https://
|
|
2587
|
+
* @returns {object} a [margin structure]{@link https://docs.ccxt.com/#/?id=add-margin-structure}
|
|
2584
2588
|
*/
|
|
2585
2589
|
return await this.modifyMarginHelper(symbol, amount, 'add', params);
|
|
2586
2590
|
}
|
|
@@ -2593,7 +2597,7 @@ export default class delta extends Exchange {
|
|
|
2593
2597
|
* @param {string} symbol unified market symbol
|
|
2594
2598
|
* @param {float} amount the amount of margin to remove
|
|
2595
2599
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
2596
|
-
* @returns {object} a [margin structure]{@link https://
|
|
2600
|
+
* @returns {object} a [margin structure]{@link https://docs.ccxt.com/#/?id=reduce-margin-structure}
|
|
2597
2601
|
*/
|
|
2598
2602
|
return await this.modifyMarginHelper(symbol, amount, 'reduce', params);
|
|
2599
2603
|
}
|
|
@@ -2676,7 +2680,7 @@ export default class delta extends Exchange {
|
|
|
2676
2680
|
* @see https://docs.delta.exchange/#get-ticker-for-a-product-by-symbol
|
|
2677
2681
|
* @param {string} symbol unified market symbol
|
|
2678
2682
|
* @param {object} [params] exchange specific parameters
|
|
2679
|
-
* @returns {object} an open interest structure{@link https://
|
|
2683
|
+
* @returns {object} an open interest structure{@link https://docs.ccxt.com/#/?id=open-interest-structure}
|
|
2680
2684
|
*/
|
|
2681
2685
|
await this.loadMarkets();
|
|
2682
2686
|
const market = this.market(symbol);
|
|
@@ -2813,7 +2817,7 @@ export default class delta extends Exchange {
|
|
|
2813
2817
|
* @see https://docs.delta.exchange/#get-order-leverage
|
|
2814
2818
|
* @param {string} symbol unified market symbol
|
|
2815
2819
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
2816
|
-
* @returns {object} a [leverage structure]{@link https://
|
|
2820
|
+
* @returns {object} a [leverage structure]{@link https://docs.ccxt.com/#/?id=leverage-structure}
|
|
2817
2821
|
*/
|
|
2818
2822
|
await this.loadMarkets();
|
|
2819
2823
|
const market = this.market(symbol);
|
|
@@ -2846,7 +2850,9 @@ export default class delta extends Exchange {
|
|
|
2846
2850
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
2847
2851
|
* @returns {object} response from the exchange
|
|
2848
2852
|
*/
|
|
2849
|
-
|
|
2853
|
+
if (symbol === undefined) {
|
|
2854
|
+
throw new ArgumentsRequired(this.id + ' setLeverage() requires a symbol argument');
|
|
2855
|
+
}
|
|
2850
2856
|
await this.loadMarkets();
|
|
2851
2857
|
const market = this.market(symbol);
|
|
2852
2858
|
const request = {
|
|
@@ -2876,7 +2882,7 @@ export default class delta extends Exchange {
|
|
|
2876
2882
|
* @param {int} [since] timestamp in ms
|
|
2877
2883
|
* @param {int} [limit] number of records
|
|
2878
2884
|
* @param {object} [params] exchange specific params
|
|
2879
|
-
* @returns {object[]} a list of [settlement history objects]{@link https://
|
|
2885
|
+
* @returns {object[]} a list of [settlement history objects]{@link https://docs.ccxt.com/#/?id=settlement-history-structure}
|
|
2880
2886
|
*/
|
|
2881
2887
|
await this.loadMarkets();
|
|
2882
2888
|
let market = undefined;
|
|
@@ -3032,7 +3038,7 @@ export default class delta extends Exchange {
|
|
|
3032
3038
|
* @see https://docs.delta.exchange/#get-ticker-for-a-product-by-symbol
|
|
3033
3039
|
* @param {string} symbol unified symbol of the market to fetch greeks for
|
|
3034
3040
|
* @param {object} [params] extra parameters specific to the delta api endpoint
|
|
3035
|
-
* @returns {object} a [greeks structure]{@link https://
|
|
3041
|
+
* @returns {object} a [greeks structure]{@link https://docs.ccxt.com/#/?id=greeks-structure}
|
|
3036
3042
|
*/
|
|
3037
3043
|
await this.loadMarkets();
|
|
3038
3044
|
const market = this.market(symbol);
|