ccxt 4.1.87 → 4.1.88

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 (85) hide show
  1. package/README.md +10 -9
  2. package/dist/ccxt.browser.js +8463 -4862
  3. package/dist/ccxt.browser.min.js +2 -2
  4. package/dist/cjs/ccxt.js +6 -1
  5. package/dist/cjs/src/base/Exchange.js +95 -27
  6. package/dist/cjs/src/base/ws/Client.js +3 -3
  7. package/dist/cjs/src/base/ws/Future.js +9 -2
  8. package/dist/cjs/src/base/ws/WsClient.js +1 -1
  9. package/dist/cjs/src/binance.js +4 -105
  10. package/dist/cjs/src/bit2c.js +8 -2
  11. package/dist/cjs/src/bitget.js +3455 -2480
  12. package/dist/cjs/src/bitmart.js +35 -9
  13. package/dist/cjs/src/coinbase.js +2 -0
  14. package/dist/cjs/src/coinbasepro.js +0 -43
  15. package/dist/cjs/src/coinsph.js +0 -29
  16. package/dist/cjs/src/cryptocom.js +22 -10
  17. package/dist/cjs/src/gate.js +37 -39
  18. package/dist/cjs/src/gemini.js +1 -0
  19. package/dist/cjs/src/novadax.js +28 -16
  20. package/dist/cjs/src/okcoin.js +23 -5
  21. package/dist/cjs/src/pro/binance.js +18 -215
  22. package/dist/cjs/src/pro/bitget.js +780 -736
  23. package/dist/cjs/src/pro/bitmart.js +8 -10
  24. package/dist/cjs/src/pro/bitmex.js +9 -34
  25. package/dist/cjs/src/pro/bitpanda.js +4 -4
  26. package/dist/cjs/src/pro/bybit.js +21 -97
  27. package/dist/cjs/src/pro/coinbasepro.js +36 -40
  28. package/dist/cjs/src/pro/cryptocom.js +10 -26
  29. package/dist/cjs/src/pro/gate.js +20 -17
  30. package/dist/cjs/src/pro/kucoin.js +39 -39
  31. package/dist/cjs/src/pro/kucoinfutures.js +40 -36
  32. package/dist/cjs/src/pro/okx.js +16 -29
  33. package/js/ccxt.d.ts +8 -2
  34. package/js/ccxt.js +6 -2
  35. package/js/src/abstract/bitget.d.ts +1 -1
  36. package/js/src/abstract/coinbasepro.d.ts +69 -0
  37. package/js/src/abstract/coinbasepro.js +11 -0
  38. package/js/src/base/Exchange.d.ts +2 -3
  39. package/js/src/base/Exchange.js +96 -28
  40. package/js/src/base/ws/Client.d.ts +2 -2
  41. package/js/src/base/ws/Client.js +4 -4
  42. package/js/src/base/ws/Future.d.ts +5 -2
  43. package/js/src/base/ws/Future.js +8 -2
  44. package/js/src/base/ws/WsClient.d.ts +1 -1
  45. package/js/src/base/ws/WsClient.js +2 -2
  46. package/js/src/binance.d.ts +0 -9
  47. package/js/src/binance.js +4 -105
  48. package/js/src/bit2c.js +8 -2
  49. package/js/src/bitget.d.ts +13 -11
  50. package/js/src/bitget.js +3455 -2480
  51. package/js/src/bitmart.js +35 -9
  52. package/js/src/coinbase.js +2 -0
  53. package/js/src/coinbasepro.d.ts +0 -4
  54. package/js/src/coinbasepro.js +1 -44
  55. package/js/src/coinsph.d.ts +0 -1
  56. package/js/src/coinsph.js +0 -29
  57. package/js/src/cryptocom.js +22 -10
  58. package/js/src/gate.js +37 -39
  59. package/js/src/gemini.js +1 -0
  60. package/js/src/novadax.js +28 -16
  61. package/js/src/okcoin.js +23 -5
  62. package/js/src/pro/binance.d.ts +0 -2
  63. package/js/src/pro/binance.js +19 -216
  64. package/js/src/pro/bitget.d.ts +3 -5
  65. package/js/src/pro/bitget.js +780 -736
  66. package/js/src/pro/bitmart.js +8 -10
  67. package/js/src/pro/bitmex.js +9 -34
  68. package/js/src/pro/bitpanda.d.ts +1 -1
  69. package/js/src/pro/bitpanda.js +4 -4
  70. package/js/src/pro/bybit.d.ts +1 -2
  71. package/js/src/pro/bybit.js +21 -97
  72. package/js/src/pro/coinbasepro.d.ts +2 -2
  73. package/js/src/pro/coinbasepro.js +36 -40
  74. package/js/src/pro/cryptocom.d.ts +1 -1
  75. package/js/src/pro/cryptocom.js +10 -26
  76. package/js/src/pro/gate.d.ts +1 -0
  77. package/js/src/pro/gate.js +20 -17
  78. package/js/src/pro/kucoin.d.ts +1 -0
  79. package/js/src/pro/kucoin.js +39 -39
  80. package/js/src/pro/kucoinfutures.d.ts +2 -1
  81. package/js/src/pro/kucoinfutures.js +40 -36
  82. package/js/src/pro/okx.d.ts +1 -1
  83. package/js/src/pro/okx.js +16 -29
  84. package/package.json +1 -1
  85. package/skip-tests.json +3 -14
@@ -1,5 +1,5 @@
1
1
  import Exchange from './abstract/bitget.js';
2
- import type { Int, OrderSide, OrderType, Trade, OHLCV, Order, FundingRateHistory, OrderRequest, FundingHistory, Balances, Str, Transaction, Ticker, OrderBook, Tickers, Market, Strings, Currency, Position } from './base/types.js';
2
+ import type { Int, OrderSide, OrderType, Trade, OHLCV, Order, FundingRateHistory, OrderRequest, FundingHistory, Balances, Str, Transaction, Ticker, OrderBook, Tickers, Market, Strings, Currency, Position, Liquidation } from './base/types.js';
3
3
  /**
4
4
  * @class bitget
5
5
  * @augments Exchange
@@ -7,6 +7,8 @@ import type { Int, OrderSide, OrderType, Trade, OHLCV, Order, FundingRateHistory
7
7
  export default class bitget extends Exchange {
8
8
  describe(): any;
9
9
  setSandboxMode(enabled: any): void;
10
+ convertSymbolForSandbox(symbol: any): any;
11
+ handleProductTypeAndParams(market?: any, params?: {}): {}[];
10
12
  fetchTime(params?: {}): Promise<number>;
11
13
  fetchMarkets(params?: {}): Promise<any>;
12
14
  parseMarket(market: any): Market;
@@ -16,7 +18,7 @@ export default class bitget extends Exchange {
16
18
  parseMarketLeverageTiers(info: any, market?: Market): any[];
17
19
  fetchDeposits(code?: Str, since?: Int, limit?: Int, params?: {}): Promise<Transaction[]>;
18
20
  withdraw(code: string, amount: any, address: any, tag?: any, params?: {}): Promise<{
19
- id: any;
21
+ id: string;
20
22
  info: any;
21
23
  txid: any;
22
24
  timestamp: any;
@@ -78,26 +80,26 @@ export default class bitget extends Exchange {
78
80
  parseBalance(balance: any): Balances;
79
81
  parseOrderStatus(status: any): string;
80
82
  parseOrder(order: any, market?: Market): Order;
83
+ createMarketBuyOrderWithCost(symbol: string, cost: any, params?: {}): Promise<Order>;
81
84
  createOrder(symbol: string, type: OrderType, side: OrderSide, amount: any, price?: any, params?: {}): Promise<Order>;
82
85
  createOrderRequest(symbol: any, type: any, side: any, amount: any, price?: any, params?: {}): any;
83
86
  createOrders(orders: OrderRequest[], params?: {}): Promise<Order[]>;
84
87
  editOrder(id: string, symbol: any, type: any, side: any, amount?: any, price?: any, params?: {}): Promise<Order>;
85
88
  cancelOrder(id: string, symbol?: Str, params?: {}): Promise<Order>;
86
- cancelOrders(ids: any, symbol?: Str, params?: {}): Promise<any>;
89
+ cancelOrders(ids: any, symbol?: Str, params?: {}): Promise<Order[]>;
87
90
  cancelAllOrders(symbol?: Str, params?: {}): Promise<any>;
88
91
  fetchOrder(id: string, symbol?: Str, params?: {}): Promise<Order>;
89
92
  fetchOpenOrders(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Order[]>;
90
93
  fetchClosedOrders(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Order[]>;
91
94
  fetchCanceledOrders(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Order[]>;
92
95
  fetchCanceledAndClosedOrders(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<any>;
93
- addPaginationCursorToResult(response: any, data: any): any;
94
96
  fetchLedger(code?: Str, since?: Int, limit?: Int, params?: {}): Promise<any>;
95
97
  parseLedgerEntry(item: any, currency?: Currency): {
96
98
  info: any;
97
99
  id: string;
98
100
  timestamp: number;
99
101
  datetime: string;
100
- direction: any;
102
+ direction: string;
101
103
  account: any;
102
104
  referenceId: any;
103
105
  referenceAccount: any;
@@ -109,8 +111,8 @@ export default class bitget extends Exchange {
109
111
  status: any;
110
112
  fee: number;
111
113
  };
114
+ parseLedgerType(type: any): string;
112
115
  fetchMyTrades(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Trade[]>;
113
- fetchOrderTrades(id: string, symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Trade[]>;
114
116
  fetchPosition(symbol: string, params?: {}): Promise<Position>;
115
117
  fetchPositions(symbols?: Strings, params?: {}): Promise<Position[]>;
116
118
  parsePosition(position: any, market?: Market): Position;
@@ -180,6 +182,7 @@ export default class bitget extends Exchange {
180
182
  setMarginMode(marginMode: any, symbol?: Str, params?: {}): Promise<any>;
181
183
  setPositionMode(hedged: any, symbol?: Str, params?: {}): Promise<any>;
182
184
  fetchOpenInterest(symbol: string, params?: {}): Promise<import("./base/types.js").OpenInterest>;
185
+ parseOpenInterest(interest: any, market?: Market): import("./base/types.js").OpenInterest;
183
186
  fetchTransfers(code?: Str, since?: Int, limit?: Int, params?: {}): Promise<any>;
184
187
  transfer(code: string, amount: any, fromAccount: any, toAccount: any, params?: {}): Promise<{
185
188
  info: any;
@@ -203,6 +206,7 @@ export default class bitget extends Exchange {
203
206
  toAccount: string;
204
207
  status: string;
205
208
  };
209
+ parseTransferStatus(status: any): string;
206
210
  parseDepositWithdrawFee(fee: any, currency?: Currency): {
207
211
  info: any;
208
212
  withdraw: {
@@ -216,8 +220,6 @@ export default class bitget extends Exchange {
216
220
  networks: {};
217
221
  };
218
222
  fetchDepositWithdrawFees(codes?: Strings, params?: {}): Promise<any>;
219
- parseTransferStatus(status: any): string;
220
- parseOpenInterest(interest: any, market?: Market): import("./base/types.js").OpenInterest;
221
223
  borrowCrossMargin(code: string, amount: any, params?: {}): Promise<{
222
224
  id: string;
223
225
  currency: string;
@@ -254,7 +256,7 @@ export default class bitget extends Exchange {
254
256
  datetime: any;
255
257
  info: any;
256
258
  }>;
257
- parseMarginLoan(info: any, currency?: Currency): {
259
+ parseMarginLoan(info: any, currency?: Currency, market?: Market): {
258
260
  id: string;
259
261
  currency: string;
260
262
  amount: number;
@@ -263,8 +265,8 @@ export default class bitget extends Exchange {
263
265
  datetime: any;
264
266
  info: any;
265
267
  };
266
- fetchMyLiquidations(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<import("./base/types.js").Liquidation[]>;
267
- parseLiquidation(liquidation: any, market?: Market): import("./base/types.js").Liquidation;
268
+ fetchMyLiquidations(symbol?: Str, since?: Int, limit?: Int, params?: {}): Promise<Liquidation[]>;
269
+ parseLiquidation(liquidation: any, market?: Market): Liquidation;
268
270
  fetchIsolatedBorrowRate(symbol: string, params?: {}): Promise<{
269
271
  symbol: string;
270
272
  base: string;