Skip to content

Commit

Permalink
release 4.82.0
Browse files Browse the repository at this point in the history
  • Loading branch information
revilwang committed Oct 14, 2024
1 parent 03cc882 commit 40cb7f4
Show file tree
Hide file tree
Showing 156 changed files with 13,860 additions and 261 deletions.
70 changes: 63 additions & 7 deletions README.md

Large diffs are not rendered by default.

199 changes: 199 additions & 0 deletions docs/AccountApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,14 @@ All URIs are relative to *https://api.gateio.ws/api/v4*
Method | HTTP request | Description
------------- | ------------- | -------------
[**get_account_detail**](AccountApi.md#get_account_detail) | **GET** /account/detail | Get account detail
[**get_account_rate_limit**](AccountApi.md#get_account_rate_limit) | **GET** /account/rate_limit | Get user transaction rate limit information
[**list_stp_groups**](AccountApi.md#list_stp_groups) | **GET** /account/stp_groups | List STP Groups
[**create_stp_group**](AccountApi.md#create_stp_group) | **POST** /account/stp_groups | Create STP Group
[**list_stp_groups_users**](AccountApi.md#list_stp_groups_users) | **GET** /account/stp_groups/{stp_id}/users | List users of the STP group
[**add_stp_group_users**](AccountApi.md#add_stp_group_users) | **POST** /account/stp_groups/{stp_id}/users | Add users to the STP group
[**delete_stp_group_users**](AccountApi.md#delete_stp_group_users) | **DELETE** /account/stp_groups/{stp_id}/users | Delete the user in the STP group
[**get_debit_fee**](AccountApi.md#get_debit_fee) | **GET** /account/debit_fee | Query GT deduction configuration.
[**set_debit_fee**](AccountApi.md#set_debit_fee) | **POST** /account/debit_fee | Set GT deduction.


# **get_account_detail**
Expand Down Expand Up @@ -75,6 +78,69 @@ This endpoint does not need any parameter.

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

# **get_account_rate_limit**
> list[AccountRateLimit] get_account_rate_limit()
Get user transaction rate limit information

### Example

* Api Key Authentication (apiv4):
```python
from __future__ import print_function
import gate_api
from gate_api.exceptions import ApiException, GateApiException
# Defining the host is optional and defaults to https://api.gateio.ws/api/v4
# See configuration.py for a list of all supported configuration parameters.
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure APIv4 key authorization
configuration = gate_api.Configuration(
host = "https://api.gateio.ws/api/v4",
key = "YOU_API_KEY",
secret = "YOUR_API_SECRET"
)

api_client = gate_api.ApiClient(configuration)
# Create an instance of the API class
api_instance = gate_api.AccountApi(api_client)

try:
# Get user transaction rate limit information
api_response = api_instance.get_account_rate_limit()
print(api_response)
except GateApiException as ex:
print("Gate api exception, label: %s, message: %s\n" % (ex.label, ex.message))
except ApiException as e:
print("Exception when calling AccountApi->get_account_rate_limit: %s\n" % e)
```

### Parameters
This endpoint does not need any parameter.

### Return type

[**list[AccountRateLimit]**](AccountRateLimit.md)

### Authorization

[apiv4](../README.md#apiv4)

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: application/json

### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
**200** | Successful | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

# **list_stp_groups**
> list[StpGroup] list_stp_groups(name=name)
Expand Down Expand Up @@ -424,3 +490,136 @@ Name | Type | Description | Notes

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

# **get_debit_fee**
> InlineResponse200 get_debit_fee()
Query GT deduction configuration.

Query the current GT deduction configuration for the account.

### Example

* Api Key Authentication (apiv4):
```python
from __future__ import print_function
import gate_api
from gate_api.exceptions import ApiException, GateApiException
# Defining the host is optional and defaults to https://api.gateio.ws/api/v4
# See configuration.py for a list of all supported configuration parameters.
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure APIv4 key authorization
configuration = gate_api.Configuration(
host = "https://api.gateio.ws/api/v4",
key = "YOU_API_KEY",
secret = "YOUR_API_SECRET"
)

api_client = gate_api.ApiClient(configuration)
# Create an instance of the API class
api_instance = gate_api.AccountApi(api_client)

try:
# Query GT deduction configuration.
api_response = api_instance.get_debit_fee()
print(api_response)
except GateApiException as ex:
print("Gate api exception, label: %s, message: %s\n" % (ex.label, ex.message))
except ApiException as e:
print("Exception when calling AccountApi->get_debit_fee: %s\n" % e)
```

### Parameters
This endpoint does not need any parameter.

### Return type

[**InlineResponse200**](InlineResponse200.md)

### Authorization

[apiv4](../README.md#apiv4)

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: application/json

### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
**200** | Success | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

# **set_debit_fee**
> set_debit_fee(inline_object)
Set GT deduction.

Enable or disable GT deduction for the current account.

### Example

* Api Key Authentication (apiv4):
```python
from __future__ import print_function
import gate_api
from gate_api.exceptions import ApiException, GateApiException
# Defining the host is optional and defaults to https://api.gateio.ws/api/v4
# See configuration.py for a list of all supported configuration parameters.
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure APIv4 key authorization
configuration = gate_api.Configuration(
host = "https://api.gateio.ws/api/v4",
key = "YOU_API_KEY",
secret = "YOUR_API_SECRET"
)

api_client = gate_api.ApiClient(configuration)
# Create an instance of the API class
api_instance = gate_api.AccountApi(api_client)
inline_object = gate_api.InlineObject() # InlineObject |

try:
# Set GT deduction.
api_instance.set_debit_fee(inline_object)
except GateApiException as ex:
print("Gate api exception, label: %s, message: %s\n" % (ex.label, ex.message))
except ApiException as e:
print("Exception when calling AccountApi->set_debit_fee: %s\n" % e)
```

### Parameters

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**inline_object** | [**InlineObject**](InlineObject.md)| |

### Return type

void (empty response body)

### Authorization

[apiv4](../README.md#apiv4)

### HTTP request headers

- **Content-Type**: application/json
- **Accept**: Not defined

### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
**200** | Success | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

1 change: 1 addition & 0 deletions docs/AccountDetail.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Name | Type | Description | Notes
**user_id** | **int** | User ID | [optional]
**tier** | **int** | User VIP level | [optional]
**key** | [**AccountDetailKey**](AccountDetailKey.md) | | [optional]
**copy_trading_role** | **int** | User role: 0 - Ordinary user 1 - Order leader 2 - Follower 3 - Order leader and follower | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Expand Down
13 changes: 13 additions & 0 deletions docs/AccountRateLimit.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# AccountRateLimit

## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**tier** | **str** | Frequency limit level (For detailed frequency limit rules, see [Transaction ratio frequency limit](#成交比率限频)) | [optional]
**ratio** | **str** | Transaction rate | [optional]
**main_ratio** | **str** | Total transaction ratio of main account | [optional]
**updated_at** | **str** | Update time | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


1 change: 1 addition & 0 deletions docs/BatchAmendItem.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Name | Type | Description | Notes
**amount** | **str** | trade amount, only one of amount and price can be specified | [optional]
**price** | **str** | trade price, only one of amount and price can be specified | [optional]
**amend_text** | **str** | Custom info during amending order | [optional]
**action_mode** | **str** | Processing Mode: When placing an order, different fields are returned based on action_mode. This field is only valid during the request and is not included in the response result ACK: Asynchronous mode, only returns key order fields RESULT: No clearing information FULL: Full mode (default) | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Expand Down
15 changes: 15 additions & 0 deletions docs/BatchAmendOrderReq.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# BatchAmendOrderReq

Modify contract order parameters
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**order_id** | **int** | Order id, order_id and text must contain at least one | [optional]
**text** | **str** | User-defined order text, at least one of order_id and text must be passed | [optional]
**size** | **int** | The new order size, including the executed order size. - If it is less than or equal to the executed quantity, the order will be cancelled. - The new order direction must be consistent with the original one. - The size of the closing order cannot be modified. - For orders that only reduce positions, if the size is increased, other orders that only reduce positions may be kicked out. - If the price is not modified, reducing the size will not affect the depth of the queue, and increasing the size will place it at the end of the current price. | [optional]
**price** | **str** | New order price. | [optional]
**amend_text** | **str** | Custom info during amending order | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


2 changes: 1 addition & 1 deletion docs/BatchFuturesOrder.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Name | Type | Description | Notes
**user** | **int** | User ID | [optional] [readonly]
**create_time** | **float** | Creation time of order | [optional] [readonly]
**finish_time** | **float** | Order finished time. Not returned if order is open | [optional] [readonly]
**finish_as** | **str** | How the order was finished. - filled: all filled - cancelled: manually cancelled - liquidated: cancelled because of liquidation - ioc: time in force is `IOC`, finish immediately - auto_deleveraged: finished by ADL - reduce_only: cancelled because of increasing position while `reduce-only` set- position_closed: cancelled because of position close - stp: cancelled because self trade prevention | [optional] [readonly]
**finish_as** | **str** | How the order was finished. - filled: all filled - cancelled: manually cancelled - liquidated: cancelled because of liquidation - ioc: time in force is `IOC`, finish immediately - auto_deleveraged: finished by ADL - reduce_only: cancelled because of increasing position while `reduce-only` set- position_closed: cancelled because of position close - position_closed: canceled because the position was closed - reduce_out: only reduce positions by excluding hard-to-fill orders - stp: cancelled because self trade prevention | [optional] [readonly]
**status** | **str** | Order status - `open`: waiting to be traded - `finished`: finished | [optional] [readonly]
**contract** | **str** | Futures contract | [optional]
**size** | **int** | Order size. Specify positive number to make a bid, and negative number to ask | [optional]
Expand Down
1 change: 1 addition & 0 deletions docs/CancelOrderResult.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**currency_pair** | **str** | Order currency pair | [optional]
**id** | **str** | Order ID | [optional]
**text** | **str** | Custom order information | [optional]
**succeeded** | **bool** | Whether cancellation succeeded | [optional]
**label** | **str** | Error label when failed to cancel the order; emtpy if succeeded | [optional]
**message** | **str** | Error message when failed to cancel the order; empty if succeeded | [optional]
Expand Down
2 changes: 1 addition & 1 deletion docs/Contract.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Name | Type | Description | Notes
**trade_size** | **int** | Historical accumulated trade size | [optional]
**position_size** | **int** | Current total long position size | [optional]
**config_change_time** | **float** | Last changed time of configuration | [optional]
**in_delisting** | **bool** | Contract is delisting | [optional]
**in_delisting** | **bool** | `in_delisting=true` And when position_size>0, it means the contract is in the offline transition period `in_delisting=true` And when position_size=0, it means the contract is offline | [optional]
**orders_limit** | **int** | Maximum number of open orders | [optional]
**enable_bonus** | **bool** | Whether bouns is enabled | [optional]
**enable_credit** | **bool** | Whether portfolio margin account is enabled | [optional]
Expand Down
1 change: 1 addition & 0 deletions docs/ConvertSmallBalance.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ Convert Small Balance
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**currency** | **list[str]** | Currency | [optional]
**is_all** | **bool** | Whether to exchange all | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

Expand Down
13 changes: 13 additions & 0 deletions docs/CountdownCancelAllOptionsTask.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# CountdownCancelAllOptionsTask

Countdown cancel task detail
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**timeout** | **int** | Countdown time, in seconds At least 5 seconds, 0 means cancel the countdown |
**contract** | **str** | Options contract name | [optional]
**underlying** | **str** | Underlying | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)


67 changes: 67 additions & 0 deletions docs/DeliveryApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ Method | HTTP request | Description
[**list_delivery_position_close**](DeliveryApi.md#list_delivery_position_close) | **GET** /delivery/{settle}/position_close | List position close history
[**list_delivery_liquidates**](DeliveryApi.md#list_delivery_liquidates) | **GET** /delivery/{settle}/liquidates | List liquidation history
[**list_delivery_settlements**](DeliveryApi.md#list_delivery_settlements) | **GET** /delivery/{settle}/settlements | List settlement history
[**list_delivery_risk_limit_tiers**](DeliveryApi.md#list_delivery_risk_limit_tiers) | **GET** /delivery/{settle}/risk_limit_tiers | List risk limit tiers
[**list_price_triggered_delivery_orders**](DeliveryApi.md#list_price_triggered_delivery_orders) | **GET** /delivery/{settle}/price_orders | List all auto orders
[**create_price_triggered_delivery_order**](DeliveryApi.md#create_price_triggered_delivery_order) | **POST** /delivery/{settle}/price_orders | Create a price-triggered order
[**cancel_price_triggered_delivery_order_list**](DeliveryApi.md#cancel_price_triggered_delivery_order_list) | **DELETE** /delivery/{settle}/price_orders | Cancel all open orders
Expand Down Expand Up @@ -1630,6 +1631,72 @@ Name | Type | Description | Notes

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

# **list_delivery_risk_limit_tiers**
> list[FuturesLimitRiskTiers] list_delivery_risk_limit_tiers(settle, contract=contract, limit=limit, offset=offset)
List risk limit tiers

When the 'contract' parameter is not passed, the default is to query the risk limits for the top 100 markets.'Limit' and 'offset' correspond to pagination queries at the market level, not to the length of the returned array. This only takes effect when the 'contract' parameter is empty.

### Example

```python
from __future__ import print_function
import gate_api
from gate_api.exceptions import ApiException, GateApiException
# Defining the host is optional and defaults to https://api.gateio.ws/api/v4
# See configuration.py for a list of all supported configuration parameters.
configuration = gate_api.Configuration(
host = "https://api.gateio.ws/api/v4"
)

api_client = gate_api.ApiClient(configuration)
# Create an instance of the API class
api_instance = gate_api.DeliveryApi(api_client)
settle = 'usdt' # str | Settle currency
contract = 'BTC_USDT_20200814' # str | Futures contract (optional)
limit = 100 # int | Maximum number of records to be returned in a single list (optional) (default to 100)
offset = 0 # int | List offset, starting from 0 (optional) (default to 0)

try:
# List risk limit tiers
api_response = api_instance.list_delivery_risk_limit_tiers(settle, contract=contract, limit=limit, offset=offset)
print(api_response)
except GateApiException as ex:
print("Gate api exception, label: %s, message: %s\n" % (ex.label, ex.message))
except ApiException as e:
print("Exception when calling DeliveryApi->list_delivery_risk_limit_tiers: %s\n" % e)
```

### Parameters

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**settle** | **str**| Settle currency |
**contract** | **str**| Futures contract | [optional]
**limit** | **int**| Maximum number of records to be returned in a single list | [optional] [default to 100]
**offset** | **int**| List offset, starting from 0 | [optional] [default to 0]

### Return type

[**list[FuturesLimitRiskTiers]**](FuturesLimitRiskTiers.md)

### Authorization

No authorization required

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: application/json

### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
**200** | Successfully retrieved | - |

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

# **list_price_triggered_delivery_orders**
> list[FuturesPriceTriggeredOrder] list_price_triggered_delivery_orders(settle, status, contract=contract, limit=limit, offset=offset)
Expand Down
Loading

0 comments on commit 40cb7f4

Please sign in to comment.