ccxt 4.4.85 → 4.4.86

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.
Files changed (60) hide show
  1. package/README.md +6 -7
  2. package/dist/ccxt.browser.min.js +2 -2
  3. package/dist/cjs/ccxt.js +6 -9
  4. package/dist/cjs/src/abstract/bittrade.js +9 -0
  5. package/dist/cjs/src/ascendex.js +189 -155
  6. package/dist/cjs/src/bequant.js +1 -1
  7. package/dist/cjs/src/bitget.js +5 -4
  8. package/dist/cjs/src/bitmart.js +1 -1
  9. package/dist/cjs/src/bittrade.js +2049 -0
  10. package/dist/cjs/src/coinbase.js +2 -6
  11. package/dist/cjs/src/deribit.js +4 -5
  12. package/dist/cjs/src/hollaex.js +107 -49
  13. package/dist/cjs/src/htx.js +20 -44
  14. package/dist/cjs/src/hyperliquid.js +4 -4
  15. package/dist/cjs/src/mexc.js +2 -2
  16. package/dist/cjs/src/ndax.js +25 -24
  17. package/dist/cjs/src/okcoin.js +12 -31
  18. package/dist/cjs/src/okx.js +9 -0
  19. package/dist/cjs/src/onetrading.js +9 -6
  20. package/dist/cjs/src/oxfun.js +42 -114
  21. package/dist/cjs/src/paradex.js +5 -1
  22. package/dist/cjs/src/pro/binance.js +1 -0
  23. package/dist/cjs/src/pro/bittrade.js +605 -0
  24. package/dist/cjs/src/pro/luno.js +6 -5
  25. package/dist/cjs/src/pro/mexc.js +3 -0
  26. package/js/ccxt.d.ts +8 -11
  27. package/js/ccxt.js +6 -8
  28. package/js/src/abstract/myokx.d.ts +2 -0
  29. package/js/src/abstract/okx.d.ts +2 -0
  30. package/js/src/ascendex.d.ts +2 -0
  31. package/js/src/ascendex.js +189 -155
  32. package/js/src/bequant.js +1 -1
  33. package/js/src/bitget.js +5 -4
  34. package/js/src/bitmart.js +1 -1
  35. package/js/src/{huobijp.d.ts → bittrade.d.ts} +29 -29
  36. package/js/src/{huobijp.js → bittrade.js} +35 -35
  37. package/js/src/coinbase.js +2 -6
  38. package/js/src/deribit.js +4 -5
  39. package/js/src/hollaex.js +107 -49
  40. package/js/src/htx.js +20 -44
  41. package/js/src/hyperliquid.js +4 -4
  42. package/js/src/mexc.js +2 -2
  43. package/js/src/ndax.js +25 -24
  44. package/js/src/okcoin.js +12 -31
  45. package/js/src/okx.js +9 -0
  46. package/js/src/onetrading.js +9 -6
  47. package/js/src/oxfun.js +42 -114
  48. package/js/src/paradex.js +5 -1
  49. package/js/src/pro/binance.js +1 -0
  50. package/js/src/pro/{huobijp.d.ts → bittrade.d.ts} +6 -6
  51. package/js/src/pro/{huobijp.js → bittrade.js} +7 -7
  52. package/js/src/pro/luno.js +6 -5
  53. package/js/src/pro/mexc.js +3 -0
  54. package/package.json +1 -1
  55. package/js/src/abstract/kuna.d.ts +0 -185
  56. package/js/src/abstract/kuna.js +0 -11
  57. package/js/src/kuna.d.ts +0 -335
  58. package/js/src/kuna.js +0 -2006
  59. /package/js/src/abstract/{huobijp.d.ts → bittrade.d.ts} +0 -0
  60. /package/js/src/abstract/{huobijp.js → bittrade.js} +0 -0
package/js/src/kuna.d.ts DELETED
@@ -1,335 +0,0 @@
1
- import Exchange from './abstract/kuna.js';
2
- import type { Balances, Currencies, Currency, Dict, Int, Market, Num, Order, OrderBook, OrderSide, OrderType, Str, Strings, Ticker, Tickers, Trade, Transaction, int, DepositAddress } from './base/types.js';
3
- /**
4
- * @class kuna
5
- * @augments Exchange
6
- * @description Use the public-key as your apiKey
7
- */
8
- export default class kuna extends Exchange {
9
- describe(): any;
10
- /**
11
- * @method
12
- * @name kuna#fetchTime
13
- * @description fetches the current integer timestamp in milliseconds from the exchange server
14
- * @see https://docs.kuna.io/docs/get-time-on-the-server
15
- * @param {object} [params] extra parameters specific to the exchange API endpoint
16
- * @returns {int} the current integer timestamp in milliseconds from the exchange server
17
- */
18
- fetchTime(params?: {}): Promise<Int>;
19
- /**
20
- * @method
21
- * @name kuna#fetchCurrencies
22
- * @description fetches all available currencies on an exchange
23
- * @see https://docs.kuna.io/docs/get-information-about-available-currencies
24
- * @param {object} [params] extra parameters specific to the exchange API endpoint
25
- * @returns {object} an associative dictionary of currencies
26
- */
27
- fetchCurrencies(params?: {}): Promise<Currencies>;
28
- parseCurrency(currency: Dict): Currency;
29
- /**
30
- * @method
31
- * @name kuna#fetchMarkets
32
- * @description retrieves data on all markets for kuna
33
- * @see https://docs.kuna.io/docs/get-all-traded-markets
34
- * @param {object} [params] extra parameters specific to the exchange API endpoint
35
- * @returns {object[]} an array of objects representing market data
36
- */
37
- fetchMarkets(params?: {}): Promise<Market[]>;
38
- /**
39
- * @method
40
- * @name kuna#fetchOrderBook
41
- * @description fetches information on open orders with bid (buy) and ask (sell) prices, volumes and other data
42
- * @see https://docs.kuna.io/docs/get-public-orders-book
43
- * @param {string} symbol unified symbol of the market to fetch the order book for
44
- * @param {int} [limit] 5, 10, 20, 50, 100, 500, or 1000 (default)
45
- * @param {object} [params] extra parameters specific to the exchange API endpoint
46
- * @returns {object} A dictionary of [order book structures]{@link https://docs.ccxt.com/#/?id=order-book-structure} indexed by market symbols
47
- */
48
- fetchOrderBook(symbol: string, limit?: Int, params?: {}): Promise<OrderBook>;
49
- parseTicker(ticker: Dict, market?: Market): Ticker;
50
- /**
51
- * @method
52
- * @name kuna#fetchTickers
53
- * @description fetches price tickers for multiple markets, statistical information calculated over the past 24 hours for each market. The average is not returned in the response, but the median can be accessed via response['info']['price']
54
- * @see https://docs.kuna.io/docs/get-market-info-by-tickers
55
- * @param {string[]} [symbols] unified symbols of the markets to fetch the ticker for, all market tickers are returned if not assigned
56
- * @param {object} [params] extra parameters specific to the exchange API endpoint
57
- * @returns {object} a dictionary of [ticker structures]{@link https://docs.ccxt.com/#/?id=ticker-structure}
58
- */
59
- fetchTickers(symbols?: Strings, params?: {}): Promise<Tickers>;
60
- /**
61
- * @method
62
- * @name kuna#fetchTicker
63
- * @description fetches a price ticker, a statistical calculation with the information calculated over the past 24 hours for a specific market
64
- * @see https://docs.kuna.io/docs/get-market-info-by-tickers
65
- * @param {string} symbol unified symbol of the market to fetch the ticker for
66
- * @param {object} [params] extra parameters specific to the exchange API endpoint
67
- * @returns {object} a [ticker structure]{@link https://docs.ccxt.com/#/?id=ticker-structure}
68
- */
69
- fetchTicker(symbol: string, params?: {}): Promise<Ticker>;
70
- /**
71
- * TODO: double check
72
- * @method
73
- * @name kuna#fetchL3OrderBook
74
- * @description fetches level 3 information on open orders with bid (buy) and ask (sell) prices, volumes and other data
75
- * @param {string} symbol unified market symbol
76
- * @param {int} [limit] max number of orders to return, default is undefined
77
- * @param {object} [params] extra parameters specific to the exchange API endpoint
78
- * @returns {object} an [order book structure]{@link https://docs.ccxt.com/#/?id=order-book-structure}
79
- */
80
- fetchL3OrderBook(symbol: string, limit?: Int, params?: {}): Promise<OrderBook>;
81
- /**
82
- * @method
83
- * @name kuna#fetchTrades
84
- * @description get the list of most recent trades for a particular symbol
85
- * @see https://docs.kuna.io/docs/get-public-trades-book
86
- * @param {string} symbol unified symbol of the market to fetch trades for
87
- * @param {int} [since] timestamp in ms of the earliest trade to fetch
88
- * @param {int} [limit] between 1 and 100, 25 by default
89
- * @param {object} [params] extra parameters specific to the exchange API endpoint
90
- * @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=public-trades}
91
- */
92
- fetchTrades(symbol: string, since?: Int, limit?: Int, params?: {}): Promise<Trade[]>;
93
- parseTrade(trade: Dict, market?: Market): Trade;
94
- parseBalance(response: any): Balances;
95
- /**
96
- * @method
97
- * @name kuna#fetchBalance
98
- * @description query for balance and get the amount of funds available for trading or funds locked in orders
99
- * @param {object} [params] extra parameters specific to the exchange API endpoint
100
- * @returns {object} a [balance structure]{@link https://docs.ccxt.com/#/?id=balance-structure}
101
- */
102
- fetchBalance(params?: {}): Promise<Balances>;
103
- /**
104
- * @method
105
- * @name kuna#createOrder
106
- * @description create a trade order
107
- * @see https://docs.kuna.io/docs/create-a-new-order-private
108
- * @param {string} symbol unified symbol of the market to create an order in
109
- * @param {string} type 'market' or 'limit'
110
- * @param {string} side 'buy' or 'sell'
111
- * @param {float} amount how much of currency you want to trade in units of base currency
112
- * @param {float} [price] the price at which the order is to be fulfilled, in units of the quote currency, ignored in market orders
113
- * @param {object} [params] extra parameters specific to the exchange API endpoint
114
- * @param {float} [params.triggerPrice] the price at which a trigger order is triggered at
115
- *
116
- * EXCHANGE SPECIFIC PARAMETERS
117
- * @param {string} [params.id] id must be a UUID format, if you do not specify id, it will be generated automatically.
118
- * @param {float} [params.quoteQuantity] the max quantity of the quote asset to use for selling/buying
119
- * @returns {object} an [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
120
- */
121
- createOrder(symbol: string, type: OrderType, side: OrderSide, amount: number, price?: Num, params?: {}): Promise<Order>;
122
- /**
123
- * @method
124
- * @name kuna#cancelOrder
125
- * @description cancels an open order
126
- * @param {string} id order id
127
- * @param {string} symbol unified market symbol
128
- * @param {object} [params] extra parameters specific to the exchange API endpoint
129
- * @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
130
- */
131
- cancelOrder(id: string, symbol?: Str, params?: {}): Promise<Order>;
132
- /**
133
- * @method
134
- * @name kuna#cancelOrders
135
- * @description cancels an open order
136
- * @param {string} ids order ids
137
- * @param {string} symbol not used by kuna cancelOrder
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
- cancelOrders(ids: string[], symbol?: Str, params?: {}): Promise<Order[]>;
142
- parseOrderStatus(status: Str): string;
143
- parseOrder(order: Dict, market?: Market): Order;
144
- /**
145
- * @method
146
- * @name kuna#fetchOrder
147
- * @description fetches information on an order made by the user
148
- * @see https://docs.kuna.io/docs/get-order-details-by-id
149
- * @param {string} id order id
150
- * @param {string} symbol not used by kuna fetchOrder
151
- * @param {object} [params] extra parameters specific to the exchange API endpoint
152
- *
153
- * EXCHANGE SPECIFIC PARAMETERS
154
- * @param {boolean} [params.withTrades] default == true, specify if the response should include trades associated with the order
155
- * @returns {object} An [order structure]{@link https://docs.ccxt.com/#/?id=order-structure}
156
- */
157
- fetchOrder(id: string, symbol?: Str, params?: {}): Promise<Order>;
158
- /**
159
- * @method
160
- * @name kuna#fetchOpenOrders
161
- * @description fetch all unfilled currently open orders
162
- * @see https://docs.kuna.io/docs/get-active-client-orders-private
163
- * @param {string} symbol unified market symbol
164
- * @param {int} [since] the earliest time in ms to fetch open orders for
165
- * @param {int} [limit] 1-100, the maximum number of open orders structures to retrieve
166
- * @param {object} [params] extra parameters specific to the exchange API endpoint
167
- * @param {int} [params.until] the latest timestamp (ms) to fetch orders for
168
- *
169
- * EXCHANGE SPECIFIC PARAMETERS
170
- * @param {string} [params.sort] asc (oldest-on-top) or desc (newest-on-top)
171
- * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
172
- */
173
- fetchOpenOrders(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Order[]>;
174
- /**
175
- * @method
176
- * @name kuna#fetchClosedOrders
177
- * @description fetches information on multiple closed orders made by the user
178
- * @see https://docs.kuna.io/docs/get-private-orders-history
179
- * @param {string} symbol unified market symbol of the market orders were made in
180
- * @param {int} [since] the earliest time in ms to fetch orders for
181
- * @param {int} [limit] the maximum number of order structures to retrieve
182
- * @param {object} [params] extra parameters specific to the exchange API endpoint
183
- * @param {int} [params.until] the latest time in ms to fetch orders for
184
- *
185
- * EXCHANGE SPECIFIC PARAMETERS
186
- * @param {string} [params.sort] asc (oldest-on-top) or desc (newest-on-top)
187
- * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
188
- */
189
- fetchClosedOrders(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Order[]>;
190
- /**
191
- * @method
192
- * @name kuna#fetchOrdersByStatus
193
- * @description fetch a list of orders
194
- * @see https://docs.kuna.io/docs/get-private-orders-history
195
- * @param {string} status canceled, closed, expired, open, pending, rejected, or waitStop
196
- * @param {string} symbol unified market symbol of the market orders were made in
197
- * @param {int} [since] the earliest time in ms to fetch orders for
198
- * @param {int} [limit] 1-100, the maximum number of open orders structures to retrieve
199
- * @param {object} [params] extra parameters specific to the exchange API endpoint
200
- * @param {int} [params.until] the latest timestamp (ms) to fetch orders for
201
- *
202
- * EXCHANGE SPECIFIC PARAMETERS
203
- * @param {string} [params.sort] asc (oldest-on-top) or desc (newest-on-top)
204
- * @returns {Order[]} a list of [order structures]{@link https://docs.ccxt.com/#/?id=order-structure}
205
- */
206
- fetchOrdersByStatus(status: any, symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Order[]>;
207
- /**
208
- * @method
209
- * @name kuna#fetchMyTrades
210
- * @description fetch all trades made by the user
211
- * @see https://docs.kuna.io/docs/get-private-trades-history
212
- * @param {string} symbol unified market symbol
213
- * @param {int} [since] not used by kuna fetchMyTrades
214
- * @param {int} [limit] not used by kuna fetchMyTrades
215
- * @param {object} [params] extra parameters specific to the exchange API endpoint
216
- *
217
- * EXCHANGE SPECIFIC PARAMETERS
218
- * @param {string} [params.orderId] UUID of an order, to receive trades for this order only
219
- * @param {string} [params.sort] asc (oldest-on-top) or desc (newest-on-top)
220
- * @returns {Trade[]} a list of [trade structures]{@link https://docs.ccxt.com/#/?id=trade-structure}
221
- */
222
- fetchMyTrades(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Trade[]>;
223
- /**
224
- * @method
225
- * @name kuna#withdraw
226
- * @description make a withdrawal
227
- * @see https://docs.kuna.io/docs/create-a-withdraw
228
- * @param {string} code unified currency code
229
- * @param {float} amount the amount to withdraw
230
- * @param {string} address the address to withdraw to
231
- * @param {string} tag
232
- * @param {object} [params] extra parameters specific to the exchange API endpoint
233
- * @param {string} [params.chain] the chain to withdraw to
234
- *
235
- * EXCHANGE SPECIFIC PARAMETERS
236
- * @param {string} [params.id] id must be a uuid format, if you do not specify id, it will be generated automatically
237
- * @param {boolean} [params.withdrawAll] this field says that the amount should also include a fee
238
- * @returns {object} a [transaction structure]{@link https://docs.ccxt.com/#/?id=transaction-structure}
239
- */
240
- withdraw(code: string, amount: number, address: string, tag?: any, params?: {}): Promise<Transaction>;
241
- /**
242
- * @method
243
- * @name kuna#fetchWithdrawals
244
- * @description fetch all withdrawals made to an account
245
- * @see https://docs.kuna.io/docs/get-withdraw-history
246
- * @param {string} code unified currency code
247
- * @param {int} [since] the earliest time in ms to fetch withdrawals for
248
- * @param {int} [limit] the maximum number of withdrawals structures to retrieve
249
- * @param {object} [params] extra parameters specific to the exchange API endpoint
250
- * @param {int} [params.until] the latest time in ms to fetch deposits for
251
- *
252
- * EXCHANGE SPECIFIC PARAMETERS
253
- * @param {string} [params.status] Created, Canceled, PartiallyProcessed, Processing, Processed, WaitForConfirmation, Pending, AmlChecking
254
- * @param {string} [params.sortField] amount (sorting by time), createdAt (sorting by date)
255
- * @param {string} [params.sortOrder] asc (oldest-on-top), or desc (newest-on-top, default)
256
- * @param {int} [params.skip] 0 - ... Select the number of transactions to skip
257
- * @param {string} [params.address]
258
- * @returns {object[]} a list of [transaction structures]{@link https://docs.ccxt.com/#/?id=transaction-structure}
259
- */
260
- fetchWithdrawals(code?: Str, since?: Int, limit?: Int, params?: {}): Promise<Transaction[]>;
261
- /**
262
- * @method
263
- * @name kuna#fetchWithdrawal
264
- * @description fetch data on a currency withdrawal via the withdrawal id
265
- * @see https://docs.kuna.io/docs/get-withdraw-details-by-id
266
- * @param {string} id withdrawal id
267
- * @param {string} code not used by kuna.fetchWithdrawal
268
- * @param {object} [params] extra parameters specific to the exchange API endpoint
269
- * @returns {object} a [transaction structure]{@link https://docs.ccxt.com/#/?id=transaction-structure}
270
- */
271
- fetchWithdrawal(id: string, code?: Str, params?: {}): Promise<Transaction>;
272
- /**
273
- * @method
274
- * @name kuna#createDepositAddress
275
- * @description create a currency deposit address
276
- * @see https://docs.kuna.io/docs/generate-a-constant-crypto-address-for-deposit
277
- * @param {string} code unified currency code of the currency for the deposit address
278
- * @param {object} [params] extra parameters specific to the exchange API endpoint
279
- * @returns {object} an [address structure]{@link https://docs.ccxt.com/#/?id=address-structure}
280
- */
281
- createDepositAddress(code: string, params?: {}): Promise<DepositAddress>;
282
- /**
283
- * @method
284
- * @name kuna#fetchDepositAddress
285
- * @description fetch the deposit address for a currency associated with this account
286
- * @see https://docs.kuna.io/docs/find-crypto-address-for-deposit
287
- * @param {string} code unified currency code
288
- * @param {object} [params] extra parameters specific to the exchange API endpoint
289
- * @returns {object} an [address structure]{@link https://docs.ccxt.com/#/?id=address-structure}
290
- */
291
- fetchDepositAddress(code: string, params?: {}): Promise<DepositAddress>;
292
- parseDepositAddress(depositAddress: any, currency?: Currency): DepositAddress;
293
- parseTransactionStatus(status: Str): string;
294
- /**
295
- * @method
296
- * @name kuna#fetchDeposits
297
- * @description fetch all deposits made to an account
298
- * @see https://docs.kuna.io/docs/get-deposit-history
299
- * @param {string} code unified currency code
300
- * @param {int} [since] the earliest time in ms to fetch deposits for
301
- * @param {int} [limit] the maximum number of deposits structures to retrieve
302
- * @param {object} [params] extra parameters specific to the exchange API endpoint
303
- * @param {int} [params.until] the latest time in ms to fetch deposits for
304
- *
305
- * EXCHANGE SPECIFIC PARAMETERS
306
- * @param {string} [params.status] Created, Canceled, PartiallyProcessed, Processing, Processed, WaitForConfirmation, Pending, AmlChecking
307
- * @param {string} [params.sortField] amount (sorting by time), createdAt (sorting by date)
308
- * @param {string} [params.sortOrder] asc (oldest-on-top), or desc (newest-on-top, default)
309
- * @param {int} [params.skip] 0 - ... Select the number of transactions to skip
310
- * @param {string} [params.address]
311
- * @returns {object[]} a list of [transaction structures]{@link https://docs.ccxt.com/#/?id=transaction-structure}
312
- */
313
- fetchDeposits(code?: Str, since?: Int, limit?: Int, params?: {}): Promise<Transaction[]>;
314
- /**
315
- * @method
316
- * @name kuna#fetchDeposit
317
- * @description fetch data on a currency deposit via the deposit id
318
- * @see https://docs.kuna.io/docs/get-deposit-details-by-id
319
- * @param {string} id deposit id
320
- * @param {string} code filter by currency code
321
- * @param {object} [params] extra parameters specific to the exchange API endpoint
322
- * @returns {object} a [transaction structure]{@link https://docs.ccxt.com/#/?id=transaction-structure}
323
- */
324
- fetchDeposit(id: string, code?: Str, params?: {}): Promise<Transaction>;
325
- parseTransaction(transaction: Dict, currency?: Currency): Transaction;
326
- nonce(): number;
327
- encodeParams(params: any): string;
328
- sign(path: any, api?: string, method?: string, params?: {}, headers?: any, body?: any): {
329
- url: any;
330
- method: string;
331
- body: any;
332
- headers: any;
333
- };
334
- handleErrors(code: int, reason: string, url: string, method: string, headers: Dict, body: string, response: any, requestHeaders: any, requestBody: any): any;
335
- }