Skip to content

Commit 4c5ae5b

Browse files
committed
add etf info in spot currency pair
1 parent 3838f4d commit 4c5ae5b

9 files changed

Lines changed: 159 additions & 9 deletions

File tree

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ APIv4 provides spot, margin and futures trading operations. There are public API
33

44
This Python package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
55

6-
- API version: 4.18.1
7-
- Package version: 4.18.1
6+
- API version: 4.18.3
7+
- Package version: 4.18.3
88
- Build package: org.openapitools.codegen.languages.PythonClientCodegen
99
For more information, please visit [https://www.gate.io/page/contacts](https://www.gate.io/page/contacts)
1010

docs/CurrencyPair.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ Name | Type | Description | Notes
1313
**amount_precision** | **int** | Amount scale | [optional]
1414
**precision** | **int** | Price scale | [optional]
1515
**trade_status** | **str** | How currency pair can be traded - untradable: cannot be bought or sold - buyable: can be bought - sellable: can be sold - tradable: can be bought or sold | [optional]
16+
**etf_net_value** | **str** | ETF net value | [optional]
17+
**etf_pre_net_value** | **str** | ETF previous net value at re-balancing time | [optional]
18+
**etf_pre_timestamp** | **int** | ETF previous re-balancing time | [optional]
19+
**etf_leverage** | **str** | ETF current leverage | [optional]
1620

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

docs/Trade.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ Name | Type | Description | Notes
55
------------ | ------------- | ------------- | -------------
66
**id** | **str** | Trade ID | [optional]
77
**create_time** | **str** | Trading time | [optional]
8+
**create_time_ms** | **str** | Trading time, with millisecond precision | [optional]
89
**side** | **str** | Order side | [optional]
910
**role** | **str** | Trade role | [optional]
1011
**amount** | **str** | Trade amount | [optional]

gate_api/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515
from __future__ import absolute_import
1616

17-
__version__ = "4.18.1"
17+
__version__ = "4.18.3"
1818

1919
# import apis into sdk package
2020
from gate_api.api.delivery_api import DeliveryApi

gate_api/api_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ def __init__(self, configuration=None, header_name=None, header_value=None, cook
8282
self.default_headers[header_name] = header_value
8383
self.cookie = cookie
8484
# Set default User-Agent.
85-
self.user_agent = 'OpenAPI-Generator/4.18.1/python'
85+
self.user_agent = 'OpenAPI-Generator/4.18.3/python'
8686
self.client_side_validation = configuration.client_side_validation
8787

8888
def __enter__(self):

gate_api/configuration.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -316,8 +316,8 @@ def to_debug_report(self):
316316
"Python SDK Debug Report:\n"
317317
"OS: {env}\n"
318318
"Python Version: {pyversion}\n"
319-
"Version of the API: 4.18.1\n"
320-
"SDK Package Version: 4.18.1".format(env=sys.platform, pyversion=sys.version)
319+
"Version of the API: 4.18.3\n"
320+
"SDK Package Version: 4.18.3".format(env=sys.platform, pyversion=sys.version)
321321
)
322322

323323
def get_host_settings(self):

gate_api/models/currency_pair.py

Lines changed: 117 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,10 @@ class CurrencyPair(object):
4242
'amount_precision': 'int',
4343
'precision': 'int',
4444
'trade_status': 'str',
45+
'etf_net_value': 'str',
46+
'etf_pre_net_value': 'str',
47+
'etf_pre_timestamp': 'int',
48+
'etf_leverage': 'str',
4549
}
4650

4751
attribute_map = {
@@ -54,6 +58,10 @@ class CurrencyPair(object):
5458
'amount_precision': 'amount_precision',
5559
'precision': 'precision',
5660
'trade_status': 'trade_status',
61+
'etf_net_value': 'etf_net_value',
62+
'etf_pre_net_value': 'etf_pre_net_value',
63+
'etf_pre_timestamp': 'etf_pre_timestamp',
64+
'etf_leverage': 'etf_leverage',
5765
}
5866

5967
def __init__(
@@ -67,9 +75,13 @@ def __init__(
6775
amount_precision=None,
6876
precision=None,
6977
trade_status=None,
78+
etf_net_value=None,
79+
etf_pre_net_value=None,
80+
etf_pre_timestamp=None,
81+
etf_leverage=None,
7082
local_vars_configuration=None,
7183
): # noqa: E501
72-
# type: (str, str, str, str, str, str, int, int, str, Configuration) -> None
84+
# type: (str, str, str, str, str, str, int, int, str, str, str, int, str, Configuration) -> None
7385
"""CurrencyPair - a model defined in OpenAPI""" # noqa: E501
7486
if local_vars_configuration is None:
7587
local_vars_configuration = Configuration()
@@ -84,6 +96,10 @@ def __init__(
8496
self._amount_precision = None
8597
self._precision = None
8698
self._trade_status = None
99+
self._etf_net_value = None
100+
self._etf_pre_net_value = None
101+
self._etf_pre_timestamp = None
102+
self._etf_leverage = None
87103
self.discriminator = None
88104

89105
if id is not None:
@@ -104,6 +120,14 @@ def __init__(
104120
self.precision = precision
105121
if trade_status is not None:
106122
self.trade_status = trade_status
123+
if etf_net_value is not None:
124+
self.etf_net_value = etf_net_value
125+
if etf_pre_net_value is not None:
126+
self.etf_pre_net_value = etf_pre_net_value
127+
if etf_pre_timestamp is not None:
128+
self.etf_pre_timestamp = etf_pre_timestamp
129+
if etf_leverage is not None:
130+
self.etf_leverage = etf_leverage
107131

108132
@property
109133
def id(self):
@@ -319,6 +343,98 @@ def trade_status(self, trade_status):
319343

320344
self._trade_status = trade_status
321345

346+
@property
347+
def etf_net_value(self):
348+
"""Gets the etf_net_value of this CurrencyPair. # noqa: E501
349+
350+
ETF net value # noqa: E501
351+
352+
:return: The etf_net_value of this CurrencyPair. # noqa: E501
353+
:rtype: str
354+
"""
355+
return self._etf_net_value
356+
357+
@etf_net_value.setter
358+
def etf_net_value(self, etf_net_value):
359+
"""Sets the etf_net_value of this CurrencyPair.
360+
361+
ETF net value # noqa: E501
362+
363+
:param etf_net_value: The etf_net_value of this CurrencyPair. # noqa: E501
364+
:type: str
365+
"""
366+
367+
self._etf_net_value = etf_net_value
368+
369+
@property
370+
def etf_pre_net_value(self):
371+
"""Gets the etf_pre_net_value of this CurrencyPair. # noqa: E501
372+
373+
ETF previous net value at re-balancing time # noqa: E501
374+
375+
:return: The etf_pre_net_value of this CurrencyPair. # noqa: E501
376+
:rtype: str
377+
"""
378+
return self._etf_pre_net_value
379+
380+
@etf_pre_net_value.setter
381+
def etf_pre_net_value(self, etf_pre_net_value):
382+
"""Sets the etf_pre_net_value of this CurrencyPair.
383+
384+
ETF previous net value at re-balancing time # noqa: E501
385+
386+
:param etf_pre_net_value: The etf_pre_net_value of this CurrencyPair. # noqa: E501
387+
:type: str
388+
"""
389+
390+
self._etf_pre_net_value = etf_pre_net_value
391+
392+
@property
393+
def etf_pre_timestamp(self):
394+
"""Gets the etf_pre_timestamp of this CurrencyPair. # noqa: E501
395+
396+
ETF previous re-balancing time # noqa: E501
397+
398+
:return: The etf_pre_timestamp of this CurrencyPair. # noqa: E501
399+
:rtype: int
400+
"""
401+
return self._etf_pre_timestamp
402+
403+
@etf_pre_timestamp.setter
404+
def etf_pre_timestamp(self, etf_pre_timestamp):
405+
"""Sets the etf_pre_timestamp of this CurrencyPair.
406+
407+
ETF previous re-balancing time # noqa: E501
408+
409+
:param etf_pre_timestamp: The etf_pre_timestamp of this CurrencyPair. # noqa: E501
410+
:type: int
411+
"""
412+
413+
self._etf_pre_timestamp = etf_pre_timestamp
414+
415+
@property
416+
def etf_leverage(self):
417+
"""Gets the etf_leverage of this CurrencyPair. # noqa: E501
418+
419+
ETF current leverage # noqa: E501
420+
421+
:return: The etf_leverage of this CurrencyPair. # noqa: E501
422+
:rtype: str
423+
"""
424+
return self._etf_leverage
425+
426+
@etf_leverage.setter
427+
def etf_leverage(self, etf_leverage):
428+
"""Sets the etf_leverage of this CurrencyPair.
429+
430+
ETF current leverage # noqa: E501
431+
432+
:param etf_leverage: The etf_leverage of this CurrencyPair. # noqa: E501
433+
:type: str
434+
"""
435+
436+
self._etf_leverage = etf_leverage
437+
322438
def to_dict(self):
323439
"""Returns the model properties as a dict"""
324440
result = {}

gate_api/models/trade.py

Lines changed: 30 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ class Trade(object):
3535
openapi_types = {
3636
'id': 'str',
3737
'create_time': 'str',
38+
'create_time_ms': 'str',
3839
'side': 'str',
3940
'role': 'str',
4041
'amount': 'str',
@@ -49,6 +50,7 @@ class Trade(object):
4950
attribute_map = {
5051
'id': 'id',
5152
'create_time': 'create_time',
53+
'create_time_ms': 'create_time_ms',
5254
'side': 'side',
5355
'role': 'role',
5456
'amount': 'amount',
@@ -64,6 +66,7 @@ def __init__(
6466
self,
6567
id=None,
6668
create_time=None,
69+
create_time_ms=None,
6770
side=None,
6871
role=None,
6972
amount=None,
@@ -75,14 +78,15 @@ def __init__(
7578
gt_fee=None,
7679
local_vars_configuration=None,
7780
): # noqa: E501
78-
# type: (str, str, str, str, str, str, str, str, str, str, str, Configuration) -> None
81+
# type: (str, str, str, str, str, str, str, str, str, str, str, str, Configuration) -> None
7982
"""Trade - a model defined in OpenAPI""" # noqa: E501
8083
if local_vars_configuration is None:
8184
local_vars_configuration = Configuration()
8285
self.local_vars_configuration = local_vars_configuration
8386

8487
self._id = None
8588
self._create_time = None
89+
self._create_time_ms = None
8690
self._side = None
8791
self._role = None
8892
self._amount = None
@@ -98,6 +102,8 @@ def __init__(
98102
self.id = id
99103
if create_time is not None:
100104
self.create_time = create_time
105+
if create_time_ms is not None:
106+
self.create_time_ms = create_time_ms
101107
if side is not None:
102108
self.side = side
103109
if role is not None:
@@ -163,6 +169,29 @@ def create_time(self, create_time):
163169

164170
self._create_time = create_time
165171

172+
@property
173+
def create_time_ms(self):
174+
"""Gets the create_time_ms of this Trade. # noqa: E501
175+
176+
Trading time, with millisecond precision # noqa: E501
177+
178+
:return: The create_time_ms of this Trade. # noqa: E501
179+
:rtype: str
180+
"""
181+
return self._create_time_ms
182+
183+
@create_time_ms.setter
184+
def create_time_ms(self, create_time_ms):
185+
"""Sets the create_time_ms of this Trade.
186+
187+
Trading time, with millisecond precision # noqa: E501
188+
189+
:param create_time_ms: The create_time_ms of this Trade. # noqa: E501
190+
:type: str
191+
"""
192+
193+
self._create_time_ms = create_time_ms
194+
166195
@property
167196
def side(self):
168197
"""Gets the side of this Trade. # noqa: E501

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
from setuptools import setup, find_packages # noqa: H301
1414

1515
NAME = "gate-api"
16-
VERSION = "4.18.1"
16+
VERSION = "4.18.3"
1717
# To install the library, run the following
1818
#
1919
# python setup.py install

0 commit comments

Comments
 (0)