Skip to content

Commit 1f6df1e

Browse files
committed
Merge branch 'vei_api-Python-2022-01-01-online-359-2024_03_21_14_15_40' into 'master'
Vei api python 2022 01 01 online 359 2024 03 21 14 15 40 See merge request iaasng/volcengine-python-sdk!274
2 parents 1ebdfac + 76f04a2 commit 1f6df1e

File tree

10 files changed

+510
-5
lines changed

10 files changed

+510
-5
lines changed

meta.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
2-
"lasted": "1.0.70",
3-
"meta_commit": "4b7787e2b1f8c7f96853976ca27cefb6bce90486"
2+
"lasted": "1.0.71",
3+
"meta_commit": "9b8097a35f287338f299c3f4c67b27ac3ce80478"
44
}

setup.py

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

55
NAME = "volcengine-python-sdk"
6-
VERSION = "1.0.70"
6+
VERSION = "1.0.71"
77
# To install the library, run the following
88
#
99
# python setup.py install

volcenginesdkcore/api_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ def __init__(self, configuration=None, header_name=None, header_value=None,
6767
self.default_headers[header_name] = header_value
6868
self.cookie = cookie
6969
# Set default User-Agent.
70-
self.user_agent = 'volcstack-python-sdk/1.0.70'
70+
self.user_agent = 'volcstack-python-sdk/1.0.71'
7171
self.client_side_validation = configuration.client_side_validation
7272

7373
def __del__(self):

volcenginesdkcore/configuration.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,5 +221,5 @@ def to_debug_report(self):
221221
"OS: {env}\n"\
222222
"Python Version: {pyversion}\n"\
223223
"Version of the API: 0.1.0\n"\
224-
"SDK Package Version: 1.0.70".\
224+
"SDK Package Version: 1.0.71".\
225225
format(env=sys.platform, pyversion=sys.version)

volcenginesdkveiapi/__init__.py

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# coding: utf-8
2+
3+
# flake8: noqa
4+
5+
"""
6+
vei_api
7+
8+
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
9+
10+
OpenAPI spec version: common-version
11+
12+
Generated by: https://github.com/swagger-api/swagger-codegen.git
13+
"""
14+
15+
16+
from __future__ import absolute_import
17+
18+
# import apis into sdk package
19+
from volcenginesdkveiapi.api.vei_api_api import VEIAPIApi
20+
21+
# import models into sdk package
22+
from volcenginesdkveiapi.models.create_sn_in_one_step_request import CreateSNInOneStepRequest
23+
from volcenginesdkveiapi.models.create_sn_in_one_step_response import CreateSNInOneStepResponse
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
from __future__ import absolute_import
2+
3+
# flake8: noqa
4+
5+
# import apis into api package
6+
from volcenginesdkveiapi.api.vei_api_api import VEIAPIApi
Lines changed: 131 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,131 @@
1+
# coding: utf-8
2+
3+
"""
4+
vei_api
5+
6+
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
7+
8+
OpenAPI spec version: common-version
9+
10+
Generated by: https://github.com/swagger-api/swagger-codegen.git
11+
"""
12+
13+
14+
from __future__ import absolute_import
15+
16+
import re # noqa: F401
17+
18+
# python 2 and python 3 compatibility library
19+
import six
20+
21+
import volcenginesdkcore
22+
23+
24+
class VEIAPIApi(object):
25+
"""NOTE: This class is auto generated by the swagger code generator program.
26+
27+
Do not edit the class manually.
28+
Ref: https://github.com/swagger-api/swagger-codegen
29+
"""
30+
31+
def __init__(self, api_client=None):
32+
if api_client is None:
33+
api_client = volcenginesdkcore.ApiClient()
34+
self.api_client = api_client
35+
36+
def create_sn_in_one_step(self, body, **kwargs): # noqa: E501
37+
"""create_sn_in_one_step # noqa: E501
38+
39+
This method makes a synchronous HTTP request by default. To make an
40+
asynchronous HTTP request, please pass async_req=True
41+
>>> thread = api.create_sn_in_one_step(body, async_req=True)
42+
>>> result = thread.get()
43+
44+
:param async_req bool
45+
:param CreateSNInOneStepRequest body: (required)
46+
:return: CreateSNInOneStepResponse
47+
If the method is called asynchronously,
48+
returns the request thread.
49+
"""
50+
kwargs['_return_http_data_only'] = True
51+
if kwargs.get('async_req'):
52+
return self.create_sn_in_one_step_with_http_info(body, **kwargs) # noqa: E501
53+
else:
54+
(data) = self.create_sn_in_one_step_with_http_info(body, **kwargs) # noqa: E501
55+
return data
56+
57+
def create_sn_in_one_step_with_http_info(self, body, **kwargs): # noqa: E501
58+
"""create_sn_in_one_step # noqa: E501
59+
60+
This method makes a synchronous HTTP request by default. To make an
61+
asynchronous HTTP request, please pass async_req=True
62+
>>> thread = api.create_sn_in_one_step_with_http_info(body, async_req=True)
63+
>>> result = thread.get()
64+
65+
:param async_req bool
66+
:param CreateSNInOneStepRequest body: (required)
67+
:return: CreateSNInOneStepResponse
68+
If the method is called asynchronously,
69+
returns the request thread.
70+
"""
71+
72+
all_params = ['body'] # noqa: E501
73+
all_params.append('async_req')
74+
all_params.append('_return_http_data_only')
75+
all_params.append('_preload_content')
76+
all_params.append('_request_timeout')
77+
78+
params = locals()
79+
for key, val in six.iteritems(params['kwargs']):
80+
if key not in all_params:
81+
raise TypeError(
82+
"Got an unexpected keyword argument '%s'"
83+
" to method create_sn_in_one_step" % key
84+
)
85+
params[key] = val
86+
del params['kwargs']
87+
# verify the required parameter 'body' is set
88+
if self.api_client.client_side_validation and ('body' not in params or
89+
params['body'] is None): # noqa: E501
90+
raise ValueError("Missing the required parameter `body` when calling `create_sn_in_one_step`") # noqa: E501
91+
92+
collection_formats = {}
93+
94+
path_params = {}
95+
96+
query_params = []
97+
98+
header_params = {}
99+
100+
form_params = []
101+
local_var_files = {}
102+
103+
body_params = None
104+
if 'body' in params:
105+
body_params = params['body']
106+
# HTTP header `Accept`
107+
header_params['Accept'] = self.api_client.select_header_accept(
108+
['application/json']) # noqa: E501
109+
110+
# HTTP header `Content-Type`
111+
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
112+
['application/json']) # noqa: E501
113+
114+
# Authentication setting
115+
auth_settings = ['volcengineSign'] # noqa: E501
116+
117+
return self.api_client.call_api(
118+
'/CreateSNInOneStep/2022-01-01/vei_api/post/application_json/', 'POST',
119+
path_params,
120+
query_params,
121+
header_params,
122+
body=body_params,
123+
post_params=form_params,
124+
files=local_var_files,
125+
response_type='CreateSNInOneStepResponse', # noqa: E501
126+
auth_settings=auth_settings,
127+
async_req=params.get('async_req'),
128+
_return_http_data_only=params.get('_return_http_data_only'),
129+
_preload_content=params.get('_preload_content', True),
130+
_request_timeout=params.get('_request_timeout'),
131+
collection_formats=collection_formats)
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# coding: utf-8
2+
3+
# flake8: noqa
4+
"""
5+
vei_api
6+
7+
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
8+
9+
OpenAPI spec version: common-version
10+
11+
Generated by: https://github.com/swagger-api/swagger-codegen.git
12+
"""
13+
14+
15+
from __future__ import absolute_import
16+
17+
# import models into model package
18+
from volcenginesdkveiapi.models.create_sn_in_one_step_request import CreateSNInOneStepRequest
19+
from volcenginesdkveiapi.models.create_sn_in_one_step_response import CreateSNInOneStepResponse
Lines changed: 177 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,177 @@
1+
# coding: utf-8
2+
3+
"""
4+
vei_api
5+
6+
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501
7+
8+
OpenAPI spec version: common-version
9+
10+
Generated by: https://github.com/swagger-api/swagger-codegen.git
11+
"""
12+
13+
14+
import pprint
15+
import re # noqa: F401
16+
17+
import six
18+
19+
from volcenginesdkcore.configuration import Configuration
20+
21+
22+
class CreateSNInOneStepRequest(object):
23+
"""NOTE: This class is auto generated by the swagger code generator program.
24+
25+
Do not edit the class manually.
26+
"""
27+
28+
"""
29+
Attributes:
30+
swagger_types (dict): The key is attribute name
31+
and the value is attribute type.
32+
attribute_map (dict): The key is attribute name
33+
and the value is json key in definition.
34+
"""
35+
swagger_types = {
36+
'auto_renew': 'bool',
37+
'count_of_month': 'str',
38+
'type': 'int'
39+
}
40+
41+
attribute_map = {
42+
'auto_renew': 'auto_renew',
43+
'count_of_month': 'count_of_month',
44+
'type': 'type'
45+
}
46+
47+
def __init__(self, auto_renew=None, count_of_month=None, type=None, _configuration=None): # noqa: E501
48+
"""CreateSNInOneStepRequest - a model defined in Swagger""" # noqa: E501
49+
if _configuration is None:
50+
_configuration = Configuration()
51+
self._configuration = _configuration
52+
53+
self._auto_renew = None
54+
self._count_of_month = None
55+
self._type = None
56+
self.discriminator = None
57+
58+
if auto_renew is not None:
59+
self.auto_renew = auto_renew
60+
self.count_of_month = count_of_month
61+
self.type = type
62+
63+
@property
64+
def auto_renew(self):
65+
"""Gets the auto_renew of this CreateSNInOneStepRequest. # noqa: E501
66+
67+
68+
:return: The auto_renew of this CreateSNInOneStepRequest. # noqa: E501
69+
:rtype: bool
70+
"""
71+
return self._auto_renew
72+
73+
@auto_renew.setter
74+
def auto_renew(self, auto_renew):
75+
"""Sets the auto_renew of this CreateSNInOneStepRequest.
76+
77+
78+
:param auto_renew: The auto_renew of this CreateSNInOneStepRequest. # noqa: E501
79+
:type: bool
80+
"""
81+
82+
self._auto_renew = auto_renew
83+
84+
@property
85+
def count_of_month(self):
86+
"""Gets the count_of_month of this CreateSNInOneStepRequest. # noqa: E501
87+
88+
89+
:return: The count_of_month of this CreateSNInOneStepRequest. # noqa: E501
90+
:rtype: str
91+
"""
92+
return self._count_of_month
93+
94+
@count_of_month.setter
95+
def count_of_month(self, count_of_month):
96+
"""Sets the count_of_month of this CreateSNInOneStepRequest.
97+
98+
99+
:param count_of_month: The count_of_month of this CreateSNInOneStepRequest. # noqa: E501
100+
:type: str
101+
"""
102+
if self._configuration.client_side_validation and count_of_month is None:
103+
raise ValueError("Invalid value for `count_of_month`, must not be `None`") # noqa: E501
104+
105+
self._count_of_month = count_of_month
106+
107+
@property
108+
def type(self):
109+
"""Gets the type of this CreateSNInOneStepRequest. # noqa: E501
110+
111+
112+
:return: The type of this CreateSNInOneStepRequest. # noqa: E501
113+
:rtype: int
114+
"""
115+
return self._type
116+
117+
@type.setter
118+
def type(self, type):
119+
"""Sets the type of this CreateSNInOneStepRequest.
120+
121+
122+
:param type: The type of this CreateSNInOneStepRequest. # noqa: E501
123+
:type: int
124+
"""
125+
if self._configuration.client_side_validation and type is None:
126+
raise ValueError("Invalid value for `type`, must not be `None`") # noqa: E501
127+
128+
self._type = type
129+
130+
def to_dict(self):
131+
"""Returns the model properties as a dict"""
132+
result = {}
133+
134+
for attr, _ in six.iteritems(self.swagger_types):
135+
value = getattr(self, attr)
136+
if isinstance(value, list):
137+
result[attr] = list(map(
138+
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
139+
value
140+
))
141+
elif hasattr(value, "to_dict"):
142+
result[attr] = value.to_dict()
143+
elif isinstance(value, dict):
144+
result[attr] = dict(map(
145+
lambda item: (item[0], item[1].to_dict())
146+
if hasattr(item[1], "to_dict") else item,
147+
value.items()
148+
))
149+
else:
150+
result[attr] = value
151+
if issubclass(CreateSNInOneStepRequest, dict):
152+
for key, value in self.items():
153+
result[key] = value
154+
155+
return result
156+
157+
def to_str(self):
158+
"""Returns the string representation of the model"""
159+
return pprint.pformat(self.to_dict())
160+
161+
def __repr__(self):
162+
"""For `print` and `pprint`"""
163+
return self.to_str()
164+
165+
def __eq__(self, other):
166+
"""Returns true if both objects are equal"""
167+
if not isinstance(other, CreateSNInOneStepRequest):
168+
return False
169+
170+
return self.to_dict() == other.to_dict()
171+
172+
def __ne__(self, other):
173+
"""Returns true if both objects are not equal"""
174+
if not isinstance(other, CreateSNInOneStepRequest):
175+
return True
176+
177+
return self.to_dict() != other.to_dict()

0 commit comments

Comments
 (0)