kucoin-api 1.0.22 → 2.0.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.
package/README.md CHANGED
@@ -64,7 +64,7 @@ Check out my related JavaScript/TypeScript/Node.js projects:
64
64
 
65
65
  Most methods accept JS objects. These can be populated using parameters specified by Kucoin's API documentation.
66
66
 
67
- - [Kucoin API Documentation](https://www.kucoin.com/docs/beginners/introduction)
67
+ - [Kucoin API Documentation](https://www.kucoin.com/docs-new/introduction)
68
68
  - Node.js Quick Start Guides
69
69
  - [Spot Node.js Kucoin Quick Start Guide](./examples/kucoin-SPOT-examples-nodejs.md)
70
70
  - [Futures Node.js Kucoin Quick Start Guide](./examples/kucoin-FUTURES-examples-nodejs.md)
@@ -102,7 +102,7 @@ const client = new SpotClient({
102
102
  });
103
103
 
104
104
  try {
105
- const spotBuyResult = await client.submitOrder({
105
+ const spotBuyResult = await client.submitHFOrder({
106
106
  clientOid: client.generateNewOrderID(),
107
107
  side: 'buy',
108
108
  type: 'market',
@@ -111,7 +111,7 @@ try {
111
111
  });
112
112
  console.log('spotBuy ', JSON.stringify(spotBuyResult, null, 2));
113
113
 
114
- const spotSellResult = await client.submitOrder({
114
+ const spotSellResult = await client.submitHFOrder({
115
115
  clientOid: client.generateNewOrderID(),
116
116
  side: 'sell',
117
117
  type: 'market',
@@ -1,8 +1,8 @@
1
1
  import { AxiosRequestConfig } from 'axios';
2
2
  import { BaseRestClient } from './lib/BaseRestClient.js';
3
3
  import { RestClientOptions, RestClientType } from './lib/requestUtils.js';
4
- import { AccountFillsRequest, BatchCancelOrdersRequest, CreateSubAPIRequest, DeleteSubAPIRequest, GetFundingHistoryRequest, GetFundingRatesRequest, GetInterestRatesRequest, GetKlinesRequest, GetOrdersRequest, GetStopOrdersRequest, GetSubAPIsRequest, GetTransactionsRequest, GetTransfersRequest, MaxOpenSizeRequest, Order, SLTPOrder, SubmitTransfer, UpdateSubAPIRequest } from './types/request/futures.types.js';
5
- import { AccountBalance, AccountSummary, AddMargin, BatchCancelOrderResult, CreateSubAccountAPI, FullOrderBookDetail, FuturesAccountFundingRateHistory, FuturesAccountTransaction, FuturesActiveOrder, FuturesClosedPositions, FuturesCurrentFundingRate, FuturesFill, FuturesFills, FuturesHistoricFundingRate, FuturesKline, FuturesMarkPrice, FuturesOrder, FuturesOrders, FuturesPosition, FuturesRiskLimit, FuturesSymbolInfo, FuturesTransferRecords, IndexListItem, InterestRateItem, MarketTradeDetail, MaxOpenSize, PremiumIndexItem, SubAccountAPI, SubBalance, SubmitMultipleOrdersFuturesResponse, TickerDetail, TransferDetail, UpdateSubAccountAPI } from './types/response/futures.types.js';
4
+ import { AccountFillsRequest, BatchCancelOrdersRequest, GetFundingHistoryRequest, GetFundingRatesRequest, GetInterestRatesRequest, GetKlinesRequest, GetOrdersRequest, GetStopOrdersRequest, GetTransactionsRequest, MaxOpenSizeRequest, Order, SLTPOrder } from './types/request/futures.types.js';
5
+ import { AccountBalance, AccountSummary, AddMargin, BatchCancelOrderResult, FullOrderBookDetail, FuturesAccountFundingRateHistory, FuturesAccountTransaction, FuturesActiveOrder, FuturesClosedPositions, FuturesCurrentFundingRate, FuturesFill, FuturesFills, FuturesHistoricFundingRate, FuturesKline, FuturesMarkPrice, FuturesOrder, FuturesOrders, FuturesPosition, FuturesRiskLimit, FuturesSymbolInfo, IndexListItem, InterestRateItem, MarketTradeDetail, MaxOpenSize, PremiumIndexItem, SubBalance, SubmitMultipleOrdersFuturesResponse, TickerDetail } from './types/response/futures.types.js';
6
6
  import { APISuccessResponse, ServiceStatus } from './types/response/shared.types.js';
7
7
  import { WsConnectionInfo } from './types/response/ws.js';
8
8
  /**
@@ -17,32 +17,35 @@ export declare class FuturesClient extends BaseRestClient {
17
17
  *
18
18
  */
19
19
  generateNewOrderID(): string;
20
- getServerTime(): Promise<APISuccessResponse<number>>;
21
- getServiceStatus(): Promise<APISuccessResponse<ServiceStatus>>;
22
20
  /**
23
- * REST - ACCOUNT - BASIC INFO
21
+ *
22
+ * REST - ACCOUNT INFO - Account & Funding
23
+ *
24
+ */
25
+ /**
26
+ * Get Account - Futures
27
+ * Request via this endpoint to get the info of the futures account.
28
+ */
29
+ getBalance(params?: {
30
+ currency?: string;
31
+ }): Promise<APISuccessResponse<AccountBalance>>;
32
+ /**
24
33
  * Get Account Ledgers - Futures
34
+ * This interface can query the ledger records of the futures business line
25
35
  */
26
36
  getTransactions(params: GetTransactionsRequest): Promise<APISuccessResponse<{
27
37
  hasMore: boolean;
28
38
  dataList: FuturesAccountTransaction[];
29
39
  }>>;
30
40
  /**
31
- * REST - ACCOUNT - SUBACCOUNT API
41
+ *
42
+ * REST - ACCOUNT INFO - Sub Account
43
+ *
32
44
  */
33
- getSubAPIs(params: GetSubAPIsRequest): Promise<APISuccessResponse<SubAccountAPI[]>>;
34
- createSubAPI(params: CreateSubAPIRequest): Promise<APISuccessResponse<CreateSubAccountAPI>>;
35
- updateSubAPI(params: UpdateSubAPIRequest): Promise<APISuccessResponse<UpdateSubAccountAPI>>;
36
- deleteSubAPI(params: DeleteSubAPIRequest): Promise<APISuccessResponse<{
37
- subName: string;
38
- apiKey: string;
39
- }>>;
40
45
  /**
41
- * REST - FUNDING - FUNDING OVERVIEW
46
+ * Get SubAccount List - Futures Balance(V2)
47
+ * This endpoint can be used to get Futures sub-account information.
42
48
  */
43
- getBalance(params?: {
44
- currency?: string;
45
- }): Promise<APISuccessResponse<AccountBalance>>;
46
49
  getSubBalances(params?: {
47
50
  currency?: string;
48
51
  }): Promise<APISuccessResponse<{
@@ -50,13 +53,13 @@ export declare class FuturesClient extends BaseRestClient {
50
53
  accounts: SubBalance[];
51
54
  }>>;
52
55
  /**
53
- * REST - FUNDING - TRANSFER
56
+ *
57
+ * REST - Account Info - Trade Fee
58
+ *
54
59
  */
55
- submitTransferOut(params: SubmitTransfer): Promise<Promise<APISuccessResponse<TransferDetail>>>;
56
- submitTransferIn(params: SubmitTransfer): Promise<any>;
57
- getTransfers(params: GetTransfersRequest): Promise<APISuccessResponse<FuturesTransferRecords>>;
58
60
  /**
59
- * REST - FUNDING - TRADE FEE
61
+ * Get Actual Fee - Futures
62
+ * This interface is for the actual futures fee rate of the trading pair. The fee rate of your sub-account is the same as that of the master account.
60
63
  */
61
64
  getTradingPairFee(params: {
62
65
  symbol: string;
@@ -67,143 +70,293 @@ export declare class FuturesClient extends BaseRestClient {
67
70
  }>>;
68
71
  /**
69
72
  *
70
- * REST - FUTURES TRADING - Market Data
73
+ * REST - Futures Trading - Market Data
71
74
  *
72
75
  */
73
- getSymbols(): Promise<APISuccessResponse<FuturesSymbolInfo[]>>;
76
+ /**
77
+ * Get Symbol
78
+ * Get information of specified contracts that can be traded.
79
+ * This API will return a list of tradable contracts, including some key parameters of the contract such as the symbol name, tick size, mark price,etc.
80
+ */
74
81
  getSymbol(params: {
75
82
  symbol: string;
76
83
  }): Promise<APISuccessResponse<FuturesSymbolInfo>>;
84
+ /**
85
+ * Get Symbol
86
+ * Get information of specified contracts that can be traded.
87
+ * This API will return a list of tradable contracts, including some key parameters of the contract such as the symbol name, tick size, mark price,etc.
88
+ */
89
+ getSymbols(): Promise<APISuccessResponse<FuturesSymbolInfo[]>>;
90
+ /**
91
+ * Get Ticker
92
+ * This endpoint returns "last traded price/size"、"best bid/ask price/size" etc. of a single symbol.
93
+ */
77
94
  getTicker(params: {
78
95
  symbol: string;
79
96
  }): Promise<APISuccessResponse<TickerDetail>>;
97
+ /**
98
+ * Get All Tickers
99
+ * This endpoint returns "last traded price/size"、"best bid/ask price/size" etc. of all symbol.
100
+ */
80
101
  getTickers(): Promise<APISuccessResponse<TickerDetail[]>>;
102
+ /**
103
+ * Get Full OrderBook
104
+ * Query for Full orderbook depth data. (aggregated by price)
105
+ */
81
106
  getFullOrderBookLevel2(params: {
82
107
  symbol: string;
83
108
  }): Promise<APISuccessResponse<FullOrderBookDetail>>;
109
+ /**
110
+ * Get Part OrderBook
111
+ * Query for part orderbook depth data. (aggregated by price)
112
+ */
84
113
  getPartOrderBookLevel2Depth20(params: {
85
114
  symbol: string;
86
115
  }): Promise<APISuccessResponse<FullOrderBookDetail>>;
116
+ /**
117
+ * Get Part OrderBook
118
+ * Query for part orderbook depth data. (aggregated by price)
119
+ */
87
120
  getPartOrderBookLevel2Depth100(params: {
88
121
  symbol: string;
89
122
  }): Promise<APISuccessResponse<FullOrderBookDetail>>;
123
+ /**
124
+ * Get Trade History
125
+ * Request via this endpoint to get the trade history of the specified symbol, the returned quantity is the last 100 transaction records.
126
+ */
90
127
  getMarketTrades(params: {
91
128
  symbol: string;
92
129
  }): Promise<APISuccessResponse<MarketTradeDetail>>;
130
+ /**
131
+ * Get Klines
132
+ * Get the Kline of the symbol. Data are returned in grouped buckets based on requested type.
133
+ */
93
134
  getKlines(params: GetKlinesRequest): Promise<APISuccessResponse<FuturesKline[]>>;
94
- getInterestRates(params: GetInterestRatesRequest): Promise<APISuccessResponse<{
95
- dataList: InterestRateItem[];
96
- hasMore: boolean;
97
- }>>;
135
+ /**
136
+ * Get Mark Price
137
+ * Get the mark price of the symbol.
138
+ */
139
+ getMarkPrice(params: {
140
+ symbol: string;
141
+ }): Promise<APISuccessResponse<FuturesMarkPrice>>;
142
+ /**
143
+ * Get Spot Index Price
144
+ * This endpoint returns the index price of the specified symbol.
145
+ */
98
146
  getIndex(params: GetInterestRatesRequest): Promise<APISuccessResponse<{
99
147
  dataList: IndexListItem[];
100
148
  hasMore: boolean;
101
149
  }>>;
102
- getMarkPrice(params: {
103
- symbol: string;
104
- }): Promise<APISuccessResponse<FuturesMarkPrice>>;
150
+ /**
151
+ * Get Interest Rate Index
152
+ * This endpoint returns the interest rate index of the specified symbol.
153
+ */
154
+ getInterestRates(params: GetInterestRatesRequest): Promise<APISuccessResponse<{
155
+ dataList: InterestRateItem[];
156
+ hasMore: boolean;
157
+ }>>;
158
+ /**
159
+ * Get Premium Index
160
+ * This endpoint returns the premium index of the specified symbol.
161
+ */
105
162
  getPremiumIndex(params: GetInterestRatesRequest): Promise<APISuccessResponse<{
106
163
  dataList: PremiumIndexItem[];
107
164
  hasMore: boolean;
108
165
  }>>;
166
+ /**
167
+ * Get 24hr Stats
168
+ * Get the statistics of the platform futures trading volume in the last 24 hours.
169
+ */
109
170
  get24HourTransactionVolume(): Promise<APISuccessResponse<{
110
171
  turnoverOf24h: number;
111
172
  }>>;
173
+ /**
174
+ * Get Server Time
175
+ * Get the API server time. This is the Unix timestamp.
176
+ */
177
+ getServerTime(): Promise<APISuccessResponse<number>>;
178
+ /**
179
+ * Get Service Status
180
+ * This endpoint returns the status of the API service.
181
+ */
182
+ getServiceStatus(): Promise<APISuccessResponse<ServiceStatus>>;
112
183
  /**
113
184
  *
114
- * REST - FUTURES TRADING - Orders
185
+ * REST - Futures Trading - Orders
115
186
  *
116
187
  */
188
+ /**
189
+ * Add Order
190
+ * Place order to the futures trading system
191
+ */
117
192
  submitOrder(params: Order): Promise<APISuccessResponse<{
118
193
  orderId?: string;
119
194
  clientOid?: string;
120
195
  }>>;
121
- submitNewOrderTest(): Promise<{
196
+ /**
197
+ * Add Order Test
198
+ * Order test endpoint, the request parameters and return parameters of this endpoint are exactly the same as the order endpoint, and can be used to verify whether the signature is correct and other operations.
199
+ */
200
+ submitNewOrderTest(params: Order): Promise<{
122
201
  orderId?: string;
123
202
  clientOid?: string;
124
203
  }>;
204
+ /**
205
+ * Batch Add Orders
206
+ * Place multiple order to the futures trading system
207
+ */
208
+ submitMultipleOrders(params: Order[]): Promise<APISuccessResponse<SubmitMultipleOrdersFuturesResponse[]>>;
209
+ /**
210
+ * Add Take Profit And Stop Loss Order
211
+ * Place take profit and stop loss order supports both take-profit and stop-loss functions, and other functions are exactly the same as the place order interface.
212
+ */
213
+ submitSLTPOrder(params: SLTPOrder): Promise<APISuccessResponse<{
214
+ orderId?: string;
215
+ clientOid?: string;
216
+ }>>;
217
+ /**
218
+ * Cancel Order By OrderId
219
+ * Cancel an order (including a stop order).
220
+ */
125
221
  cancelOrderById(params: {
126
222
  orderId: string;
127
223
  }): Promise<APISuccessResponse<{
128
224
  cancelledOrderIds: string[];
129
225
  }>>;
226
+ /**
227
+ * Cancel Order By Client Order Id
228
+ * Cancel an order (including a stop order) by client order id.
229
+ */
130
230
  cancelOrderByClientOid(params: {
131
231
  clientOid: string;
132
232
  }): Promise<APISuccessResponse<{
133
233
  clientOid: string;
134
234
  }>>;
235
+ /**
236
+ * Batch Cancel Orders
237
+ * Cancel multiple orders.
238
+ */
135
239
  batchCancelOrders(params: BatchCancelOrdersRequest): Promise<APISuccessResponse<{
136
240
  data: BatchCancelOrderResult[];
137
241
  }>>;
138
- submitSLTPOrder(params: SLTPOrder): Promise<APISuccessResponse<{
139
- orderId?: string;
140
- clientOid?: string;
141
- }>>;
142
- submitMultipleOrders(params: Order[]): Promise<APISuccessResponse<SubmitMultipleOrdersFuturesResponse[]>>;
143
242
  /**
144
- * @deprecated, use cancelAllOrdersV3 instead
243
+ * Cancel All Orders
244
+ * Using this endpoint, all open orders (excluding stop orders) can be canceled in batches.
145
245
  */
146
- cancelAllOrders(params?: {
147
- symbol?: string;
148
- }): Promise<APISuccessResponse<{
149
- cancelledOrderIds: string[];
150
- }>>;
151
246
  cancelAllOrdersV3(params: {
152
247
  symbol: string;
153
248
  }): Promise<APISuccessResponse<{
154
249
  cancelledOrderIds: string[];
155
250
  }>>;
251
+ /**
252
+ * Cancel All Stop orders
253
+ * Using this endpoint, all untriggered stop orders can be canceled in batches.
254
+ */
156
255
  cancelAllStopOrders(params?: {
157
256
  symbol?: string;
158
257
  }): Promise<APISuccessResponse<{
159
258
  cancelledOrderIds: string[];
160
259
  }>>;
161
- getOrders(params?: GetOrdersRequest): Promise<APISuccessResponse<FuturesOrders>>;
162
- getStopOrders(params?: GetStopOrdersRequest): Promise<APISuccessResponse<FuturesOrders>>;
163
- getRecentOrders(params?: {
164
- symbol?: string;
165
- }): Promise<APISuccessResponse<FuturesOrder[]>>;
260
+ /**
261
+ * Get Order By OrderId
262
+ * Get order details by order id.
263
+ */
166
264
  getOrderByOrderId(params: {
167
265
  orderId: string;
168
266
  }): Promise<APISuccessResponse<FuturesOrder>>;
267
+ /**
268
+ * Get Order By Client Order Id
269
+ * Get order details by client order id.
270
+ */
169
271
  getOrderByClientOrderId(params: {
170
272
  clientOid: string;
171
273
  }): Promise<APISuccessResponse<FuturesOrder>>;
172
274
  /**
173
- *
174
- * REST - FUTURES TRADING - Fills
175
- *
275
+ * Get Order List
276
+ * List your current orders. Any limit order on the exchange order book is in active status.
176
277
  */
278
+ getOrders(params?: GetOrdersRequest): Promise<APISuccessResponse<FuturesOrders>>;
177
279
  /**
178
- * Get a list of recent fills.
179
- *
180
- * If you need to get your recent trade history with low latency, please query endpoint Get List of Orders Completed in 24h.
181
- * The requested data is not real-time.
280
+ * Get Recent Closed Orders
281
+ * Get a list of recent 1000 closed orders in the last 24 hours.
182
282
  */
183
- getFills(params?: AccountFillsRequest): Promise<APISuccessResponse<FuturesFills>>;
283
+ getRecentOrders(params?: {
284
+ symbol?: string;
285
+ }): Promise<APISuccessResponse<FuturesOrder[]>>;
184
286
  /**
287
+ * Get Stop Order List
288
+ * Get the un-triggered stop orders list. Stop orders that have been triggered can be queried through the general order interface
289
+ */
290
+ getStopOrders(params?: GetStopOrdersRequest): Promise<APISuccessResponse<FuturesOrders>>;
291
+ /**
292
+ * Get Open Order Value
293
+ * You can query this endpoint to get the the total number and value of the all your active orders.
294
+ */
295
+ getOpenOrderStatistics(params: {
296
+ symbol: string;
297
+ }): Promise<APISuccessResponse<FuturesActiveOrder>>;
298
+ /**
299
+ * Get Recent Trade History
185
300
  * Get a list of recent 1000 fills in the last 24 hours.
186
- *
187
- * If you need to get your recent traded order history with low latency, you may query this endpoint.
188
301
  */
189
302
  getRecentFills(params?: {
190
303
  symbol?: string;
191
304
  }): Promise<APISuccessResponse<FuturesFill[]>>;
192
- getOpenOrderStatistics(params: {
193
- symbol: string;
194
- }): Promise<APISuccessResponse<FuturesActiveOrder>>;
305
+ /**
306
+ * Get Trade History
307
+ * Get a list of recent fills.
308
+ * If you need to get your recent trade history with low latency, please query endpoint Get List of Orders Completed in 24h. The requested data is not real-time.
309
+ */
310
+ getFills(params?: AccountFillsRequest): Promise<APISuccessResponse<FuturesFills>>;
195
311
  /**
196
312
  *
197
- * REST - FUTURES TRADING - Positions
313
+ * REST - Futures Trading - Positions
198
314
  *
199
315
  */
316
+ /**
317
+ * Get Margin Mode
318
+ * This interface can query the margin mode of the current symbol.
319
+ */
320
+ getMarginMode(params: {
321
+ symbol: string;
322
+ }): Promise<APISuccessResponse<{
323
+ symbol: string;
324
+ marginMode: 'ISOLATED' | 'CROSS';
325
+ }>>;
326
+ /**
327
+ * Switch Margin Mode
328
+ * Modify the margin mode of the current symbol.
329
+ */
330
+ updateMarginMode(params: {
331
+ symbol: string;
332
+ marginMode: 'ISOLATED' | 'CROSS';
333
+ }): Promise<APISuccessResponse<{
334
+ symbol: string;
335
+ marginMode: 'ISOLATED' | 'CROSS';
336
+ }>>;
337
+ /**
338
+ * Get Max Open Size
339
+ * Get Maximum Open Position Size.
340
+ */
200
341
  getMaxOpenSize(params: MaxOpenSizeRequest): Promise<APISuccessResponse<MaxOpenSize>>;
342
+ /**
343
+ * Get Position Details
344
+ * Get the position details of a specified position.
345
+ */
201
346
  getPosition(params: {
202
347
  symbol: string;
203
348
  }): Promise<APISuccessResponse<FuturesPosition>>;
349
+ /**
350
+ * Get Position List
351
+ * Get the position details of a specified position.
352
+ */
204
353
  getPositions(params?: {
205
354
  currency?: string;
206
355
  }): Promise<APISuccessResponse<FuturesPosition[]>>;
356
+ /**
357
+ * Get Positions History
358
+ * This interface can query position history information records.
359
+ */
207
360
  getHistoryPositions(params?: {
208
361
  symbol?: string;
209
362
  from?: number;
@@ -211,44 +364,27 @@ export declare class FuturesClient extends BaseRestClient {
211
364
  limit?: number;
212
365
  pageId?: number;
213
366
  }): Promise<APISuccessResponse<FuturesClosedPositions>>;
214
- updateAutoDepositStatus(params: {
215
- symbol: string;
216
- status: boolean;
217
- }): Promise<APISuccessResponse<boolean>>;
367
+ /**
368
+ * Get Max Withdraw Margin
369
+ * This interface can query the maximum amount of margin that the current position supports withdrawal.
370
+ */
218
371
  getMaxWithdrawMargin(params: {
219
372
  symbol: string;
220
373
  }): Promise<APISuccessResponse<number>>;
221
- withdrawMargin(params: {
222
- symbol: string;
223
- withdrawAmount: string;
224
- }): Promise<APISuccessResponse<{
225
- sybmol: string;
226
- withdrawAmount: number;
227
- }>>;
228
- depositMargin(params: {
229
- symbol: string;
230
- margin: number;
231
- bizNo: string;
232
- }): Promise<APISuccessResponse<AddMargin>>;
233
- getMarginMode(params: {
234
- symbol: string;
235
- }): Promise<APISuccessResponse<{
236
- symbol: string;
237
- marginMode: 'ISOLATED' | 'CROSS';
238
- }>>;
239
- updateMarginMode(params: {
240
- symbol: string;
241
- marginMode: 'ISOLATED' | 'CROSS';
242
- }): Promise<APISuccessResponse<{
243
- symbol: string;
244
- marginMode: 'ISOLATED' | 'CROSS';
245
- }>>;
374
+ /**
375
+ * Get Cross Margin Leverage
376
+ * This interface can query the current symbol’s cross-margin leverage multiple.
377
+ */
246
378
  getCrossMarginLeverage(params: {
247
379
  symbol: string;
248
380
  }): Promise<APISuccessResponse<{
249
381
  symbol: string;
250
382
  leverage: string;
251
383
  }>>;
384
+ /**
385
+ * Modify Cross Margin Leverage
386
+ * This interface can modify the current symbol’s cross-margin leverage multiple.
387
+ */
252
388
  changeCrossMarginLeverage(params: {
253
389
  symbol: string;
254
390
  leverage: string;
@@ -257,26 +393,61 @@ export declare class FuturesClient extends BaseRestClient {
257
393
  leverage: string;
258
394
  }>>;
259
395
  /**
260
- *
261
- * REST - FUTURES TRADING - Risk limit
262
- *
396
+ * Add Isolated Margin
397
+ * Add Isolated Margin Manually.
398
+ */
399
+ depositMargin(params: {
400
+ symbol: string;
401
+ margin: number;
402
+ bizNo: string;
403
+ }): Promise<APISuccessResponse<AddMargin>>;
404
+ /**
405
+ * Remove Isolated Margin
406
+ * Remove Isolated Margin Manually.
407
+ */
408
+ withdrawMargin(params: {
409
+ symbol: string;
410
+ withdrawAmount: string;
411
+ }): Promise<APISuccessResponse<{
412
+ sybmol: string;
413
+ withdrawAmount: number;
414
+ }>>;
415
+ /**
416
+ * Get Isolated Margin Risk Limit
417
+ * This interface can be used to obtain information about risk limit level of a specific contract(Only valid for isolated Margin).
263
418
  */
264
419
  getRiskLimitLevel(params: {
265
420
  symbol: string;
266
421
  }): Promise<APISuccessResponse<FuturesRiskLimit[]>>;
422
+ /**
423
+ * Modify Isolated Margin Risk Limit
424
+ * This interface is for the adjustment of the risk limit level(Only valid for isolated Margin).
425
+ */
267
426
  updateRiskLimitLevel(params: {
268
427
  symbol: string;
269
428
  level: number;
270
429
  }): Promise<any>;
271
430
  /**
272
431
  *
273
- * REST - FUTURES TRADING - Funding fees
432
+ * REST - Futures Trading - Funding Fees
274
433
  *
275
434
  */
435
+ /**
436
+ * Get Current Funding Rate
437
+ * This interface can be used to obtain the current funding rate of the specified symbol.
438
+ */
276
439
  getFundingRate(params: {
277
440
  symbol: string;
278
441
  }): Promise<APISuccessResponse<FuturesCurrentFundingRate>>;
442
+ /**
443
+ * Get Public Funding History
444
+ * Query the funding rate at each settlement time point within a certain time range of the corresponding contract
445
+ */
279
446
  getFundingRates(params: GetFundingRatesRequest): Promise<APISuccessResponse<FuturesHistoricFundingRate[]>>;
447
+ /**
448
+ * Get Private Funding History
449
+ * Submit request to get the funding history.
450
+ */
280
451
  getFundingHistory(params: GetFundingHistoryRequest): Promise<APISuccessResponse<{
281
452
  dataList: FuturesAccountFundingRateHistory[];
282
453
  hasMore: boolean;
@@ -298,4 +469,39 @@ export declare class FuturesClient extends BaseRestClient {
298
469
  */
299
470
  getPublicWSConnectionToken(): Promise<APISuccessResponse<WsConnectionInfo>>;
300
471
  getPrivateWSConnectionToken(): Promise<APISuccessResponse<WsConnectionInfo>>;
472
+ /**
473
+ * @deprecated - please use universal transfer from SpotClient
474
+ */
475
+ submitTransferOut(params: {
476
+ currency: string;
477
+ amount: number;
478
+ recAccountType: 'MAIN' | 'TRADE';
479
+ }): Promise<APISuccessResponse<any>>;
480
+ /**
481
+ * @deprecated - please use universal transfer from SpotClient
482
+ */
483
+ submitTransferIn(params: {
484
+ currency: string;
485
+ amount: number;
486
+ payAccountType: 'MAIN' | 'TRADE';
487
+ }): Promise<APISuccessResponse<any>>;
488
+ /**
489
+ * @deprecated - please use universal transfer from SpotClient
490
+ */
491
+ getTransfers(params?: {
492
+ currency?: string;
493
+ type?: 'MAIN' | 'TRADE' | 'MARGIN' | 'ISOLATED';
494
+ tag?: string[];
495
+ startAt?: number;
496
+ endAt?: number;
497
+ currentPage?: number;
498
+ pageSize?: number;
499
+ }): Promise<APISuccessResponse<any>>;
500
+ /**
501
+ * @deprecated - please use updateMarginMode() instead
502
+ */
503
+ updateAutoDepositStatus(params: {
504
+ symbol: string;
505
+ status: boolean;
506
+ }): Promise<APISuccessResponse<any>>;
301
507
  }