bybit-api 3.10.30 → 4.0.0-beta.0

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 (146) hide show
  1. package/README.md +301 -178
  2. package/lib/index.d.ts +0 -11
  3. package/lib/index.js +0 -11
  4. package/lib/index.js.map +1 -1
  5. package/lib/rest-client-v5.d.ts +1 -1
  6. package/lib/rest-client-v5.js +1 -1
  7. package/lib/spot-client-v3.d.ts +8 -81
  8. package/lib/spot-client-v3.js +7 -172
  9. package/lib/spot-client-v3.js.map +1 -1
  10. package/lib/types/index.d.ts +1 -2
  11. package/lib/types/index.js +1 -2
  12. package/lib/types/index.js.map +1 -1
  13. package/lib/types/request/index.d.ts +0 -1
  14. package/lib/types/request/index.js +0 -1
  15. package/lib/types/request/index.js.map +1 -1
  16. package/lib/types/request/v5-account.d.ts +1 -1
  17. package/lib/types/request/v5-asset.d.ts +1 -1
  18. package/lib/types/request/v5-market.d.ts +1 -1
  19. package/lib/types/request/v5-position.d.ts +1 -1
  20. package/lib/types/request/v5-pre-upgrade.d.ts +1 -1
  21. package/lib/types/request/v5-spot-leverage-token.d.ts +1 -1
  22. package/lib/types/request/v5-trade.d.ts +1 -1
  23. package/lib/types/request/v5-user.d.ts +1 -1
  24. package/lib/types/response/v5-account.d.ts +1 -1
  25. package/lib/types/response/v5-asset.d.ts +1 -1
  26. package/lib/types/response/v5-market.d.ts +1 -1
  27. package/lib/types/response/v5-position.d.ts +1 -1
  28. package/lib/types/response/v5-spot-leverage-token.d.ts +1 -1
  29. package/lib/types/response/v5-trade.d.ts +1 -1
  30. package/lib/types/response/v5-user.d.ts +1 -1
  31. package/lib/types/{request/spot.js → shared-v5.js} +1 -1
  32. package/lib/types/shared-v5.js.map +1 -0
  33. package/lib/types/shared.d.ts +1 -19
  34. package/lib/types/websockets/index.d.ts +3 -0
  35. package/lib/types/websockets/index.js +20 -0
  36. package/lib/types/websockets/index.js.map +1 -0
  37. package/lib/types/websockets/ws-api.d.ts +73 -0
  38. package/lib/types/websockets/ws-api.js +10 -0
  39. package/lib/types/websockets/ws-api.js.map +1 -0
  40. package/lib/types/websockets/ws-confirmations.d.ts +13 -0
  41. package/lib/types/{websocket.events.js → websockets/ws-confirmations.js} +1 -1
  42. package/lib/types/websockets/ws-confirmations.js.map +1 -0
  43. package/lib/types/{websocket.events.d.ts → websockets/ws-events.d.ts} +9 -3
  44. package/lib/types/websockets/ws-events.js +11 -0
  45. package/lib/types/websockets/ws-events.js.map +1 -0
  46. package/lib/types/{websockets.d.ts → websockets/ws-general.d.ts} +35 -10
  47. package/lib/types/{v5-shared.js → websockets/ws-general.js} +1 -1
  48. package/lib/types/websockets/ws-general.js.map +1 -0
  49. package/lib/util/BaseRestClient.d.ts +1 -1
  50. package/lib/util/BaseRestClient.js +15 -39
  51. package/lib/util/BaseRestClient.js.map +1 -1
  52. package/lib/util/BaseWSClient.d.ts +221 -0
  53. package/lib/util/BaseWSClient.js +733 -0
  54. package/lib/util/BaseWSClient.js.map +1 -0
  55. package/lib/util/index.d.ts +1 -2
  56. package/lib/util/index.js +1 -2
  57. package/lib/util/index.js.map +1 -1
  58. package/lib/util/logger.d.ts +2 -5
  59. package/lib/util/logger.js +3 -12
  60. package/lib/util/logger.js.map +1 -1
  61. package/lib/util/requestUtils.d.ts +7 -10
  62. package/lib/util/requestUtils.js +6 -33
  63. package/lib/util/requestUtils.js.map +1 -1
  64. package/lib/util/typeGuards.d.ts +7 -1
  65. package/lib/util/typeGuards.js +41 -5
  66. package/lib/util/typeGuards.js.map +1 -1
  67. package/lib/util/webCryptoAPI.d.ts +10 -0
  68. package/lib/util/webCryptoAPI.js +69 -0
  69. package/lib/util/webCryptoAPI.js.map +1 -0
  70. package/lib/util/websockets/WsStore.d.ts +71 -0
  71. package/lib/util/websockets/WsStore.js +269 -0
  72. package/lib/util/websockets/WsStore.js.map +1 -0
  73. package/lib/util/websockets/WsStore.types.d.ts +50 -0
  74. package/lib/util/websockets/WsStore.types.js +14 -0
  75. package/lib/util/websockets/WsStore.types.js.map +1 -0
  76. package/lib/util/websockets/index.d.ts +3 -0
  77. package/lib/util/websockets/index.js +20 -0
  78. package/lib/util/websockets/index.js.map +1 -0
  79. package/lib/util/websockets/websocket-util.d.ts +92 -0
  80. package/lib/util/websockets/websocket-util.js +280 -0
  81. package/lib/util/websockets/websocket-util.js.map +1 -0
  82. package/lib/websocket-client.d.ts +107 -114
  83. package/lib/websocket-client.js +422 -716
  84. package/lib/websocket-client.js.map +1 -1
  85. package/package.json +4 -4
  86. package/lib/account-asset-client-v3.d.ts +0 -87
  87. package/lib/account-asset-client-v3.js +0 -154
  88. package/lib/account-asset-client-v3.js.map +0 -1
  89. package/lib/account-asset-client.d.ts +0 -46
  90. package/lib/account-asset-client.js +0 -108
  91. package/lib/account-asset-client.js.map +0 -1
  92. package/lib/contract-client.d.ts +0 -136
  93. package/lib/contract-client.js +0 -251
  94. package/lib/contract-client.js.map +0 -1
  95. package/lib/copy-trading-client.d.ts +0 -60
  96. package/lib/copy-trading-client.js +0 -114
  97. package/lib/copy-trading-client.js.map +0 -1
  98. package/lib/inverse-client.d.ts +0 -104
  99. package/lib/inverse-client.js +0 -213
  100. package/lib/inverse-client.js.map +0 -1
  101. package/lib/inverse-futures-client.d.ts +0 -217
  102. package/lib/inverse-futures-client.js +0 -224
  103. package/lib/inverse-futures-client.js.map +0 -1
  104. package/lib/linear-client.d.ts +0 -112
  105. package/lib/linear-client.js +0 -225
  106. package/lib/linear-client.js.map +0 -1
  107. package/lib/spot-client.d.ts +0 -46
  108. package/lib/spot-client.js +0 -131
  109. package/lib/spot-client.js.map +0 -1
  110. package/lib/types/request/spot.d.ts +0 -79
  111. package/lib/types/request/spot.js.map +0 -1
  112. package/lib/types/v5-shared.js.map +0 -1
  113. package/lib/types/websocket.events.js.map +0 -1
  114. package/lib/types/websockets.js +0 -3
  115. package/lib/types/websockets.js.map +0 -1
  116. package/lib/types/ws-events/failed-topic-subscription-confirmation.d.ts +0 -4
  117. package/lib/types/ws-events/failed-topic-subscription-confirmation.js +0 -3
  118. package/lib/types/ws-events/failed-topic-subscription-confirmation.js.map +0 -1
  119. package/lib/types/ws-events/succeeded-topic-subscription-confirmation.d.ts +0 -4
  120. package/lib/types/ws-events/succeeded-topic-subscription-confirmation.js +0 -3
  121. package/lib/types/ws-events/succeeded-topic-subscription-confirmation.js.map +0 -1
  122. package/lib/types/ws-events/topic-subscription-confirmation.d.ts +0 -7
  123. package/lib/types/ws-events/topic-subscription-confirmation.js +0 -3
  124. package/lib/types/ws-events/topic-subscription-confirmation.js.map +0 -1
  125. package/lib/unified-margin-client.d.ts +0 -140
  126. package/lib/unified-margin-client.js +0 -270
  127. package/lib/unified-margin-client.js.map +0 -1
  128. package/lib/usdc-option-client.d.ts +0 -110
  129. package/lib/usdc-option-client.js +0 -196
  130. package/lib/usdc-option-client.js.map +0 -1
  131. package/lib/usdc-perpetual-client.d.ts +0 -97
  132. package/lib/usdc-perpetual-client.js +0 -191
  133. package/lib/usdc-perpetual-client.js.map +0 -1
  134. package/lib/util/WsStore.d.ts +0 -57
  135. package/lib/util/WsStore.js +0 -97
  136. package/lib/util/WsStore.js.map +0 -1
  137. package/lib/util/browser-support.d.ts +0 -1
  138. package/lib/util/browser-support.js +0 -26
  139. package/lib/util/browser-support.js.map +0 -1
  140. package/lib/util/node-support.d.ts +0 -2
  141. package/lib/util/node-support.js +0 -21
  142. package/lib/util/node-support.js.map +0 -1
  143. package/lib/util/websocket-util.d.ts +0 -68
  144. package/lib/util/websocket-util.js +0 -506
  145. package/lib/util/websocket-util.js.map +0 -1
  146. /package/lib/types/{v5-shared.d.ts → shared-v5.d.ts} +0 -0
@@ -1,270 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
- var __importDefault = (this && this.__importDefault) || function (mod) {
12
- return (mod && mod.__esModule) ? mod : { "default": mod };
13
- };
14
- Object.defineProperty(exports, "__esModule", { value: true });
15
- exports.UnifiedMarginClient = void 0;
16
- const util_1 = require("./util");
17
- const BaseRestClient_1 = __importDefault(require("./util/BaseRestClient"));
18
- /**
19
- * REST API client for Derivatives V3 unified margin APIs
20
- * @deprecated WARNING
21
- * These endpoints are being switched off gradually and are expected to be completely turned off by the end of 2024.
22
- * They may stop working at any point before then.
23
- * Please update your code as soon as possible to use the V5 APIs instead.
24
- */
25
- class UnifiedMarginClient extends BaseRestClient_1.default {
26
- getClientType() {
27
- return util_1.REST_CLIENT_TYPE_ENUM.v3;
28
- }
29
- fetchServerTime() {
30
- return __awaiter(this, void 0, void 0, function* () {
31
- const res = yield this.getServerTime();
32
- return Number(res.time_now);
33
- });
34
- }
35
- /**
36
- *
37
- * Market Data Endpoints
38
- *
39
- */
40
- /** Query order book info. Each side has a depth of 25 orders. */
41
- getOrderBook(symbol, category, limit) {
42
- return this.get('/derivatives/v3/public/order-book/L2', {
43
- category,
44
- symbol,
45
- limit,
46
- });
47
- }
48
- /** Get candles/klines */
49
- getCandles(params) {
50
- return this.get('/derivatives/v3/public/kline', params);
51
- }
52
- /** Get a symbol price/statistics ticker */
53
- getSymbolTicker(category, symbol) {
54
- return this.get('/derivatives/v3/public/tickers', { category, symbol });
55
- }
56
- /** Get trading rules per symbol/contract, incl price/amount/value/leverage filters */
57
- getInstrumentInfo(params) {
58
- return this.get('/derivatives/v3/public/instruments-info', params);
59
- }
60
- /** Query mark price kline (like getCandles() but for mark price). */
61
- getMarkPriceCandles(params) {
62
- return this.get('/derivatives/v3/public/mark-price-kline', params);
63
- }
64
- /** Query Index Price Kline */
65
- getIndexPriceCandles(params) {
66
- return this.get('/derivatives/v3/public/index-price-kline', params);
67
- }
68
- /**
69
- * The funding rate is generated every 8 hours at 00:00 UTC, 08:00 UTC and 16:00 UTC.
70
- * For example, if a request is sent at 12:00 UTC, the funding rate generated earlier that day at 08:00 UTC will be sent.
71
- */
72
- getFundingRateHistory(params) {
73
- return this.get('/derivatives/v3/public/funding/history-funding-rate', params);
74
- }
75
- /** Get Risk Limit */
76
- getRiskLimit(category, symbol) {
77
- return this.get('/derivatives/v3/public/risk-limit/list', {
78
- category,
79
- symbol,
80
- });
81
- }
82
- /** Get option delivery price */
83
- getOptionDeliveryPrice(params) {
84
- return this.get('/derivatives/v3/public/delivery-price', params);
85
- }
86
- /** Get recent trades */
87
- getTrades(params) {
88
- return this.get('/derivatives/v3/public/recent-trade', params);
89
- }
90
- /**
91
- * Gets the total amount of unsettled contracts.
92
- * In other words, the total number of contracts held in open positions.
93
- */
94
- getOpenInterest(params) {
95
- return this.get('/derivatives/v3/public/open-interest', params);
96
- }
97
- /**
98
- *
99
- * Unified Margin Account Endpoints
100
- *
101
- */
102
- /** -> Order API */
103
- /** Place an order */
104
- submitOrder(params) {
105
- return this.postPrivate('/unified/v3/private/order/create', params);
106
- }
107
- /** Active order parameters (such as quantity, price) and stop order parameters cannot be modified in one request at the same time. Please request modification separately. */
108
- modifyOrder(params) {
109
- return this.postPrivate('/unified/v3/private/order/replace', params);
110
- }
111
- /** Cancel order */
112
- cancelOrder(params) {
113
- return this.postPrivate('/unified/v3/private/order/cancel', params);
114
- }
115
- /** Query Open Orders */
116
- getActiveOrders(params) {
117
- return this.getPrivate('/unified/v3/private/order/unfilled-orders', params);
118
- }
119
- /** Query order history. As order creation/cancellation is asynchronous, the data returned from the interface may be delayed. To access order information in real-time, call getActiveOrders() */
120
- getHistoricOrders(params) {
121
- return this.getPrivate('/unified/v3/private/order/list', params);
122
- }
123
- /**
124
- * This API provides the batch order mode under the unified margin account.
125
- * Max 10 per request
126
- */
127
- batchSubmitOrders(category, orders) {
128
- return this.postPrivate('/unified/v3/private/order/create-batch', {
129
- category,
130
- request: orders,
131
- });
132
- }
133
- /**
134
- * This interface can modify the open order information in batches.
135
- * Currently, it is not supported to modify the conditional order information.
136
- * Please note that only unfilled or partial filled orders can be modified.
137
- * If both futures and options orders are in one request, only the orders matching the category will be operated according to the category type
138
- */
139
- batchReplaceOrders(category, orders) {
140
- return this.postPrivate('/unified/v3/private/order/replace-batch', {
141
- category,
142
- request: orders,
143
- });
144
- }
145
- /**
146
- * This API provides batch cancellation under the unified margin account.
147
- * Order cancellation of futures and options cannot be canceled in one request at the same time.
148
- * If both futures and options orders are in one request, only the orders matching the category will be operated according to the category type.
149
- */
150
- batchCancelOrders(category, orders) {
151
- return this.postPrivate('/unified/v3/private/order/cancel-batch', {
152
- category,
153
- request: orders,
154
- });
155
- }
156
- /**
157
- * This API provides the cancellation of all open orders under the unified margin account.
158
- * Order cancellation of futures and options cannot be canceled in one request at the same time.
159
- * If both futures and options orders are in one request, only the orders matching the category will be operated according to the category type.
160
- */
161
- cancelAllOrders(params) {
162
- return this.postPrivate('/unified/v3/private/order/cancel-all', params);
163
- }
164
- /** -> Positions API */
165
- /**
166
- * Query my positions real-time. Accessing personal list of positions.
167
- * Users can access their position holding information through this interface, such as the number of position holdings and wallet balance.
168
- */
169
- getPositions(params) {
170
- return this.getPrivate('/unified/v3/private/position/list', params);
171
- }
172
- /** Leverage setting. */
173
- setLeverage(category, symbol, buyLeverage, sellLeverage) {
174
- return this.postPrivate('/unified/v3/private/position/set-leverage', {
175
- category,
176
- symbol,
177
- buyLeverage,
178
- sellLeverage,
179
- });
180
- }
181
- /**
182
- * Switching the TP/SL mode to the cross margin mode or selected positions.
183
- * When you set the TP/SL mode on the selected positions, the quantity of take-profit or stop-loss orders can be smaller than the position size. Please use Trading-Stop endpoint.
184
- */
185
- setTPSLMode(category, symbol, tpSlMode) {
186
- return this.postPrivate('/unified/v3/private/position/tpsl/switch-mode', {
187
- category,
188
- symbol,
189
- tpSlMode,
190
- });
191
- }
192
- /** Set risk limit */
193
- setRiskLimit(category, symbol, riskId, positionIdx) {
194
- return this.postPrivate('/unified/v3/private/position/set-risk-limit', {
195
- category,
196
- symbol,
197
- riskId,
198
- positionIdx,
199
- });
200
- }
201
- /**
202
- * Set position TP/SL and trailing stop.
203
- * Pass the following parameters, then the system will create conditional orders.
204
- * If the position is closed, the system will cancel these orders, and adjust the position size.
205
- */
206
- setTPSL(params) {
207
- return this.postPrivate('/unified/v3/private/position/trading-stop', params);
208
- }
209
- /**
210
- * Access the user's filled history, ranked by time in descending order.
211
- * There might be multiple filled histories for an order.
212
- */
213
- get7DayTradingHistory(params) {
214
- return this.getPrivate('/unified/v3/private/execution/list', params);
215
- }
216
- /** Query the settlement history, ranked by time in descending order. */
217
- getOptionsSettlementHistory(params) {
218
- return this.getPrivate('/unified/v3/private/delivery-record', params);
219
- }
220
- /** Query session settlement records, only for USDC perpetual */
221
- getUSDCPerpetualSettlementHistory(params) {
222
- return this.getPrivate('/unified/v3/private/settlement-record', params);
223
- }
224
- /** -> Account API */
225
- /** Query wallet balance */
226
- getBalances(coin) {
227
- return this.getPrivate('/unified/v3/private/account/wallet/balance', {
228
- coin,
229
- });
230
- }
231
- /**
232
- * Upgrade to unified margin account.
233
- * WARNING: This is currently not reversable!
234
- */
235
- upgradeToUnifiedMargin() {
236
- return this.postPrivate('/unified/v3/private/account/upgrade-unified-account');
237
- }
238
- /** Query trading history */
239
- getTransactionLog(params) {
240
- return this.getPrivate('/unified/v3/private/account/transaction-log', params);
241
- }
242
- /** Fund transfer between accounts (v2) */
243
- transferFunds(params) {
244
- return this.postPrivate('/asset/v1/private/transfer', params);
245
- }
246
- /** Exchange Coins */
247
- getCoinExchangeHistory(params) {
248
- return this.getPrivate('/asset/v2/private/exchange/exchange-order-all', params);
249
- }
250
- /** Get Borrow History */
251
- getBorrowHistory(params) {
252
- return this.getPrivate('/unified/v3/private/account/borrow-history', params);
253
- }
254
- /** Get Borrow Rate */
255
- getBorrowRate(currency) {
256
- return this.getPrivate('/unified/v3/private/account/borrow-rate', {
257
- currency,
258
- });
259
- }
260
- /**
261
- *
262
- * API Data Endpoints
263
- *
264
- */
265
- getServerTime() {
266
- return this.get('/v2/public/time');
267
- }
268
- }
269
- exports.UnifiedMarginClient = UnifiedMarginClient;
270
- //# sourceMappingURL=unified-margin-client.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"unified-margin-client.js","sourceRoot":"","sources":["../src/unified-margin-client.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAkCA,iCAA+C;AAC/C,2EAAmD;AAEnD;;;;;;GAMG;AACH,MAAa,mBAAoB,SAAQ,wBAAc;IACrD,aAAa;QACX,OAAO,4BAAqB,CAAC,EAAE,CAAC;IAClC,CAAC;IAEK,eAAe;;YACnB,MAAM,GAAG,GAAG,MAAM,IAAI,CAAC,aAAa,EAAE,CAAC;YACvC,OAAO,MAAM,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;QAC9B,CAAC;KAAA;IAED;;;;OAIG;IAEH,iEAAiE;IACjE,YAAY,CACV,MAAc,EACd,QAAgB,EAChB,KAAc;QAEd,OAAO,IAAI,CAAC,GAAG,CAAC,sCAAsC,EAAE;YACtD,QAAQ;YACR,MAAM;YACN,KAAK;SACN,CAAC,CAAC;IACL,CAAC;IAED,yBAAyB;IACzB,UAAU,CAAC,MAAwB;QACjC,OAAO,IAAI,CAAC,GAAG,CAAC,8BAA8B,EAAE,MAAM,CAAC,CAAC;IAC1D,CAAC;IAED,2CAA2C;IAC3C,eAAe,CACb,QAAoB,EACpB,MAAe;QAEf,OAAO,IAAI,CAAC,GAAG,CAAC,gCAAgC,EAAE,EAAE,QAAQ,EAAE,MAAM,EAAE,CAAC,CAAC;IAC1E,CAAC;IAED,sFAAsF;IACtF,iBAAiB,CACf,MAA+B;QAE/B,OAAO,IAAI,CAAC,GAAG,CAAC,yCAAyC,EAAE,MAAM,CAA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ACP,CAAC;IACJ,CAAC;IAED,0CAA0C;IAC1C,aAAa,CAAC,MAA+B;QAC3C,OAAO,IAAI,CAAC,WAAW,CAAC,4BAA4B,EAAE,MAAM,CAAC,CAAC;IAChE,CAAC;IAED,qBAAqB;IACrB,sBAAsB,CACpB,MAA+B;QAE/B,OAAO,IAAI,CAAC,UAAU,CACpB,+CAA+C,EAC/C,MAAM,CACP,CAAC;IACJ,CAAC;IAED,yBAAyB;IACzB,gBAAgB,CACd,MAA+B;QAE/B,OAAO,IAAI,CAAC,UAAU,CACpB,4CAA4C,EAC5C,MAAM,CACP,CAAC;IACJ,CAAC;IAED,sBAAsB;IACtB,aAAa,CAAC,QAAiB;QAC7B,OAAO,IAAI,CAAC,UAAU,CAAC,yCAAyC,EAAE;YAChE,QAAQ;SACT,CAAC,CAAC;IACL,CAAC;IAED;;;;OAIG;IAEH,aAAa;QACX,OAAO,IAAI,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC;IACrC,CAAC;CACF;AApWD,kDAoWC"}
@@ -1,110 +0,0 @@
1
- import { APIResponseV3, APIResponseWithTime, USDCOptionsActiveOrdersRealtimeRequest, USDCOptionsActiveOrdersRequest, USDCOptionsCancelAllOrdersRequest, USDCOptionsCancelOrderRequest, USDCOptionsContractInfoRequest, USDCOptionsDeliveryHistoryRequest, USDCOptionsDeliveryPriceRequest, USDCOptionsHistoricOrdersRequest, USDCOptionsHistoricalVolatilityRequest, USDCOptionsModifyMMPRequest, USDCOptionsModifyOrderRequest, USDCOptionsOrderExecutionRequest, USDCOptionsOrderRequest, USDCOptionsPositionsInfoExpiryRequest, USDCOptionsRecentTradesRequest, USDCPositionsRequest, USDCTransactionLogRequest } from './types';
2
- import BaseRestClient from './util/BaseRestClient';
3
- /**
4
- * REST API client for USDC Option APIs
5
- *
6
- * @deprecated WARNING: V1/V2 private endpoints (Rest API & Websocket Stream) for mainnet
7
- * will be switched off gradually from 30 Oct 2023 UTC, so they are not promised a stability.
8
- * Please note that you are at your own risk of using old endpoints going forward, and please move to V5 ASAP.
9
- */
10
- export declare class USDCOptionClient extends BaseRestClient {
11
- getClientType(): "v3";
12
- fetchServerTime(): Promise<number>;
13
- /**
14
- *
15
- * Market Data Endpoints
16
- *
17
- */
18
- /** Query order book info. Each side has a depth of 25 orders. */
19
- getOrderBook(symbol: string): Promise<APIResponseV3<any>>;
20
- /** Fetch trading rules (such as min/max qty). Query for all if blank. */
21
- getContractInfo(params?: USDCOptionsContractInfoRequest): Promise<APIResponseV3<any>>;
22
- /** Get a symbol price/statistics ticker */
23
- getSymbolTicker(symbol: string): Promise<APIResponseV3<any>>;
24
- /** Get delivery information */
25
- getDeliveryPrice(params?: USDCOptionsDeliveryPriceRequest): Promise<APIResponseV3<any>>;
26
- /** Returned records are Taker Buy in default. */
27
- getLast500Trades(params: USDCOptionsRecentTradesRequest): Promise<APIResponseV3<any>>;
28
- /**
29
- * The data is in hourly.
30
- * If time field is not passed, it returns the recent 1 hour data by default.
31
- * It could be any timeframe by inputting startTime & endTime, but it must satisfy [endTime - startTime] <= 30 days.
32
- * It returns all data in 2 years when startTime & endTime are not passed.
33
- * Both startTime & endTime entered together or both are left blank
34
- */
35
- getHistoricalVolatility(params?: USDCOptionsHistoricalVolatilityRequest): Promise<APIResponseV3<any>>;
36
- /**
37
- *
38
- * Account Data Endpoints
39
- *
40
- */
41
- /** -> Order API */
42
- /**
43
- * Place an order using the USDC Derivatives Account.
44
- * The request status can be queried in real-time.
45
- * The response parameters must be queried through a query or a WebSocket response.
46
- */
47
- submitOrder(params: USDCOptionsOrderRequest): Promise<APIResponseV3<any>>;
48
- /**
49
- * Each request supports a max. of four orders. The reduceOnly parameter should be separate and unique for each order in the request.
50
- */
51
- batchSubmitOrders(orderRequest: USDCOptionsOrderRequest[]): Promise<APIResponseV3<any>>;
52
- /** For Options, at least one of the three parameters — price, quantity or implied volatility — must be input. */
53
- modifyOrder(params: USDCOptionsModifyOrderRequest): Promise<APIResponseV3<any>>;
54
- /** Each request supports a max. of four orders. The reduceOnly parameter should be separate and unique for each order in the request. */
55
- batchModifyOrders(replaceOrderRequest: USDCOptionsModifyOrderRequest[]): Promise<APIResponseV3<any>>;
56
- /** Cancel order */
57
- cancelOrder(params: USDCOptionsCancelOrderRequest): Promise<APIResponseV3<any>>;
58
- /** Batch cancel orders */
59
- batchCancelOrders(cancelRequest: USDCOptionsCancelOrderRequest[]): Promise<APIResponseV3<any>>;
60
- /** This is used to cancel all active orders. The real-time response indicates whether the request is successful, depending on retCode. */
61
- cancelActiveOrders(params?: USDCOptionsCancelAllOrdersRequest): Promise<APIResponseV3<any>>;
62
- /** Query Unfilled/Partially Filled Orders(real-time), up to last 7 days of partially filled/unfilled orders */
63
- getActiveRealtimeOrders(params?: USDCOptionsActiveOrdersRealtimeRequest): Promise<APIResponseV3<any>>;
64
- /** Query Unfilled/Partially Filled Orders */
65
- getActiveOrders(params: USDCOptionsActiveOrdersRequest): Promise<APIResponseV3<any>>;
66
- /** Query order history. The endpoint only supports up to 30 days of queried records */
67
- getHistoricOrders(params: USDCOptionsHistoricOrdersRequest): Promise<APIResponseV3<any>>;
68
- /**
69
- * Query trade history.
70
- * The endpoint only supports up to 30 days of queried records.
71
- * An error will be returned if startTime is more than 30 days.
72
- */
73
- getOrderExecutionHistory(params: USDCOptionsOrderExecutionRequest): Promise<APIResponseV3<any>>;
74
- /** -> Account API */
75
- /** The endpoint only supports up to 30 days of queried records. An error will be returned if startTime is more than 30 days. */
76
- getTransactionLog(params: USDCTransactionLogRequest): Promise<APIResponseV3<any>>;
77
- /** Wallet info for USDC account. */
78
- getBalances(): Promise<APIResponseV3<any>>;
79
- /** Asset Info */
80
- getAssetInfo(baseCoin?: string): Promise<APIResponseV3<any>>;
81
- /**
82
- * If USDC derivatives account balance is greater than X, you can open PORTFOLIO_MARGIN,
83
- * and if it is less than Y, it will automatically close PORTFOLIO_MARGIN and change back to REGULAR_MARGIN.
84
- * X and Y will be adjusted according to operational requirements.
85
- * Rest API returns the result of checking prerequisites. You could get the real status of margin mode change by subscribing margin mode.
86
- */
87
- setMarginMode(newMarginMode: 'REGULAR_MARGIN' | 'PORTFOLIO_MARGIN'): Promise<APIResponseV3<any>>;
88
- /** Query margin mode for USDC account. */
89
- getMarginMode(): Promise<APIResponseV3<any>>;
90
- /** -> Positions API */
91
- /** Query my positions */
92
- getPositions(params: USDCPositionsRequest): Promise<APIResponseV3<any>>;
93
- /** Query Delivery History */
94
- getDeliveryHistory(params: USDCOptionsDeliveryHistoryRequest): Promise<APIResponseV3<any>>;
95
- /** Query Positions Info Upon Expiry */
96
- getPositionsInfoUponExpiry(params?: USDCOptionsPositionsInfoExpiryRequest): Promise<APIResponseV3<any>>;
97
- /** -> Market Maker Protection */
98
- /** modifyMMP */
99
- modifyMMP(params: USDCOptionsModifyMMPRequest): Promise<APIResponseV3<any>>;
100
- /** resetMMP */
101
- resetMMP(currency: string): Promise<APIResponseV3<any>>;
102
- /** queryMMPState */
103
- queryMMPState(baseCoin: string): Promise<APIResponseV3<any>>;
104
- /**
105
- *
106
- * API Data Endpoints
107
- *
108
- */
109
- getServerTime(): Promise<APIResponseWithTime>;
110
- }
@@ -1,196 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
- var __importDefault = (this && this.__importDefault) || function (mod) {
12
- return (mod && mod.__esModule) ? mod : { "default": mod };
13
- };
14
- Object.defineProperty(exports, "__esModule", { value: true });
15
- exports.USDCOptionClient = void 0;
16
- const util_1 = require("./util");
17
- const BaseRestClient_1 = __importDefault(require("./util/BaseRestClient"));
18
- /**
19
- * REST API client for USDC Option APIs
20
- *
21
- * @deprecated WARNING: V1/V2 private endpoints (Rest API & Websocket Stream) for mainnet
22
- * will be switched off gradually from 30 Oct 2023 UTC, so they are not promised a stability.
23
- * Please note that you are at your own risk of using old endpoints going forward, and please move to V5 ASAP.
24
- */
25
- class USDCOptionClient extends BaseRestClient_1.default {
26
- getClientType() {
27
- return util_1.REST_CLIENT_TYPE_ENUM.v3;
28
- }
29
- fetchServerTime() {
30
- return __awaiter(this, void 0, void 0, function* () {
31
- const res = yield this.getServerTime();
32
- return Number(res.time_now);
33
- });
34
- }
35
- /**
36
- *
37
- * Market Data Endpoints
38
- *
39
- */
40
- /** Query order book info. Each side has a depth of 25 orders. */
41
- getOrderBook(symbol) {
42
- return this.get('/option/usdc/openapi/public/v1/order-book', { symbol });
43
- }
44
- /** Fetch trading rules (such as min/max qty). Query for all if blank. */
45
- getContractInfo(params) {
46
- return this.get('/option/usdc/openapi/public/v1/symbols', params);
47
- }
48
- /** Get a symbol price/statistics ticker */
49
- getSymbolTicker(symbol) {
50
- return this.get('/option/usdc/openapi/public/v1/tick', { symbol });
51
- }
52
- /** Get delivery information */
53
- getDeliveryPrice(params) {
54
- return this.get('/option/usdc/openapi/public/v1/delivery-price', params);
55
- }
56
- /** Returned records are Taker Buy in default. */
57
- getLast500Trades(params) {
58
- return this.get('/option/usdc/openapi/public/v1/query-trade-latest', params);
59
- }
60
- /**
61
- * The data is in hourly.
62
- * If time field is not passed, it returns the recent 1 hour data by default.
63
- * It could be any timeframe by inputting startTime & endTime, but it must satisfy [endTime - startTime] <= 30 days.
64
- * It returns all data in 2 years when startTime & endTime are not passed.
65
- * Both startTime & endTime entered together or both are left blank
66
- */
67
- getHistoricalVolatility(params) {
68
- return this.get('/option/usdc/openapi/public/v1/query-historical-volatility', params);
69
- }
70
- /**
71
- *
72
- * Account Data Endpoints
73
- *
74
- */
75
- /** -> Order API */
76
- /**
77
- * Place an order using the USDC Derivatives Account.
78
- * The request status can be queried in real-time.
79
- * The response parameters must be queried through a query or a WebSocket response.
80
- */
81
- submitOrder(params) {
82
- return this.postPrivate('/option/usdc/openapi/private/v1/place-order', params);
83
- }
84
- /**
85
- * Each request supports a max. of four orders. The reduceOnly parameter should be separate and unique for each order in the request.
86
- */
87
- batchSubmitOrders(orderRequest) {
88
- return this.postPrivate('/option/usdc/openapi/private/v1/batch-place-orders', { orderRequest });
89
- }
90
- /** For Options, at least one of the three parameters — price, quantity or implied volatility — must be input. */
91
- modifyOrder(params) {
92
- return this.postPrivate('/option/usdc/openapi/private/v1/replace-order', params);
93
- }
94
- /** Each request supports a max. of four orders. The reduceOnly parameter should be separate and unique for each order in the request. */
95
- batchModifyOrders(replaceOrderRequest) {
96
- return this.postPrivate('/option/usdc/openapi/private/v1/batch-replace-orders', { replaceOrderRequest });
97
- }
98
- /** Cancel order */
99
- cancelOrder(params) {
100
- return this.postPrivate('/option/usdc/openapi/private/v1/cancel-order', params);
101
- }
102
- /** Batch cancel orders */
103
- batchCancelOrders(cancelRequest) {
104
- return this.postPrivate('/option/usdc/openapi/private/v1/batch-cancel-orders', { cancelRequest });
105
- }
106
- /** This is used to cancel all active orders. The real-time response indicates whether the request is successful, depending on retCode. */
107
- cancelActiveOrders(params) {
108
- return this.postPrivate('/option/usdc/openapi/private/v1/cancel-all', params);
109
- }
110
- /** Query Unfilled/Partially Filled Orders(real-time), up to last 7 days of partially filled/unfilled orders */
111
- getActiveRealtimeOrders(params) {
112
- return this.getPrivate('/option/usdc/openapi/private/v1/trade/query-active-orders', params);
113
- }
114
- /** Query Unfilled/Partially Filled Orders */
115
- getActiveOrders(params) {
116
- return this.postPrivate('/option/usdc/openapi/private/v1/query-active-orders', params);
117
- }
118
- /** Query order history. The endpoint only supports up to 30 days of queried records */
119
- getHistoricOrders(params) {
120
- return this.postPrivate('/option/usdc/openapi/private/v1/query-order-history', params);
121
- }
122
- /**
123
- * Query trade history.
124
- * The endpoint only supports up to 30 days of queried records.
125
- * An error will be returned if startTime is more than 30 days.
126
- */
127
- getOrderExecutionHistory(params) {
128
- return this.postPrivate('/option/usdc/openapi/private/v1/execution-list', params);
129
- }
130
- /** -> Account API */
131
- /** The endpoint only supports up to 30 days of queried records. An error will be returned if startTime is more than 30 days. */
132
- getTransactionLog(params) {
133
- return this.postPrivate('/option/usdc/openapi/private/v1/query-transaction-log', params);
134
- }
135
- /** Wallet info for USDC account. */
136
- getBalances() {
137
- return this.postPrivate('/option/usdc/openapi/private/v1/query-wallet-balance');
138
- }
139
- /** Asset Info */
140
- getAssetInfo(baseCoin) {
141
- return this.postPrivate('/option/usdc/openapi/private/v1/query-asset-info', { baseCoin });
142
- }
143
- /**
144
- * If USDC derivatives account balance is greater than X, you can open PORTFOLIO_MARGIN,
145
- * and if it is less than Y, it will automatically close PORTFOLIO_MARGIN and change back to REGULAR_MARGIN.
146
- * X and Y will be adjusted according to operational requirements.
147
- * Rest API returns the result of checking prerequisites. You could get the real status of margin mode change by subscribing margin mode.
148
- */
149
- setMarginMode(newMarginMode) {
150
- return this.postPrivate('/option/usdc/private/asset/account/setMarginMode', { setMarginMode: newMarginMode });
151
- }
152
- /** Query margin mode for USDC account. */
153
- getMarginMode() {
154
- return this.postPrivate('/option/usdc/openapi/private/v1/query-margin-info');
155
- }
156
- /** -> Positions API */
157
- /** Query my positions */
158
- getPositions(params) {
159
- return this.postPrivate('/option/usdc/openapi/private/v1/query-position', params);
160
- }
161
- /** Query Delivery History */
162
- getDeliveryHistory(params) {
163
- return this.postPrivate('/option/usdc/openapi/private/v1/query-delivery-list', params);
164
- }
165
- /** Query Positions Info Upon Expiry */
166
- getPositionsInfoUponExpiry(params) {
167
- return this.postPrivate('/option/usdc/openapi/private/v1/query-position-exp-date', params);
168
- }
169
- /** -> Market Maker Protection */
170
- /** modifyMMP */
171
- modifyMMP(params) {
172
- return this.postPrivate('/option/usdc/openapi/private/v1/mmp-modify', params);
173
- }
174
- /** resetMMP */
175
- resetMMP(currency) {
176
- return this.postPrivate('/option/usdc/openapi/private/v1/mmp-reset', {
177
- currency,
178
- });
179
- }
180
- /** queryMMPState */
181
- queryMMPState(baseCoin) {
182
- return this.postPrivate('/option/usdc/openapi/private/v1/get-mmp-state', {
183
- baseCoin,
184
- });
185
- }
186
- /**
187
- *
188
- * API Data Endpoints
189
- *
190
- */
191
- getServerTime() {
192
- return this.get('/v2/public/time');
193
- }
194
- }
195
- exports.USDCOptionClient = USDCOptionClient;
196
- //# sourceMappingURL=usdc-option-client.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"usdc-option-client.js","sourceRoot":"","sources":["../src/usdc-option-client.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAsBA,iCAA+C;AAC/C,2EAAmD;AAEnD;;;;;;GAMG;AACH,MAAa,gBAAiB,SAAQ,wBAAc;IAClD,aAAa;QACX,OAAO,4BAAqB,CAAC,EAAE,CAAC;IAClC,CAAC;IAEK,eAAe;;YACnB,MAAM,GAAG,GAAG,MAAM,IAAI,CAAC,aAAa,EAAE,CAAC;YACvC,OAAO,MAAM,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;QAC9B,CAAC;KAAA;IAED;;;;OAIG;IAEH,iEAAiE;IACjE,YAAY,CAAC,MAAc;QACzB,OAAO,IAAI,CAAC,GAAG,CAAC,2CAA2C,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;IAC3E,CAAC;IAED,yEAAyE;IACzE,eAAe,CACb,MAAuC;QAEvC,OAAO,IAAI,CAAC,GAAG,CAAC,wCAAwC,EAAE,MAAM,CAAC,CAAC;IACpE,CAAC;IAED,2CAA2C;IAC3C,eAAe,CAAC,MAAc;QAC5B,OAAO,IAAI,CAAC,GAAG,CAAC,qCAAqC,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC;IACrE,CAAC;IAED,+BAA+B;IAC/B,gBAAgB,CACd,MAAwC;QAExC,OAAO,IAAI,CAAC,GAAG,CAAC,+CAA+C,EAAE,MAAM,CAAC,CAAC;IA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