ccxt 4.5.44 → 4.5.45
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 +9 -12
- package/dist/ccxt.browser.min.js +3 -3
- package/dist/cjs/ccxt.js +1 -12
- package/dist/cjs/src/abstract/kucoinfutures.js +1 -1
- package/dist/cjs/src/base/Exchange.js +36 -3
- package/dist/cjs/src/base/functions/encode.js +2 -2
- package/dist/cjs/src/base/functions/generic.js +8 -2
- package/dist/cjs/src/bitrue.js +1 -1
- package/dist/cjs/src/bitteam.js +1 -1
- package/dist/cjs/src/btcbox.js +1 -1
- package/dist/cjs/src/cex.js +1 -0
- package/dist/cjs/src/gate.js +227 -168
- package/dist/cjs/src/grvt.js +3 -2
- package/dist/cjs/src/hyperliquid.js +16 -5
- package/dist/cjs/src/kraken.js +2 -2
- package/dist/cjs/src/krakenfutures.js +1 -5
- package/dist/cjs/src/kucoin.js +4729 -970
- package/dist/cjs/src/kucoinfutures.js +14 -3434
- package/dist/cjs/src/lbank.js +1 -1
- package/dist/cjs/src/poloniex.js +1 -1
- package/dist/cjs/src/pro/gate.js +37 -1
- package/dist/cjs/src/pro/kucoin.js +819 -178
- package/dist/cjs/src/pro/kucoinfutures.js +95 -1261
- package/dist/cjs/src/pro/mexc.js +10 -5
- package/dist/cjs/src/pro/okx.js +84 -39
- package/js/ccxt.d.ts +2 -14
- package/js/ccxt.js +2 -10
- package/js/src/abstract/kucoin.d.ts +46 -3
- package/js/src/abstract/kucoinfutures.d.ts +27 -12
- package/js/src/base/Exchange.d.ts +12 -1
- package/js/src/base/Exchange.js +36 -3
- package/js/src/base/functions/encode.js +2 -2
- package/js/src/base/functions/generic.js +9 -3
- package/js/src/bitrue.js +1 -1
- package/js/src/bitteam.js +1 -1
- package/js/src/btcbox.js +1 -1
- package/js/src/cex.js +2 -1
- package/js/src/gate.d.ts +125 -119
- package/js/src/gate.js +227 -168
- package/js/src/grvt.js +3 -2
- package/js/src/hyperliquid.d.ts +3 -1
- package/js/src/hyperliquid.js +16 -5
- package/js/src/kraken.js +2 -2
- package/js/src/krakenfutures.js +1 -5
- package/js/src/kucoin.d.ts +696 -100
- package/js/src/kucoin.js +4730 -971
- package/js/src/kucoinfutures.d.ts +4 -522
- package/js/src/kucoinfutures.js +14 -3434
- package/js/src/lbank.js +1 -1
- package/js/src/poloniex.js +1 -1
- package/js/src/pro/gate.d.ts +30 -1
- package/js/src/pro/gate.js +37 -1
- package/js/src/pro/kucoin.d.ts +70 -30
- package/js/src/pro/kucoin.js +821 -180
- package/js/src/pro/kucoinfutures.d.ts +17 -195
- package/js/src/pro/kucoinfutures.js +96 -1262
- package/js/src/pro/mexc.js +10 -5
- package/js/src/pro/okx.d.ts +1 -0
- package/js/src/pro/okx.js +84 -39
- package/package.json +1 -1
- package/dist/cjs/src/abstract/alp.js +0 -11
- package/dist/cjs/src/abstract/defx.js +0 -11
- package/dist/cjs/src/abstract/timex.js +0 -11
- package/dist/cjs/src/alp.js +0 -1059
- package/dist/cjs/src/defx.js +0 -2142
- package/dist/cjs/src/pro/defx.js +0 -866
- package/dist/cjs/src/timex.js +0 -1793
- package/js/src/abstract/alp.d.ts +0 -21
- package/js/src/abstract/alp.js +0 -5
- package/js/src/abstract/defx.d.ts +0 -72
- package/js/src/abstract/defx.js +0 -5
- package/js/src/abstract/timex.d.ts +0 -65
- package/js/src/abstract/timex.js +0 -5
- package/js/src/alp.d.ts +0 -209
- package/js/src/alp.js +0 -1052
- package/js/src/defx.d.ts +0 -348
- package/js/src/defx.js +0 -2135
- package/js/src/pro/defx.d.ts +0 -236
- package/js/src/pro/defx.js +0 -859
- package/js/src/timex.d.ts +0 -247
- package/js/src/timex.js +0 -1786
package/js/src/timex.d.ts
DELETED
|
@@ -1,247 +0,0 @@
|
|
|
1
|
-
import Exchange from './abstract/timex.js';
|
|
2
|
-
import type { Balances, Currencies, Currency, Dict, Int, Market, Num, OHLCV, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, TradingFeeInterface, Transaction, int, DepositAddress } from './base/types.js';
|
|
3
|
-
/**
|
|
4
|
-
* @class timex
|
|
5
|
-
* @augments Exchange
|
|
6
|
-
*/
|
|
7
|
-
export default class timex extends Exchange {
|
|
8
|
-
describe(): any;
|
|
9
|
-
/**
|
|
10
|
-
* @method
|
|
11
|
-
* @name timex#fetchTime
|
|
12
|
-
* @description fetches the current integer timestamp in milliseconds from the exchange server
|
|
13
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
14
|
-
* @returns {int} the current integer timestamp in milliseconds from the exchange server
|
|
15
|
-
*/
|
|
16
|
-
fetchTime(params?: {}): Promise<Int>;
|
|
17
|
-
/**
|
|
18
|
-
* @method
|
|
19
|
-
* @name timex#fetchMarkets
|
|
20
|
-
* @description retrieves data on all markets for timex
|
|
21
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Public/listMarkets
|
|
22
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
23
|
-
* @returns {object[]} an array of objects representing market data
|
|
24
|
-
*/
|
|
25
|
-
fetchMarkets(params?: {}): Promise<Market[]>;
|
|
26
|
-
/**
|
|
27
|
-
* @method
|
|
28
|
-
* @name timex#fetchCurrencies
|
|
29
|
-
* @description fetches all available currencies on an exchange
|
|
30
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Public/listCurrencies
|
|
31
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
32
|
-
* @returns {object} an associative dictionary of currencies
|
|
33
|
-
*/
|
|
34
|
-
fetchCurrencies(params?: {}): Promise<Currencies>;
|
|
35
|
-
/**
|
|
36
|
-
* @method
|
|
37
|
-
* @name timex#fetchDeposits
|
|
38
|
-
* @description fetch all deposits made to an account
|
|
39
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Manager/getDeposits
|
|
40
|
-
* @param {string} code unified currency code
|
|
41
|
-
* @param {int} [since] the earliest time in ms to fetch deposits for
|
|
42
|
-
* @param {int} [limit] the maximum number of deposits structures to retrieve
|
|
43
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
44
|
-
* @returns {object[]} a list of [transaction structures]{@link https://docs.ccxt.com/?id=transaction-structure}
|
|
45
|
-
*/
|
|
46
|
-
fetchDeposits(code?: Str, since?: Int, limit?: Int, params?: {}): Promise<Transaction[]>;
|
|
47
|
-
/**
|
|
48
|
-
* @method
|
|
49
|
-
* @name timex#fetchWithdrawals
|
|
50
|
-
* @description fetch all withdrawals made to an account
|
|
51
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Manager/getWithdraws
|
|
52
|
-
* @param {string} code unified currency code
|
|
53
|
-
* @param {int} [since] the earliest time in ms to fetch withdrawals for
|
|
54
|
-
* @param {int} [limit] the maximum number of transaction structures to retrieve
|
|
55
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
56
|
-
* @returns {object[]} a list of [transaction structures]{@link https://docs.ccxt.com/?id=transaction-structure}
|
|
57
|
-
*/
|
|
58
|
-
fetchWithdrawals(code?: Str, since?: Int, limit?: Int, params?: {}): Promise<Transaction[]>;
|
|
59
|
-
getCurrencyByAddress(address: any): any;
|
|
60
|
-
parseTransaction(transaction: Dict, currency?: Currency): Transaction;
|
|
61
|
-
/**
|
|
62
|
-
* @method
|
|
63
|
-
* @name timex#fetchTickers
|
|
64
|
-
* @description fetches price tickers for multiple markets, statistical information calculated over the past 24 hours for each market
|
|
65
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Public/listTickers
|
|
66
|
-
* @param {string[]|undefined} symbols unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
|
|
67
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
68
|
-
* @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/?id=ticker-structure}
|
|
69
|
-
*/
|
|
70
|
-
fetchTickers(symbols?: Strings, params?: {}): Promise<Tickers>;
|
|
71
|
-
/**
|
|
72
|
-
* @method
|
|
73
|
-
* @name timex#fetchTicker
|
|
74
|
-
* @description fetches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
|
|
75
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Public/listTickers
|
|
76
|
-
* @param {string} symbol unified symbol of the market to fetch the ticker for
|
|
77
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
78
|
-
* @returns {object} a [ticker structure]{@link https://docs.ccxt.com/?id=ticker-structure}
|
|
79
|
-
*/
|
|
80
|
-
fetchTicker(symbol: string, params?: {}): Promise<Ticker>;
|
|
81
|
-
/**
|
|
82
|
-
* @method
|
|
83
|
-
* @name timex#fetchOrderBook
|
|
84
|
-
* @description fetches information on open orders with bid (buy) and ask (sell) prices, volumes and other data
|
|
85
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Public/orderbookV2
|
|
86
|
-
* @param {string} symbol unified symbol of the market to fetch the order book for
|
|
87
|
-
* @param {int} [limit] the maximum amount of order book entries to return
|
|
88
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
89
|
-
* @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/?id=order-book-structure} indexed by market symbols
|
|
90
|
-
*/
|
|
91
|
-
fetchOrderBook(symbol: string, limit?: Int, params?: {}): Promise<OrderBook>;
|
|
92
|
-
/**
|
|
93
|
-
* @method
|
|
94
|
-
* @name timex#fetchTrades
|
|
95
|
-
* @description get the list of most recent trades for a particular symbol
|
|
96
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Public/listTrades
|
|
97
|
-
* @param {string} symbol unified symbol of the market to fetch trades for
|
|
98
|
-
* @param {int} [since] timestamp in ms of the earliest trade to fetch
|
|
99
|
-
* @param {int} [limit] the maximum amount of trades to fetch
|
|
100
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
101
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/?id=public-trades}
|
|
102
|
-
*/
|
|
103
|
-
fetchTrades(symbol: string, since?: Int, limit?: Int, params?: {}): Promise<Trade[]>;
|
|
104
|
-
/**
|
|
105
|
-
* @method
|
|
106
|
-
* @name timex#fetchOHLCV
|
|
107
|
-
* @description fetches historical candlestick data containing the open, high, low, and close price, and the volume of a market
|
|
108
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Public/listCandles
|
|
109
|
-
* @param {string} symbol unified symbol of the market to fetch OHLCV data for
|
|
110
|
-
* @param {string} timeframe the length of time each candle represents
|
|
111
|
-
* @param {int} [since] timestamp in ms of the earliest candle to fetch
|
|
112
|
-
* @param {int} [limit] the maximum amount of candles to fetch
|
|
113
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
114
|
-
* @param {int} [params.until] timestamp in ms of the latest candle to fetch
|
|
115
|
-
* @returns {int[][]} A list of candles ordered as timestamp, open, high, low, close, volume
|
|
116
|
-
*/
|
|
117
|
-
fetchOHLCV(symbol: string, timeframe?: string, since?: Int, limit?: Int, params?: {}): Promise<OHLCV[]>;
|
|
118
|
-
parseBalance(response: any): Balances;
|
|
119
|
-
/**
|
|
120
|
-
* @method
|
|
121
|
-
* @name timex#fetchBalance
|
|
122
|
-
* @description query for balance and get the amount of funds available for trading or funds locked in orders
|
|
123
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Trading/getBalances
|
|
124
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
125
|
-
* @returns {object} a [balance structure]{@link https://docs.ccxt.com/?id=balance-structure}
|
|
126
|
-
*/
|
|
127
|
-
fetchBalance(params?: {}): Promise<Balances>;
|
|
128
|
-
/**
|
|
129
|
-
* @method
|
|
130
|
-
* @name timex#createOrder
|
|
131
|
-
* @description create a trade order
|
|
132
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Trading/createOrder
|
|
133
|
-
* @param {string} symbol unified symbol of the market to create an order in
|
|
134
|
-
* @param {string} type 'market' or 'limit'
|
|
135
|
-
* @param {string} side 'buy' or 'sell'
|
|
136
|
-
* @param {float} amount how much of currency you want to trade in units of base currency
|
|
137
|
-
* @param {float} [price] the price at which the order is to be fulfilled, in units of the quote currency, ignored in market orders
|
|
138
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
139
|
-
* @returns {object} an [order structure]{@link https://docs.ccxt.com/?id=order-structure}
|
|
140
|
-
*/
|
|
141
|
-
createOrder(symbol: string, type: OrderType, side: OrderSide, amount: number, price?: Num, params?: {}): Promise<Order>;
|
|
142
|
-
editOrder(id: string, symbol: string, type: OrderType, side: OrderSide, amount?: Num, price?: Num, params?: {}): Promise<Order>;
|
|
143
|
-
/**
|
|
144
|
-
* @method
|
|
145
|
-
* @name timex#cancelOrder
|
|
146
|
-
* @description cancels an open order
|
|
147
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Trading/deleteOrders
|
|
148
|
-
* @param {string} id order id
|
|
149
|
-
* @param {string} symbol not used by timex cancelOrder ()
|
|
150
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
151
|
-
* @returns {object} An [order structure]{@link https://docs.ccxt.com/?id=order-structure}
|
|
152
|
-
*/
|
|
153
|
-
cancelOrder(id: string, symbol?: Str, params?: {}): Promise<Order>;
|
|
154
|
-
/**
|
|
155
|
-
* @method
|
|
156
|
-
* @name timex#cancelOrders
|
|
157
|
-
* @description cancel multiple orders
|
|
158
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Trading/deleteOrders
|
|
159
|
-
* @param {string[]} ids order ids
|
|
160
|
-
* @param {string} symbol unified market symbol, default is undefined
|
|
161
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
162
|
-
* @returns {object} an list of [order structures]{@link https://docs.ccxt.com/?id=order-structure}
|
|
163
|
-
*/
|
|
164
|
-
cancelOrders(ids: string[], symbol?: Str, params?: {}): Promise<Order[]>;
|
|
165
|
-
/**
|
|
166
|
-
* @method
|
|
167
|
-
* @name timex#fetchOrder
|
|
168
|
-
* @description fetches information on an order made by the user
|
|
169
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/History/getOrderDetails
|
|
170
|
-
* @param {string} id order id
|
|
171
|
-
* @param {string} symbol not used by timex fetchOrder
|
|
172
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
173
|
-
* @returns {object} An [order structure]{@link https://docs.ccxt.com/?id=order-structure}
|
|
174
|
-
*/
|
|
175
|
-
fetchOrder(id: string, symbol?: Str, params?: {}): Promise<Order>;
|
|
176
|
-
/**
|
|
177
|
-
* @method
|
|
178
|
-
* @name timex#fetchOpenOrders
|
|
179
|
-
* @description fetch all unfilled currently open orders
|
|
180
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Trading/getOpenOrders
|
|
181
|
-
* @param {string} symbol unified market symbol
|
|
182
|
-
* @param {int} [since] the earliest time in ms to fetch open orders for
|
|
183
|
-
* @param {int} [limit] the maximum number of open orders structures to retrieve
|
|
184
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
185
|
-
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/?id=order-structure}
|
|
186
|
-
*/
|
|
187
|
-
fetchOpenOrders(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Order[]>;
|
|
188
|
-
/**
|
|
189
|
-
* @method
|
|
190
|
-
* @name timex#fetchClosedOrders
|
|
191
|
-
* @description fetches information on multiple closed orders made by the user
|
|
192
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/History/getOrders
|
|
193
|
-
* @param {string} symbol unified market symbol of the market orders were made in
|
|
194
|
-
* @param {int} [since] the earliest time in ms to fetch orders for
|
|
195
|
-
* @param {int} [limit] the maximum number of order structures to retrieve
|
|
196
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
197
|
-
* @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/?id=order-structure}
|
|
198
|
-
*/
|
|
199
|
-
fetchClosedOrders(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Order[]>;
|
|
200
|
-
/**
|
|
201
|
-
* @method
|
|
202
|
-
* @name timex#fetchMyTrades
|
|
203
|
-
* @description fetch all trades made by the user
|
|
204
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/History/getTrades_1
|
|
205
|
-
* @param {string} symbol unified market symbol
|
|
206
|
-
* @param {int} [since] the earliest time in ms to fetch trades for
|
|
207
|
-
* @param {int} [limit] the maximum number of trades structures to retrieve
|
|
208
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
209
|
-
* @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/?id=trade-structure}
|
|
210
|
-
*/
|
|
211
|
-
fetchMyTrades(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Trade[]>;
|
|
212
|
-
parseTradingFee(fee: Dict, market?: Market): TradingFeeInterface;
|
|
213
|
-
/**
|
|
214
|
-
* @method
|
|
215
|
-
* @name timex#fetchTradingFee
|
|
216
|
-
* @description fetch the trading fees for a market
|
|
217
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Trading/getFees
|
|
218
|
-
* @param {string} symbol unified market symbol
|
|
219
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
220
|
-
* @returns {object} a [fee structure]{@link https://docs.ccxt.com/?id=fee-structure}
|
|
221
|
-
*/
|
|
222
|
-
fetchTradingFee(symbol: string, params?: {}): Promise<TradingFeeInterface>;
|
|
223
|
-
parseMarket(market: Dict): Market;
|
|
224
|
-
parseCurrency(currency: Dict): Currency;
|
|
225
|
-
parseTicker(ticker: Dict, market?: Market): Ticker;
|
|
226
|
-
parseTrade(trade: Dict, market?: Market): Trade;
|
|
227
|
-
parseOHLCV(ohlcv: any, market?: Market): OHLCV;
|
|
228
|
-
parseOrder(order: Dict, market?: Market): Order;
|
|
229
|
-
/**
|
|
230
|
-
* @method
|
|
231
|
-
* @name timex#fetchDepositAddress
|
|
232
|
-
* @description fetch the deposit address for a currency associated with this account, does not accept params["network"]
|
|
233
|
-
* @see https://plasma-relay-backend.timex.io/swagger-ui/index.html?urls.primaryName=Relay#/Currency/selectCurrencyBySymbol
|
|
234
|
-
* @param {string} code unified currency code
|
|
235
|
-
* @param {object} [params] extra parameters specific to the exchange API endpoint
|
|
236
|
-
* @returns {object} an [address structure]{@link https://docs.ccxt.com/?id=address-structure}
|
|
237
|
-
*/
|
|
238
|
-
fetchDepositAddress(code: string, params?: {}): Promise<DepositAddress>;
|
|
239
|
-
parseDepositAddress(depositAddress: any, currency?: Currency): DepositAddress;
|
|
240
|
-
sign(path: any, api?: string, method?: string, params?: {}, headers?: any, body?: any): {
|
|
241
|
-
url: string;
|
|
242
|
-
method: string;
|
|
243
|
-
body: any;
|
|
244
|
-
headers: any;
|
|
245
|
-
};
|
|
246
|
-
handleErrors(statusCode: int, statusText: string, url: string, method: string, responseHeaders: Dict, responseBody: any, response: any, requestHeaders: any, requestBody: any): any;
|
|
247
|
-
}
|