ccxt 4.5.0 → 4.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +110 -112
- package/dist/ccxt.browser.min.js +5 -5
- package/dist/cjs/ccxt.js +1 -9
- package/dist/cjs/src/ascendex.js +1 -1
- package/dist/cjs/src/base/Exchange.js +13 -0
- package/dist/cjs/src/binance.js +20 -14
- package/dist/cjs/src/bitget.js +1 -1
- package/dist/cjs/src/coinbase.js +46 -34
- package/dist/cjs/src/gate.js +39 -18
- package/dist/cjs/src/gemini.js +1 -1
- package/dist/cjs/src/hibachi.js +1 -1
- package/dist/cjs/src/hyperliquid.js +16 -2
- package/dist/cjs/src/indodax.js +11 -12
- package/dist/cjs/src/kraken.js +1 -12
- package/dist/cjs/src/krakenfutures.js +25 -25
- package/dist/cjs/src/mexc.js +2 -1
- package/dist/cjs/src/okx.js +2 -2
- package/dist/cjs/src/poloniex.js +1 -1
- package/dist/cjs/src/pro/bitget.js +352 -75
- package/dist/cjs/src/pro/bitmart.js +1 -1
- package/dist/cjs/src/pro/bybit.js +8 -15
- package/dist/cjs/src/pro/gate.js +6 -1
- package/dist/cjs/src/pro/gemini.js +7 -2
- package/dist/cjs/src/pro/hyperliquid.js +9 -1
- package/dist/cjs/src/pro/kraken.js +5 -6
- package/dist/cjs/src/pro/lbank.js +55 -1
- package/dist/cjs/src/pro/mexc.js +1 -1
- package/dist/cjs/src/timex.js +35 -0
- package/dist/cjs/src/tradeogre.js +32 -0
- package/dist/cjs/src/wavesexchange.js +33 -0
- package/dist/cjs/src/zonda.js +12 -0
- package/js/ccxt.d.ts +2 -11
- package/js/ccxt.js +2 -8
- package/js/src/ascendex.js +1 -1
- package/js/src/base/Exchange.d.ts +1 -0
- package/js/src/base/Exchange.js +14 -1
- package/js/src/binance.d.ts +1 -1
- package/js/src/binance.js +20 -14
- package/js/src/bitget.js +1 -1
- package/js/src/coinbase.js +46 -34
- package/js/src/gate.d.ts +2 -1
- package/js/src/gate.js +39 -18
- package/js/src/gemini.js +1 -1
- package/js/src/hibachi.js +1 -1
- package/js/src/hyperliquid.d.ts +1 -0
- package/js/src/hyperliquid.js +16 -2
- package/js/src/indodax.js +11 -12
- package/js/src/kraken.d.ts +0 -1
- package/js/src/kraken.js +1 -12
- package/js/src/krakenfutures.d.ts +24 -24
- package/js/src/krakenfutures.js +25 -25
- package/js/src/mexc.js +2 -1
- package/js/src/okx.js +2 -2
- package/js/src/poloniex.js +1 -1
- package/js/src/pro/bitget.d.ts +12 -2
- package/js/src/pro/bitget.js +358 -75
- package/js/src/pro/bitmart.js +1 -1
- package/js/src/pro/bybit.js +8 -15
- package/js/src/pro/gate.d.ts +5 -0
- package/js/src/pro/gate.js +6 -1
- package/js/src/pro/gemini.d.ts +1 -1
- package/js/src/pro/gemini.js +7 -2
- package/js/src/pro/hyperliquid.js +9 -1
- package/js/src/pro/kraken.js +5 -6
- package/js/src/pro/lbank.d.ts +11 -1
- package/js/src/pro/lbank.js +55 -1
- package/js/src/pro/mexc.js +1 -1
- package/js/src/timex.js +35 -0
- package/js/src/tradeogre.js +32 -0
- package/js/src/wavesexchange.js +33 -0
- package/js/src/zonda.js +12 -0
- package/package.json +2 -1
- package/js/src/abstract/ellipx.d.ts +0 -28
- package/js/src/abstract/ellipx.js +0 -11
- package/js/src/abstract/vertex.d.ts +0 -22
- package/js/src/abstract/vertex.js +0 -11
- package/js/src/ellipx.d.ts +0 -237
- package/js/src/ellipx.js +0 -2071
- package/js/src/pro/vertex.d.ts +0 -104
- package/js/src/pro/vertex.js +0 -999
- package/js/src/vertex.d.ts +0 -346
- package/js/src/vertex.js +0 -3146
|
@@ -10,7 +10,7 @@ export default class krakenfutures extends Exchange {
|
|
|
10
10
|
* @method
|
|
11
11
|
* @name krakenfutures#fetchMarkets
|
|
12
12
|
* @description Fetches the available trading markets from the exchange, Multi-collateral markets are returned as linear markets, but can be settled in multiple currencies
|
|
13
|
-
* @see https://docs.
|
|
13
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-instruments
|
|
14
14
|
* @param {object} [params] exchange specific params
|
|
15
15
|
* @returns An array of market structures
|
|
16
16
|
*/
|
|
@@ -18,7 +18,7 @@ export default class krakenfutures extends Exchange {
|
|
|
18
18
|
/**
|
|
19
19
|
* @method
|
|
20
20
|
* @name krakenfutures#fetchOrderBook
|
|
21
|
-
* @see https://docs.
|
|
21
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-orderbook
|
|
22
22
|
* @description Fetches a list of open orders in a market
|
|
23
23
|
* @param {string} symbol Unified market symbol
|
|
24
24
|
* @param {int} [limit] Not used by krakenfutures
|
|
@@ -30,7 +30,7 @@ export default class krakenfutures extends Exchange {
|
|
|
30
30
|
* @method
|
|
31
31
|
* @name krakenfutures#fetchTickers
|
|
32
32
|
* @description fetches price tickers for multiple markets, statistical information calculated over the past 24 hours for each market
|
|
33
|
-
* @see https://docs.
|
|
33
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-tickers
|
|
34
34
|
* @param {string[]} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
|
|
35
35
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
36
36
|
* @returns {object} an array of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
@@ -40,7 +40,7 @@ export default class krakenfutures extends Exchange {
|
|
|
40
40
|
/**
|
|
41
41
|
* @method
|
|
42
42
|
* @name krakenfutures#fetchOHLCV
|
|
43
|
-
* @see https://docs.
|
|
43
|
+
* @see https://docs.kraken.com/api/docs/futures-api/charts/candles
|
|
44
44
|
* @description fetches historical candlestick data containing the open, high, low, and close price, and the volume of a market
|
|
45
45
|
* @param {string} symbol unified symbol of the market to fetch OHLCV data for
|
|
46
46
|
* @param {string} timeframe the length of time each candle represents
|
|
@@ -55,8 +55,8 @@ export default class krakenfutures extends Exchange {
|
|
|
55
55
|
/**
|
|
56
56
|
* @method
|
|
57
57
|
* @name krakenfutures#fetchTrades
|
|
58
|
-
* @see https://docs.
|
|
59
|
-
* @see https://docs.
|
|
58
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-history
|
|
59
|
+
* @see https://docs.kraken.com/api/docs/futures-api/history/get-public-execution-events
|
|
60
60
|
* @description Fetch a history of filled trades that this account has made
|
|
61
61
|
* @param {string} symbol Unified CCXT market symbol
|
|
62
62
|
* @param {int} [since] Timestamp in ms of earliest trade. Not used by krakenfutures except in combination with params.until
|
|
@@ -104,7 +104,7 @@ export default class krakenfutures extends Exchange {
|
|
|
104
104
|
/**
|
|
105
105
|
* @method
|
|
106
106
|
* @name krakenfutures#editOrder
|
|
107
|
-
* @see https://docs.
|
|
107
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/edit-order-spring
|
|
108
108
|
* @description Edit an open order on the exchange
|
|
109
109
|
* @param {string} id order id
|
|
110
110
|
* @param {string} symbol Not used by Krakenfutures
|
|
@@ -119,7 +119,7 @@ export default class krakenfutures extends Exchange {
|
|
|
119
119
|
/**
|
|
120
120
|
* @method
|
|
121
121
|
* @name krakenfutures#cancelOrder
|
|
122
|
-
* @see https://docs.
|
|
122
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/cancel-order
|
|
123
123
|
* @description Cancel an open order on the exchange
|
|
124
124
|
* @param {string} id Order id
|
|
125
125
|
* @param {string} symbol Not used by Krakenfutures
|
|
@@ -131,7 +131,7 @@ export default class krakenfutures extends Exchange {
|
|
|
131
131
|
* @method
|
|
132
132
|
* @name krakenfutures#cancelOrders
|
|
133
133
|
* @description cancel multiple orders
|
|
134
|
-
* @see https://docs.
|
|
134
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/send-batch-order
|
|
135
135
|
* @param {string[]} ids order ids
|
|
136
136
|
* @param {string} [symbol] unified market symbol
|
|
137
137
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
@@ -144,7 +144,7 @@ export default class krakenfutures extends Exchange {
|
|
|
144
144
|
/**
|
|
145
145
|
* @method
|
|
146
146
|
* @name krakenfutures#cancelAllOrders
|
|
147
|
-
* @see https://docs.
|
|
147
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/cancel-all-orders
|
|
148
148
|
* @description Cancels all orders on the exchange, including trigger orders
|
|
149
149
|
* @param {str} symbol Unified market symbol
|
|
150
150
|
* @param {dict} [params] Exchange specific params
|
|
@@ -155,7 +155,7 @@ export default class krakenfutures extends Exchange {
|
|
|
155
155
|
* @method
|
|
156
156
|
* @name krakenfutures#cancelAllOrdersAfter
|
|
157
157
|
* @description dead man's switch, cancel all orders after the given timeout
|
|
158
|
-
* @see https://docs.
|
|
158
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/cancel-all-orders-after
|
|
159
159
|
* @param {number} timeout time in milliseconds, 0 represents cancel the timer
|
|
160
160
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
161
161
|
* @returns {object} the api result
|
|
@@ -164,7 +164,7 @@ export default class krakenfutures extends Exchange {
|
|
|
164
164
|
/**
|
|
165
165
|
* @method
|
|
166
166
|
* @name krakenfutures#fetchOpenOrders
|
|
167
|
-
* @see https://docs.
|
|
167
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-open-orders
|
|
168
168
|
* @description Gets all open orders, including trigger orders, for an account from the exchange api
|
|
169
169
|
* @param {string} symbol Unified market symbol
|
|
170
170
|
* @param {int} [since] Timestamp (ms) of earliest order. (Not used by kraken api but filtered internally by CCXT)
|
|
@@ -188,7 +188,7 @@ export default class krakenfutures extends Exchange {
|
|
|
188
188
|
/**
|
|
189
189
|
* @method
|
|
190
190
|
* @name krakenfutures#fetchCanceledOrders
|
|
191
|
-
* @see https://docs.
|
|
191
|
+
* @see https://docs.kraken.com/api/docs/futures-api/history/get-order-events
|
|
192
192
|
* @description Gets all canceled orders, including trigger orders, for an account from the exchange api
|
|
193
193
|
* @param {string} symbol Unified market symbol
|
|
194
194
|
* @param {int} [since] Timestamp (ms) of earliest order.
|
|
@@ -205,7 +205,7 @@ export default class krakenfutures extends Exchange {
|
|
|
205
205
|
* @method
|
|
206
206
|
* @name krakenfutures#fetchMyTrades
|
|
207
207
|
* @description fetch all trades made by the user
|
|
208
|
-
* @see https://docs.
|
|
208
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-fills
|
|
209
209
|
* @param {string} symbol unified market symbol
|
|
210
210
|
* @param {int} [since] *not used by the api* the earliest time in ms to fetch trades for
|
|
211
211
|
* @param {int} [limit] the maximum number of trades structures to retrieve
|
|
@@ -217,7 +217,7 @@ export default class krakenfutures extends Exchange {
|
|
|
217
217
|
/**
|
|
218
218
|
* @method
|
|
219
219
|
* @name krakenfutures#fetchBalance
|
|
220
|
-
* @see https://docs.
|
|
220
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-accounts
|
|
221
221
|
* @description Fetch the balance for a sub-account, all sub-account balances are inside 'info' in the response
|
|
222
222
|
* @param {object} [params] Exchange specific parameters
|
|
223
223
|
* @param {string} [params.type] The sub-account type to query the balance of, possible values include 'flex', 'cash'/'main'/'funding', or a market symbol * defaults to 'flex' *
|
|
@@ -230,7 +230,7 @@ export default class krakenfutures extends Exchange {
|
|
|
230
230
|
* @method
|
|
231
231
|
* @name krakenfutures#fetchFundingRates
|
|
232
232
|
* @description fetch the current funding rates for multiple markets
|
|
233
|
-
* @see https://docs.
|
|
233
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-tickers
|
|
234
234
|
* @param {string[]} symbols unified market symbols
|
|
235
235
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
236
236
|
* @returns {Order[]} an array of [funding rate structures]{@link https://docs.ccxt.com/#/?id=funding-rate-structure}
|
|
@@ -241,7 +241,7 @@ export default class krakenfutures extends Exchange {
|
|
|
241
241
|
* @method
|
|
242
242
|
* @name krakenfutures#fetchFundingRateHistory
|
|
243
243
|
* @description fetches historical funding rate prices
|
|
244
|
-
* @see https://docs.
|
|
244
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/historical-funding-rates
|
|
245
245
|
* @param {string} symbol unified symbol of the market to fetch the funding rate history for
|
|
246
246
|
* @param {int} [since] timestamp in ms of the earliest funding rate to fetch
|
|
247
247
|
* @param {int} [limit] the maximum amount of [funding rate structures]{@link https://docs.ccxt.com/#/?id=funding-rate-history-structure} to fetch
|
|
@@ -252,7 +252,7 @@ export default class krakenfutures extends Exchange {
|
|
|
252
252
|
/**
|
|
253
253
|
* @method
|
|
254
254
|
* @name krakenfutures#fetchPositions
|
|
255
|
-
* @see https://docs.
|
|
255
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-open-positions
|
|
256
256
|
* @description Fetches current contract trading positions
|
|
257
257
|
* @param {string[]} symbols List of unified symbols
|
|
258
258
|
* @param {object} [params] Not used by krakenfutures
|
|
@@ -287,7 +287,7 @@ export default class krakenfutures extends Exchange {
|
|
|
287
287
|
* @method
|
|
288
288
|
* @name krakenfutures#fetchLeverageTiers
|
|
289
289
|
* @description retrieve information on the maximum leverage, and maintenance margin for trades of varying trade sizes
|
|
290
|
-
* @see https://docs.
|
|
290
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-instruments
|
|
291
291
|
* @param {string[]|undefined} symbols list of unified market symbols
|
|
292
292
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
293
293
|
* @returns {object} a dictionary of [leverage tiers structures]{@link https://docs.ccxt.com/#/?id=leverage-tiers-structure}, indexed by market symbols
|
|
@@ -309,8 +309,8 @@ export default class krakenfutures extends Exchange {
|
|
|
309
309
|
/**
|
|
310
310
|
* @method
|
|
311
311
|
* @name krakenfutures#transfer
|
|
312
|
-
* @see https://docs.
|
|
313
|
-
* @see https://docs.
|
|
312
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/transfer
|
|
313
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/sub-account-transfer
|
|
314
314
|
* @description transfers currencies between sub-accounts
|
|
315
315
|
* @param {string} code Unified currency code
|
|
316
316
|
* @param {float} amount Size of the transfer
|
|
@@ -324,7 +324,7 @@ export default class krakenfutures extends Exchange {
|
|
|
324
324
|
* @method
|
|
325
325
|
* @name krakenfutures#setLeverage
|
|
326
326
|
* @description set the level of leverage for a market
|
|
327
|
-
* @see https://docs.
|
|
327
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/set-leverage-setting
|
|
328
328
|
* @param {float} leverage the rate of leverage
|
|
329
329
|
* @param {string} symbol unified market symbol
|
|
330
330
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
@@ -335,7 +335,7 @@ export default class krakenfutures extends Exchange {
|
|
|
335
335
|
* @method
|
|
336
336
|
* @name krakenfutures#fetchLeverages
|
|
337
337
|
* @description fetch the set leverage for all contract and margin markets
|
|
338
|
-
* @see https://docs.
|
|
338
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-leverage-setting
|
|
339
339
|
* @param {string[]} [symbols] a list of unified market symbols
|
|
340
340
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
341
341
|
* @returns {object} a list of [leverage structures]{@link https://docs.ccxt.com/#/?id=leverage-structure}
|
|
@@ -345,7 +345,7 @@ export default class krakenfutures extends Exchange {
|
|
|
345
345
|
* @method
|
|
346
346
|
* @name krakenfutures#fetchLeverage
|
|
347
347
|
* @description fetch the set leverage for a market
|
|
348
|
-
* @see https://docs.
|
|
348
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-leverage-setting
|
|
349
349
|
* @param {string} symbol unified market symbol
|
|
350
350
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
351
351
|
* @returns {object} a [leverage structure]{@link https://docs.ccxt.com/#/?id=leverage-structure}
|
package/js/src/krakenfutures.js
CHANGED
|
@@ -103,7 +103,7 @@ export default class krakenfutures extends Exchange {
|
|
|
103
103
|
},
|
|
104
104
|
'www': 'https://futures.kraken.com/',
|
|
105
105
|
'doc': [
|
|
106
|
-
'https://docs.
|
|
106
|
+
'https://docs.kraken.com/api/docs/futures-api/trading/market-data/',
|
|
107
107
|
],
|
|
108
108
|
'fees': 'https://support.kraken.com/hc/en-us/articles/360022835771-Transaction-fees-and-rebates-for-Kraken-Futures',
|
|
109
109
|
'referral': undefined,
|
|
@@ -366,7 +366,7 @@ export default class krakenfutures extends Exchange {
|
|
|
366
366
|
* @method
|
|
367
367
|
* @name krakenfutures#fetchMarkets
|
|
368
368
|
* @description Fetches the available trading markets from the exchange, Multi-collateral markets are returned as linear markets, but can be settled in multiple currencies
|
|
369
|
-
* @see https://docs.
|
|
369
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-instruments
|
|
370
370
|
* @param {object} [params] exchange specific params
|
|
371
371
|
* @returns An array of market structures
|
|
372
372
|
*/
|
|
@@ -541,7 +541,7 @@ export default class krakenfutures extends Exchange {
|
|
|
541
541
|
/**
|
|
542
542
|
* @method
|
|
543
543
|
* @name krakenfutures#fetchOrderBook
|
|
544
|
-
* @see https://docs.
|
|
544
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-orderbook
|
|
545
545
|
* @description Fetches a list of open orders in a market
|
|
546
546
|
* @param {string} symbol Unified market symbol
|
|
547
547
|
* @param {int} [limit] Not used by krakenfutures
|
|
@@ -592,7 +592,7 @@ export default class krakenfutures extends Exchange {
|
|
|
592
592
|
* @method
|
|
593
593
|
* @name krakenfutures#fetchTickers
|
|
594
594
|
* @description fetches price tickers for multiple markets, statistical information calculated over the past 24 hours for each market
|
|
595
|
-
* @see https://docs.
|
|
595
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-tickers
|
|
596
596
|
* @param {string[]} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
|
|
597
597
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
598
598
|
* @returns {object} an array of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
@@ -711,7 +711,7 @@ export default class krakenfutures extends Exchange {
|
|
|
711
711
|
/**
|
|
712
712
|
* @method
|
|
713
713
|
* @name krakenfutures#fetchOHLCV
|
|
714
|
-
* @see https://docs.
|
|
714
|
+
* @see https://docs.kraken.com/api/docs/futures-api/charts/candles
|
|
715
715
|
* @description fetches historical candlestick data containing the open, high, low, and close price, and the volume of a market
|
|
716
716
|
* @param {string} symbol unified symbol of the market to fetch OHLCV data for
|
|
717
717
|
* @param {string} timeframe the length of time each candle represents
|
|
@@ -794,8 +794,8 @@ export default class krakenfutures extends Exchange {
|
|
|
794
794
|
/**
|
|
795
795
|
* @method
|
|
796
796
|
* @name krakenfutures#fetchTrades
|
|
797
|
-
* @see https://docs.
|
|
798
|
-
* @see https://docs.
|
|
797
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-history
|
|
798
|
+
* @see https://docs.kraken.com/api/docs/futures-api/history/get-public-execution-events
|
|
799
799
|
* @description Fetch a history of filled trades that this account has made
|
|
800
800
|
* @param {string} symbol Unified CCXT market symbol
|
|
801
801
|
* @param {int} [since] Timestamp in ms of earliest trade. Not used by krakenfutures except in combination with params.until
|
|
@@ -1240,7 +1240,7 @@ export default class krakenfutures extends Exchange {
|
|
|
1240
1240
|
/**
|
|
1241
1241
|
* @method
|
|
1242
1242
|
* @name krakenfutures#editOrder
|
|
1243
|
-
* @see https://docs.
|
|
1243
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/edit-order-spring
|
|
1244
1244
|
* @description Edit an open order on the exchange
|
|
1245
1245
|
* @param {string} id order id
|
|
1246
1246
|
* @param {string} symbol Not used by Krakenfutures
|
|
@@ -1272,7 +1272,7 @@ export default class krakenfutures extends Exchange {
|
|
|
1272
1272
|
/**
|
|
1273
1273
|
* @method
|
|
1274
1274
|
* @name krakenfutures#cancelOrder
|
|
1275
|
-
* @see https://docs.
|
|
1275
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/cancel-order
|
|
1276
1276
|
* @description Cancel an open order on the exchange
|
|
1277
1277
|
* @param {string} id Order id
|
|
1278
1278
|
* @param {string} symbol Not used by Krakenfutures
|
|
@@ -1294,7 +1294,7 @@ export default class krakenfutures extends Exchange {
|
|
|
1294
1294
|
* @method
|
|
1295
1295
|
* @name krakenfutures#cancelOrders
|
|
1296
1296
|
* @description cancel multiple orders
|
|
1297
|
-
* @see https://docs.
|
|
1297
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/send-batch-order
|
|
1298
1298
|
* @param {string[]} ids order ids
|
|
1299
1299
|
* @param {string} [symbol] unified market symbol
|
|
1300
1300
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
@@ -1357,7 +1357,7 @@ export default class krakenfutures extends Exchange {
|
|
|
1357
1357
|
/**
|
|
1358
1358
|
* @method
|
|
1359
1359
|
* @name krakenfutures#cancelAllOrders
|
|
1360
|
-
* @see https://docs.
|
|
1360
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/cancel-all-orders
|
|
1361
1361
|
* @description Cancels all orders on the exchange, including trigger orders
|
|
1362
1362
|
* @param {str} symbol Unified market symbol
|
|
1363
1363
|
* @param {dict} [params] Exchange specific params
|
|
@@ -1414,7 +1414,7 @@ export default class krakenfutures extends Exchange {
|
|
|
1414
1414
|
* @method
|
|
1415
1415
|
* @name krakenfutures#cancelAllOrdersAfter
|
|
1416
1416
|
* @description dead man's switch, cancel all orders after the given timeout
|
|
1417
|
-
* @see https://docs.
|
|
1417
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/cancel-all-orders-after
|
|
1418
1418
|
* @param {number} timeout time in milliseconds, 0 represents cancel the timer
|
|
1419
1419
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
1420
1420
|
* @returns {object} the api result
|
|
@@ -1440,7 +1440,7 @@ export default class krakenfutures extends Exchange {
|
|
|
1440
1440
|
/**
|
|
1441
1441
|
* @method
|
|
1442
1442
|
* @name krakenfutures#fetchOpenOrders
|
|
1443
|
-
* @see https://docs.
|
|
1443
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-open-orders
|
|
1444
1444
|
* @description Gets all open orders, including trigger orders, for an account from the exchange api
|
|
1445
1445
|
* @param {string} symbol Unified market symbol
|
|
1446
1446
|
* @param {int} [since] Timestamp (ms) of earliest order. (Not used by kraken api but filtered internally by CCXT)
|
|
@@ -1503,7 +1503,7 @@ export default class krakenfutures extends Exchange {
|
|
|
1503
1503
|
/**
|
|
1504
1504
|
* @method
|
|
1505
1505
|
* @name krakenfutures#fetchCanceledOrders
|
|
1506
|
-
* @see https://docs.
|
|
1506
|
+
* @see https://docs.kraken.com/api/docs/futures-api/history/get-order-events
|
|
1507
1507
|
* @description Gets all canceled orders, including trigger orders, for an account from the exchange api
|
|
1508
1508
|
* @param {string} symbol Unified market symbol
|
|
1509
1509
|
* @param {int} [since] Timestamp (ms) of earliest order.
|
|
@@ -1992,7 +1992,7 @@ export default class krakenfutures extends Exchange {
|
|
|
1992
1992
|
* @method
|
|
1993
1993
|
* @name krakenfutures#fetchMyTrades
|
|
1994
1994
|
* @description fetch all trades made by the user
|
|
1995
|
-
* @see https://docs.
|
|
1995
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-fills
|
|
1996
1996
|
* @param {string} symbol unified market symbol
|
|
1997
1997
|
* @param {int} [since] *not used by the api* the earliest time in ms to fetch trades for
|
|
1998
1998
|
* @param {int} [limit] the maximum number of trades structures to retrieve
|
|
@@ -2033,7 +2033,7 @@ export default class krakenfutures extends Exchange {
|
|
|
2033
2033
|
/**
|
|
2034
2034
|
* @method
|
|
2035
2035
|
* @name krakenfutures#fetchBalance
|
|
2036
|
-
* @see https://docs.
|
|
2036
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-accounts
|
|
2037
2037
|
* @description Fetch the balance for a sub-account, all sub-account balances are inside 'info' in the response
|
|
2038
2038
|
* @param {object} [params] Exchange specific parameters
|
|
2039
2039
|
* @param {string} [params.type] The sub-account type to query the balance of, possible values include 'flex', 'cash'/'main'/'funding', or a market symbol * defaults to 'flex' *
|
|
@@ -2257,7 +2257,7 @@ export default class krakenfutures extends Exchange {
|
|
|
2257
2257
|
* @method
|
|
2258
2258
|
* @name krakenfutures#fetchFundingRates
|
|
2259
2259
|
* @description fetch the current funding rates for multiple markets
|
|
2260
|
-
* @see https://docs.
|
|
2260
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-tickers
|
|
2261
2261
|
* @param {string[]} symbols unified market symbols
|
|
2262
2262
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
2263
2263
|
* @returns {Order[]} an array of [funding rate structures]{@link https://docs.ccxt.com/#/?id=funding-rate-structure}
|
|
@@ -2343,7 +2343,7 @@ export default class krakenfutures extends Exchange {
|
|
|
2343
2343
|
* @method
|
|
2344
2344
|
* @name krakenfutures#fetchFundingRateHistory
|
|
2345
2345
|
* @description fetches historical funding rate prices
|
|
2346
|
-
* @see https://docs.
|
|
2346
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/historical-funding-rates
|
|
2347
2347
|
* @param {string} symbol unified symbol of the market to fetch the funding rate history for
|
|
2348
2348
|
* @param {int} [since] timestamp in ms of the earliest funding rate to fetch
|
|
2349
2349
|
* @param {int} [limit] the maximum amount of [funding rate structures]{@link https://docs.ccxt.com/#/?id=funding-rate-history-structure} to fetch
|
|
@@ -2394,7 +2394,7 @@ export default class krakenfutures extends Exchange {
|
|
|
2394
2394
|
/**
|
|
2395
2395
|
* @method
|
|
2396
2396
|
* @name krakenfutures#fetchPositions
|
|
2397
|
-
* @see https://docs.
|
|
2397
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-open-positions
|
|
2398
2398
|
* @description Fetches current contract trading positions
|
|
2399
2399
|
* @param {string[]} symbols List of unified symbols
|
|
2400
2400
|
* @param {object} [params] Not used by krakenfutures
|
|
@@ -2491,7 +2491,7 @@ export default class krakenfutures extends Exchange {
|
|
|
2491
2491
|
* @method
|
|
2492
2492
|
* @name krakenfutures#fetchLeverageTiers
|
|
2493
2493
|
* @description retrieve information on the maximum leverage, and maintenance margin for trades of varying trade sizes
|
|
2494
|
-
* @see https://docs.
|
|
2494
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-instruments
|
|
2495
2495
|
* @param {string[]|undefined} symbols list of unified market symbols
|
|
2496
2496
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
2497
2497
|
* @returns {object} a dictionary of [leverage tiers structures]{@link https://docs.ccxt.com/#/?id=leverage-tiers-structure}, indexed by market symbols
|
|
@@ -2681,8 +2681,8 @@ export default class krakenfutures extends Exchange {
|
|
|
2681
2681
|
/**
|
|
2682
2682
|
* @method
|
|
2683
2683
|
* @name krakenfutures#transfer
|
|
2684
|
-
* @see https://docs.
|
|
2685
|
-
* @see https://docs.
|
|
2684
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/transfer
|
|
2685
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/sub-account-transfer
|
|
2686
2686
|
* @description transfers currencies between sub-accounts
|
|
2687
2687
|
* @param {string} code Unified currency code
|
|
2688
2688
|
* @param {float} amount Size of the transfer
|
|
@@ -2731,7 +2731,7 @@ export default class krakenfutures extends Exchange {
|
|
|
2731
2731
|
* @method
|
|
2732
2732
|
* @name krakenfutures#setLeverage
|
|
2733
2733
|
* @description set the level of leverage for a market
|
|
2734
|
-
* @see https://docs.
|
|
2734
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/set-leverage-setting
|
|
2735
2735
|
* @param {float} leverage the rate of leverage
|
|
2736
2736
|
* @param {string} symbol unified market symbol
|
|
2737
2737
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
@@ -2755,7 +2755,7 @@ export default class krakenfutures extends Exchange {
|
|
|
2755
2755
|
* @method
|
|
2756
2756
|
* @name krakenfutures#fetchLeverages
|
|
2757
2757
|
* @description fetch the set leverage for all contract and margin markets
|
|
2758
|
-
* @see https://docs.
|
|
2758
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-leverage-setting
|
|
2759
2759
|
* @param {string[]} [symbols] a list of unified market symbols
|
|
2760
2760
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
2761
2761
|
* @returns {object} a list of [leverage structures]{@link https://docs.ccxt.com/#/?id=leverage-structure}
|
|
@@ -2782,7 +2782,7 @@ export default class krakenfutures extends Exchange {
|
|
|
2782
2782
|
* @method
|
|
2783
2783
|
* @name krakenfutures#fetchLeverage
|
|
2784
2784
|
* @description fetch the set leverage for a market
|
|
2785
|
-
* @see https://docs.
|
|
2785
|
+
* @see https://docs.kraken.com/api/docs/futures-api/trading/get-leverage-setting
|
|
2786
2786
|
* @param {string} symbol unified market symbol
|
|
2787
2787
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
2788
2788
|
* @returns {object} a [leverage structure]{@link https://docs.ccxt.com/#/?id=leverage-structure}
|
package/js/src/mexc.js
CHANGED
|
@@ -669,6 +669,7 @@ export default class mexc extends Exchange {
|
|
|
669
669
|
'BNB Smart Chain(BEP20-RACAV1)': 'BSC',
|
|
670
670
|
'BNB Smart Chain(BEP20-RACAV2)': 'BSC',
|
|
671
671
|
'BNB Smart Chain(BEP20)': 'BSC',
|
|
672
|
+
'Ethereum(ERC20)': 'ERC20',
|
|
672
673
|
// TODO: uncomment below after deciding unified name
|
|
673
674
|
// 'PEPE COIN BSC':
|
|
674
675
|
// 'SMART BLOCKCHAIN':
|
|
@@ -5202,7 +5203,7 @@ export default class mexc extends Exchange {
|
|
|
5202
5203
|
// positionShowStatus: 'CLOSED'
|
|
5203
5204
|
// }
|
|
5204
5205
|
//
|
|
5205
|
-
market = this.safeMarket(this.safeString(position, 'symbol'), market);
|
|
5206
|
+
market = this.safeMarket(this.safeString(position, 'symbol'), market, undefined, 'swap');
|
|
5206
5207
|
const symbol = market['symbol'];
|
|
5207
5208
|
const contracts = this.safeString(position, 'holdVol');
|
|
5208
5209
|
const entryPrice = this.safeNumber(position, 'openAvgPrice');
|
package/js/src/okx.js
CHANGED
|
@@ -1220,7 +1220,7 @@ export default class okx extends Exchange {
|
|
|
1220
1220
|
'FUTURES': 'FUTURES',
|
|
1221
1221
|
'OPTION': 'OPTION',
|
|
1222
1222
|
},
|
|
1223
|
-
'brokerId': '
|
|
1223
|
+
'brokerId': '6b9ad766b55dBCDE',
|
|
1224
1224
|
},
|
|
1225
1225
|
'features': {
|
|
1226
1226
|
'default': {
|
|
@@ -6316,7 +6316,7 @@ export default class okx extends Exchange {
|
|
|
6316
6316
|
this.checkRequiredCredentials();
|
|
6317
6317
|
// inject id in implicit api call
|
|
6318
6318
|
if (method === 'POST' && (path === 'trade/batch-orders' || path === 'trade/order-algo' || path === 'trade/order')) {
|
|
6319
|
-
const brokerId = this.safeString(this.options, 'brokerId', '
|
|
6319
|
+
const brokerId = this.safeString(this.options, 'brokerId', '6b9ad766b55dBCDE');
|
|
6320
6320
|
if (Array.isArray(params)) {
|
|
6321
6321
|
for (let i = 0; i < params.length; i++) {
|
|
6322
6322
|
const entry = params[i];
|
package/js/src/poloniex.js
CHANGED
|
@@ -2648,7 +2648,7 @@ export default class poloniex extends Exchange {
|
|
|
2648
2648
|
// "scale" : "-1",
|
|
2649
2649
|
// "asks" : [ "23139.82", "0.317981", "23140", "0.191091", "23170.06", "0.01", "23200", "0.107758", "23230.55", "0.01", "23247.2", "0.154", "23254", "0.005121", "23263", "0.038", "23285.4", "0.308", "23300", "0.108896" ],
|
|
2650
2650
|
// "bids" : [ "23139.74", "0.432092", "23139.73", "0.198592", "23123.21", "0.000886", "23123.2", "0.308", "23121.4", "0.154", "23105", "0.000789", "23100", "0.078175", "23069.1", "0.026276", "23068.83", "0.001329", "23051", "0.000048" ],
|
|
2651
|
-
// "ts" :
|
|
2651
|
+
// "ts" : 1659695219512
|
|
2652
2652
|
// }
|
|
2653
2653
|
//
|
|
2654
2654
|
const timestamp = this.safeInteger(response, 'time');
|
package/js/src/pro/bitget.d.ts
CHANGED
|
@@ -8,15 +8,17 @@ import Client from '../base/ws/Client.js';
|
|
|
8
8
|
*/
|
|
9
9
|
export default class bitget extends bitgetRest {
|
|
10
10
|
describe(): any;
|
|
11
|
-
getInstType(market: any, params?: {}): any[];
|
|
11
|
+
getInstType(market: any, uta?: boolean, params?: {}): any[];
|
|
12
12
|
/**
|
|
13
13
|
* @method
|
|
14
14
|
* @name bitget#watchTicker
|
|
15
15
|
* @description watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
16
16
|
* @see https://www.bitget.com/api-doc/spot/websocket/public/Tickers-Channel
|
|
17
17
|
* @see https://www.bitget.com/api-doc/contract/websocket/public/Tickers-Channel
|
|
18
|
+
* @see https://www.bitget.com/api-doc/uta/websocket/public/Tickers-Channel
|
|
18
19
|
* @param {string} symbol unified symbol of the market to watch the ticker for
|
|
19
20
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
21
|
+
* @param {boolean} [params.uta] set to true for the unified trading account (uta), defaults to false
|
|
20
22
|
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
21
23
|
*/
|
|
22
24
|
watchTicker(symbol: string, params?: {}): Promise<Ticker>;
|
|
@@ -37,8 +39,10 @@ export default class bitget extends bitgetRest {
|
|
|
37
39
|
* @description watches a price ticker, a statistical calculation with the information calculated over the past 24 hours for all markets of a specific list
|
|
38
40
|
* @see https://www.bitget.com/api-doc/spot/websocket/public/Tickers-Channel
|
|
39
41
|
* @see https://www.bitget.com/api-doc/contract/websocket/public/Tickers-Channel
|
|
42
|
+
* @see https://www.bitget.com/api-doc/uta/websocket/public/Tickers-Channel
|
|
40
43
|
* @param {string[]} symbols unified symbol of the market to watch the tickers for
|
|
41
44
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
45
|
+
* @param {boolean} [params.uta] set to true for the unified trading account (uta), defaults to false
|
|
42
46
|
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
43
47
|
*/
|
|
44
48
|
watchTickers(symbols?: Strings, params?: {}): Promise<Tickers>;
|
|
@@ -47,11 +51,13 @@ export default class bitget extends bitgetRest {
|
|
|
47
51
|
/**
|
|
48
52
|
* @method
|
|
49
53
|
* @name bitget#watchBidsAsks
|
|
54
|
+
* @description watches best bid & ask for symbols
|
|
50
55
|
* @see https://www.bitget.com/api-doc/spot/websocket/public/Tickers-Channel
|
|
51
56
|
* @see https://www.bitget.com/api-doc/contract/websocket/public/Tickers-Channel
|
|
52
|
-
* @
|
|
57
|
+
* @see https://www.bitget.com/api-doc/uta/websocket/public/Tickers-Channel
|
|
53
58
|
* @param {string[]} symbols unified symbol of the market to fetch the ticker for
|
|
54
59
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
60
|
+
* @param {boolean} [params.uta] set to true for the unified trading account (uta), defaults to false
|
|
55
61
|
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
|
|
56
62
|
*/
|
|
57
63
|
watchBidsAsks(symbols?: Strings, params?: {}): Promise<Tickers>;
|
|
@@ -63,11 +69,13 @@ export default class bitget extends bitgetRest {
|
|
|
63
69
|
* @description watches historical candlestick data containing the open, high, low, close price, and the volume of a market
|
|
64
70
|
* @see https://www.bitget.com/api-doc/spot/websocket/public/Candlesticks-Channel
|
|
65
71
|
* @see https://www.bitget.com/api-doc/contract/websocket/public/Candlesticks-Channel
|
|
72
|
+
* @see https://www.bitget.com/api-doc/uta/websocket/public/Candlesticks-Channel
|
|
66
73
|
* @param {string} symbol unified symbol of the market to fetch OHLCV data for
|
|
67
74
|
* @param {string} timeframe the length of time each candle represents
|
|
68
75
|
* @param {int} [since] timestamp in ms of the earliest candle to fetch
|
|
69
76
|
* @param {int} [limit] the maximum amount of candles to fetch
|
|
70
77
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
78
|
+
* @param {boolean} [params.uta] set to true for the unified trading account (uta), defaults to false
|
|
71
79
|
* @returns {int[][]} A list of candles ordered as timestamp, open, high, low, close, volume
|
|
72
80
|
*/
|
|
73
81
|
watchOHLCV(symbol: string, timeframe?: string, since?: Int, limit?: Int, params?: {}): Promise<OHLCV[]>;
|
|
@@ -77,9 +85,11 @@ export default class bitget extends bitgetRest {
|
|
|
77
85
|
* @description unsubscribe from the ohlcv channel
|
|
78
86
|
* @see https://www.bitget.com/api-doc/spot/websocket/public/Candlesticks-Channel
|
|
79
87
|
* @see https://www.bitget.com/api-doc/contract/websocket/public/Candlesticks-Channel
|
|
88
|
+
* @see https://www.bitget.com/api-doc/uta/websocket/public/Candlesticks-Channel
|
|
80
89
|
* @param {string} symbol unified symbol of the market to unwatch the ohlcv for
|
|
81
90
|
* @param {string} [timeframe] the period for the ratio, default is 1 minute
|
|
82
91
|
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
92
|
+
* @param {boolean} [params.uta] set to true for the unified trading account (uta), defaults to false
|
|
83
93
|
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
|
|
84
94
|
*/
|
|
85
95
|
unWatchOHLCV(symbol: string, timeframe?: string, params?: {}): Promise<any>;
|