Skip to content

Commit 4e5309c

Browse files
author
gateio
committed
update to v2.102.0
1 parent 8c4d776 commit 4e5309c

File tree

322 files changed

+1305
-947
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

322 files changed

+1305
-947
lines changed

README.md

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,17 @@
1-
## gate-api@6.100.2
1+
## gate-api@6.102.0
22

33
TypeScript NodeJS client for gate-api.
44

55
Welcome to Gate API
6-
7-
APIv4 provides spot, margin and futures trading operations. There are public APIs to retrieve the real-time market statistics, and private APIs which needs authentication to trade on user's behalf.
8-
6+
APIv4 provides operations related to spot, margin, and contract trading, including public interfaces for querying market data and authenticated private interfaces
7+
for implementing API-based automated trading.
98

109
This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
1110

12-
- API version: 4.100.2
11+
- API version: v4.102.0
1312
- Package version:
1413
- Build package: org.openapitools.codegen.languages.TypeScriptNodeClientCodegen
15-
For more information, please visit [https://www.gate.io/page/contacts](https://www.gate.io/page/contacts)
14+
For more information, please visit [https://www.gate.com/page/contacts](https://www.gate.com/page/contacts)
1615

1716
Environment
1817

@@ -136,7 +135,7 @@ Class | Method | HTTP request | Description
136135
*EarnApi* | [**listStructuredProducts**](docs/EarnApi.md#listStructuredProducts) | **GET** /earn/structured/products | Structured Product List
137136
*EarnApi* | [**listStructuredOrders**](docs/EarnApi.md#listStructuredOrders) | **GET** /earn/structured/orders | Structured Product Order List
138137
*EarnApi* | [**placeStructuredOrder**](docs/EarnApi.md#placeStructuredOrder) | **POST** /earn/structured/orders | Place Structured Product Order
139-
*EarnApi* | [**findCoin**](docs/EarnApi.md#findCoin) | **GET** /earn/staking/coins | 链上赚币币种
138+
*EarnApi* | [**findCoin**](docs/EarnApi.md#findCoin) | **GET** /earn/staking/coins | Staking Coins
140139
*EarnApi* | [**swapStakingCoin**](docs/EarnApi.md#swapStakingCoin) | **POST** /earn/staking/swap | On-chain Token Swap for Earned Coins
141140
*EarnUniApi* | [**listUniCurrencies**](docs/EarnUniApi.md#listUniCurrencies) | **GET** /earn/uni/currencies | List currencies for lending
142141
*EarnUniApi* | [**getUniCurrency**](docs/EarnUniApi.md#getUniCurrency) | **GET** /earn/uni/currencies/{currency} | Get currency detail for lending
@@ -197,6 +196,7 @@ Class | Method | HTTP request | Description
197196
*FuturesApi* | [**getFuturesFee**](docs/FuturesApi.md#getFuturesFee) | **GET** /futures/{settle}/fee | Query user trading fee rates
198197
*FuturesApi* | [**cancelBatchFutureOrders**](docs/FuturesApi.md#cancelBatchFutureOrders) | **POST** /futures/{settle}/batch_cancel_orders | Cancel a batch of orders with an ID list
199198
*FuturesApi* | [**amendBatchFutureOrders**](docs/FuturesApi.md#amendBatchFutureOrders) | **POST** /futures/{settle}/batch_amend_orders | Batch modify orders with specified IDs
199+
*FuturesApi* | [**getFuturesRiskLimitTable**](docs/FuturesApi.md#getFuturesRiskLimitTable) | **GET** /futures/{settle}/risk_limit_table | Query risk limit table by table_id
200200
*FuturesApi* | [**listPriceTriggeredOrders**](docs/FuturesApi.md#listPriceTriggeredOrders) | **GET** /futures/{settle}/price_orders | List All Price-triggered Orders
201201
*FuturesApi* | [**createPriceTriggeredOrder**](docs/FuturesApi.md#createPriceTriggeredOrder) | **POST** /futures/{settle}/price_orders | Create a price-triggered order
202202
*FuturesApi* | [**cancelPriceTriggeredOrderList**](docs/FuturesApi.md#cancelPriceTriggeredOrderList) | **DELETE** /futures/{settle}/price_orders | Cancel All Price-triggered Orders
@@ -335,7 +335,7 @@ Class | Method | HTTP request | Description
335335
*UnifiedApi* | [**setUserLeverageCurrencySetting**](docs/UnifiedApi.md#setUserLeverageCurrencySetting) | **POST** /unified/leverage/user_currency_setting | Set the loan currency leverage
336336
*UnifiedApi* | [**listUnifiedCurrencies**](docs/UnifiedApi.md#listUnifiedCurrencies) | **GET** /unified/currencies | List of loan currencies supported by unified account
337337
*UnifiedApi* | [**getHistoryLoanRate**](docs/UnifiedApi.md#getHistoryLoanRate) | **GET** /unified/history_loan_rate | get historical lending rates
338-
*UnifiedApi* | [**setUnifiedCollateral**](docs/UnifiedApi.md#setUnifiedCollateral) | **POST** /unified/collateral_currencies | 设置抵押币种
338+
*UnifiedApi* | [**setUnifiedCollateral**](docs/UnifiedApi.md#setUnifiedCollateral) | **POST** /unified/collateral_currencies | Set Collateral Currency
339339
*WalletApi* | [**listCurrencyChains**](docs/WalletApi.md#listCurrencyChains) | **GET** /wallet/currency_chains | List chains supported for specified currency
340340
*WalletApi* | [**getDepositAddress**](docs/WalletApi.md#getDepositAddress) | **GET** /wallet/deposit_address | Generate currency deposit address
341341
*WalletApi* | [**listWithdrawals**](docs/WalletApi.md#listWithdrawals) | **GET** /wallet/withdrawals | Retrieve withdrawal records
@@ -454,6 +454,7 @@ Class | Method | HTTP request | Description
454454
- [FuturesPremiumIndex](docs/FuturesPremiumIndex.md)
455455
- [FuturesPriceTrigger](docs/FuturesPriceTrigger.md)
456456
- [FuturesPriceTriggeredOrder](docs/FuturesPriceTriggeredOrder.md)
457+
- [FuturesRiskLimitTier](docs/FuturesRiskLimitTier.md)
457458
- [FuturesTicker](docs/FuturesTicker.md)
458459
- [FuturesTrade](docs/FuturesTrade.md)
459460
- [IndexConstituent](docs/IndexConstituent.md)
@@ -562,6 +563,7 @@ Class | Method | HTTP request | Description
562563
- [SubCrossMarginAccount](docs/SubCrossMarginAccount.md)
563564
- [SubUserMode](docs/SubUserMode.md)
564565
- [SwapCoin](docs/SwapCoin.md)
566+
- [SwapCoinStruct](docs/SwapCoinStruct.md)
565567
- [SystemTime](docs/SystemTime.md)
566568
- [Ticker](docs/Ticker.md)
567569
- [TotalBalance](docs/TotalBalance.md)
@@ -625,5 +627,5 @@ Class | Method | HTTP request | Description
625627

626628
- **Type**: Gate APIv4
627629

628-
https://www.gate.io/docs/apiv4/en/index.html#apiv4-signed-request-requirements
630+
https://www.gate.com/docs/apiv4/en/index.html#apiv4-signed-request-requirements
629631

api/accountApi.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
2-
* Gate API v4
3-
* Welcome to Gate API APIv4 provides spot, margin and futures trading operations. There are public APIs to retrieve the real-time market statistics, and private APIs which needs authentication to trade on user\'s behalf.
2+
* Gate API
3+
* Welcome to Gate API APIv4 provides operations related to spot, margin, and contract trading, including public interfaces for querying market data and authenticated private interfaces for implementing API-based automated trading.
44
*
55
* Contact: support@mail.gate.com
66
*
@@ -157,7 +157,7 @@ export class AccountApi {
157157
}
158158

159159
/**
160-
* Only the main account that created this STP group is allowed to list the user ID of the STP group
160+
* Only the main account that created this STP group can query the account
161161
* @summary List users of the STP group
162162
* @param stpId STP Group ID
163163
*/

api/apiClient.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
2-
* Gate API v4
3-
* Welcome to Gate API APIv4 provides spot, margin and futures trading operations. There are public APIs to retrieve the real-time market statistics, and private APIs which needs authentication to trade on user\'s behalf.
2+
* Gate API
3+
* Welcome to Gate API APIv4 provides operations related to spot, margin, and contract trading, including public interfaces for querying market data and authenticated private interfaces for implementing API-based automated trading.
44
*
55
* Contact: support@mail.gate.com
66
*

api/collateralLoanApi.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
2-
* Gate API v4
3-
* Welcome to Gate API APIv4 provides spot, margin and futures trading operations. There are public APIs to retrieve the real-time market statistics, and private APIs which needs authentication to trade on user\'s behalf.
2+
* Gate API
3+
* Welcome to Gate API APIv4 provides operations related to spot, margin, and contract trading, including public interfaces for querying market data and authenticated private interfaces for implementing API-based automated trading.
44
*
55
* Contact: support@mail.gate.com
66
*
@@ -461,7 +461,7 @@ export class CollateralLoanApi {
461461
*
462462
* @summary Query supported borrowing and collateral currencies
463463
* @param opts Optional parameters
464-
* @param opts.loanCurrency The parameter loan_currency is used to specify the borrowing currency. If loan_currency is not provided, the API will return all supported borrowing currencies. If loan_currency is provided, the API will return an array of collateral currencies supported for the specified borrowing currency.
464+
* @param opts.loanCurrency The parameter loan_currency is used to specify the borrowing currency. If loan_currency is not provided, the API will return all supported borrowing currencies.
465465
*/
466466
public async listCollateralCurrencies(opts: {
467467
loanCurrency?: string;

api/deliveryApi.ts

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
2-
* Gate API v4
3-
* Welcome to Gate API APIv4 provides spot, margin and futures trading operations. There are public APIs to retrieve the real-time market statistics, and private APIs which needs authentication to trade on user\'s behalf.
2+
* Gate API
3+
* Welcome to Gate API APIv4 provides operations related to spot, margin, and contract trading, including public interfaces for querying market data and authenticated private interfaces for implementing API-based automated trading.
44
*
55
* Contact: support@mail.gate.com
66
*
@@ -137,7 +137,7 @@ export class DeliveryApi {
137137
* @param opts Optional parameters
138138
* @param opts.interval Order depth. 0 means no aggregation is applied. default to 0
139139
* @param opts.limit Maximum number of order depth data in asks or bids
140-
* @param opts.withId Whether the order book update ID will be returned. This ID increases by 1 on every order book update
140+
* @param opts.withId Whether to return depth update ID. This ID increments by 1 each time.
141141
*/
142142
public async listDeliveryOrderBook(
143143
settle: 'usdt',
@@ -200,7 +200,7 @@ export class DeliveryApi {
200200
* @param contract Futures contract
201201
* @param opts Optional parameters
202202
* @param opts.limit Maximum number of records to be returned in a single list
203-
* @param opts.lastId Specify the starting point for this list based on a previously retrieved id This parameter is deprecated. Use `from` and `to` instead to limit time range
203+
* @param opts.lastId 以上个列表的最后一条记录的 ID 作为下个列表的起点。 该字段不再继续支持,新的请求请使用 `from` `to` 字段来限定时间范围
204204
* @param opts.from Specify starting time in Unix seconds. If not specified, `to` and `limit` will be used to limit response items. If items between `from` and `to` are more than `limit`, only `limit` number will be returned.
205205
* @param opts.to Specify end time in Unix seconds, default to current time
206206
*/
@@ -269,9 +269,9 @@ export class DeliveryApi {
269269
* @param contract Futures contract
270270
* @param opts Optional parameters
271271
* @param opts.from Start time of candlesticks, formatted in Unix timestamp in seconds. Default to`to - 100 * interval` if not specified
272-
* @param opts.to End time of candlesticks, formatted in Unix timestamp in seconds. Default to current time
272+
* @param opts.to Specify the end time of the K-line chart, defaults to current time if not specified, note that the time format is Unix timestamp with second
273273
* @param opts.limit Maximum recent data points to return. `limit` is conflicted with `from` and `to`. If either `from` or `to` is specified, request will be rejected.
274-
* @param opts.interval Interval time between data points. Note that `1w` means natual week(Mon-Sun), while `7d` means every 7d since unix 0
274+
* @param opts.interval Time interval between data points, note that 1w represents a natural week, 7d time is aligned with Unix initial timeweek
275275
*/
276276
public async listDeliveryCandlesticks(
277277
settle: 'usdt',
@@ -488,8 +488,8 @@ export class DeliveryApi {
488488
* @param settle Settle currency
489489
* @param opts Optional parameters
490490
* @param opts.limit Maximum number of records to be returned in a single list
491-
* @param opts.from Start timestamp
492-
* @param opts.to End timestamp
491+
* @param opts.from Start timestamp Specify start time, time format is Unix timestamp. If not specified, it defaults to (the data start time of the time range actually returned by to and limit)
492+
* @param opts.to Termination Timestamp Specify the end time. If not specified, it defaults to the current time, and the time format is a Unix timestamp
493493
* @param opts.type Changing Type: - dnw: Deposit & Withdraw - pnl: Profit & Loss by reducing position - fee: Trading fee - refr: Referrer rebate - fund: Funding - point_dnw: POINT Deposit & Withdraw - point_fee: POINT Trading fee - point_refr: POINT Referrer rebate
494494
*/
495495
public async listDeliveryAccountBook(
@@ -636,7 +636,7 @@ export class DeliveryApi {
636636
* @summary Update position margin
637637
* @param settle Settle currency
638638
* @param contract Futures contract
639-
* @param change Margin change. Use positive number to increase margin, negative number otherwise.
639+
* @param change Margin change amount, positive number increases, negative number
640640
*/
641641
public async updateDeliveryPositionMargin(
642642
settle: 'usdt',
@@ -823,7 +823,7 @@ export class DeliveryApi {
823823
* @param opts.contract Futures contract
824824
* @param opts.limit Maximum number of records to be returned in a single list
825825
* @param opts.offset List offset, starting from 0
826-
* @param opts.lastId Specify list staring point using the `id` of last record in previous list-query results
826+
* @param opts.lastId Specify the currency name to query in batches, and support up to 100 pass parameters at a time.
827827
* @param opts.countTotal Whether to return total number matched. Default to 0(no return)
828828
*/
829829
public async listDeliveryOrders(
@@ -1088,7 +1088,7 @@ export class DeliveryApi {
10881088
* @param opts.order Futures order ID, return related data only if specified
10891089
* @param opts.limit Maximum number of records to be returned in a single list
10901090
* @param opts.offset List offset, starting from 0
1091-
* @param opts.lastId Specify list staring point using the `id` of last record in previous list-query results
1091+
* @param opts.lastId Specify the currency name to query in batches, and support up to 100 pass parameters at a time.
10921092
* @param opts.countTotal Whether to return total number matched. Default to 0(no return)
10931093
*/
10941094
public async getMyDeliveryTrades(

api/earnApi.ts

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
2-
* Gate API v4
3-
* Welcome to Gate API APIv4 provides spot, margin and futures trading operations. There are public APIs to retrieve the real-time market statistics, and private APIs which needs authentication to trade on user\'s behalf.
2+
* Gate API
3+
* Welcome to Gate API APIv4 provides operations related to spot, margin, and contract trading, including public interfaces for querying market data and authenticated private interfaces for implementing API-based automated trading.
44
*
55
* Contact: support@mail.gate.com
66
*
@@ -20,6 +20,7 @@ import { StructuredBuy } from '../model/structuredBuy';
2020
import { StructuredGetProjectList } from '../model/structuredGetProjectList';
2121
import { StructuredOrderList } from '../model/structuredOrderList';
2222
import { SwapCoin } from '../model/swapCoin';
23+
import { SwapCoinStruct } from '../model/swapCoinStruct';
2324
import { ObjectSerializer } from '../model/models';
2425
import { ApiClient } from './apiClient';
2526
import { AxiosRequestConfig, AxiosResponse } from 'axios';
@@ -217,9 +218,9 @@ export class EarnApi {
217218
/**
218219
*
219220
* @summary Structured Product List
220-
* @param status Status (default: all) `in_process`-processing `will_begin`-unstarted `wait_settlement`-unsettled `done`-finish
221+
* @param status Status (Default empty to query all) `in_process`-In progress `will_begin`-Not started `wait_settlement`-Pending settlement `done`-Completed
221222
* @param opts Optional parameters
222-
* @param opts.type Product Type (default all) `SharkFin2.0`-SharkFin `BullishSharkFin`-BullishSharkFin `BearishSharkFin`-BearishSharkFin `DoubleNoTouch`-DoubleNoTouch `RangeAccrual`-RangeAccrual `SnowBall`-SnowBall
223+
* @param opts.type Product Type (Default empty to query all) `SharkFin2.0`-Shark Fin `BullishSharkFin`-Bullish Treasure `BearishSharkFin`-Bearish Treasure `DoubleNoTouch`-Volatility Treasure `RangeAccrual`-Range Smart Yield `SnowBall`-Snowball
223224
* @param opts.page Page number
224225
* @param opts.limit Maximum number of records to be returned in a single list
225226
*/
@@ -277,8 +278,8 @@ export class EarnApi {
277278
*
278279
* @summary Structured Product Order List
279280
* @param opts Optional parameters
280-
* @param opts.from Start timestamp
281-
* @param opts.to End timestamp
281+
* @param opts.from Start timestamp Specify start time, time format is Unix timestamp. If not specified, it defaults to (the data start time of the time range actually returned by to and limit)
282+
* @param opts.to Termination Timestamp Specify the end time. If not specified, it defaults to the current time, and the time format is a Unix timestamp
282283
* @param opts.page Page number
283284
* @param opts.limit Maximum number of records to be returned in a single list
284285
*/
@@ -358,7 +359,7 @@ export class EarnApi {
358359

359360
/**
360361
*
361-
* @summary 链上赚币币种
362+
* @summary Staking Coins
362363
* @param findCoin
363364
*/
364365
public async findCoin(findCoin: FindCoin): Promise<{ response: AxiosResponse; body: Array<string> }> {
@@ -395,10 +396,17 @@ export class EarnApi {
395396
* @summary On-chain Token Swap for Earned Coins
396397
* @param swapCoin
397398
*/
398-
public async swapStakingCoin(swapCoin: SwapCoin): Promise<{ response: AxiosResponse; body?: any }> {
399+
public async swapStakingCoin(swapCoin: SwapCoin): Promise<{ response: AxiosResponse; body: SwapCoinStruct }> {
399400
const localVarPath = this.client.basePath + '/earn/staking/swap';
400401
let localVarQueryParameters: any = {};
401402
let localVarHeaderParams: any = (<any>Object).assign({}, this.client.defaultHeaders);
403+
const produces = ['application/json'];
404+
// give precedence to 'application/json'
405+
if (produces.indexOf('application/json') >= 0) {
406+
localVarHeaderParams.Accept = 'application/json';
407+
} else {
408+
localVarHeaderParams.Accept = produces.join(',');
409+
}
402410

403411
// verify required parameter 'swapCoin' is not null or undefined
404412
if (swapCoin === null || swapCoin === undefined) {
@@ -414,6 +422,6 @@ export class EarnApi {
414422
};
415423

416424
const authSettings = ['apiv4'];
417-
return this.client.request<any>(config, '', authSettings);
425+
return this.client.request<SwapCoinStruct>(config, 'SwapCoinStruct', authSettings);
418426
}
419427
}

0 commit comments

Comments
 (0)