Skip to content

Commit debae55

Browse files
author
BitsAdmin
committed
Merge branch 'tis-Python-2024-07-31-online-1094-2025_04_08_12_33_28' into 'integration_2025-04-17_865081244162'
feat: [development task] tis-1094-Python (1163178) See merge request iaasng/volcengine-python-sdk!571
2 parents 8c96a49 + 32414ec commit debae55

15 files changed

+1463
-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.1.4",
3-
"meta_commit": "dd02693ca04c65eb6d4802be8a736a1f6232ed68"
2+
"lasted": "1.1.5",
3+
"meta_commit": "8add3409ad23518a38031d4eecb43f0cf07dca4b"
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.1.4"
6+
VERSION = "1.1.5"
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
@@ -63,7 +63,7 @@ def __init__(self, configuration=None, header_name=None, header_value=None,
6363
self.default_headers[header_name] = header_value
6464
self.cookie = cookie
6565
# Set default User-Agent.
66-
self.user_agent = 'volcstack-python-sdk/1.1.4'
66+
self.user_agent = 'volcstack-python-sdk/1.1.5'
6767
self.client_side_validation = configuration.client_side_validation
6868

6969
self.interceptor_chain = InterceptorChain()

volcenginesdkcore/configuration.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -250,5 +250,5 @@ def to_debug_report(self):
250250
"OS: {env}\n" \
251251
"Python Version: {pyversion}\n" \
252252
"Version of the API: 0.1.0\n" \
253-
"SDK Package Version: 1.1.4".\
253+
"SDK Package Version: 1.1.5".\
254254
format(env=sys.platform, pyversion=sys.version)

volcenginesdktis/__init__.py

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# coding: utf-8
2+
3+
# flake8: noqa
4+
5+
"""
6+
tis
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 volcenginesdktis.api.tis_api import TISApi
20+
21+
# import models into sdk package
22+
from volcenginesdktis.models.buy_resource_package_request import BuyResourcePackageRequest
23+
from volcenginesdktis.models.buy_resource_package_response import BuyResourcePackageResponse
24+
from volcenginesdktis.models.get_access_token_request import GetAccessTokenRequest
25+
from volcenginesdktis.models.get_access_token_response import GetAccessTokenResponse
26+
from volcenginesdktis.models.get_quota_info_request import GetQuotaInfoRequest
27+
from volcenginesdktis.models.get_quota_info_response import GetQuotaInfoResponse
28+
from volcenginesdktis.models.quota_info_list_for_get_quota_info_output import QuotaInfoListForGetQuotaInfoOutput

volcenginesdktis/api/__init__.py

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 volcenginesdktis.api.tis_api import TISApi

volcenginesdktis/api/tis_api.py

Lines changed: 325 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,325 @@
1+
# coding: utf-8
2+
3+
"""
4+
tis
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 TISApi(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 buy_resource_package(self, body, **kwargs): # noqa: E501
37+
"""buy_resource_package # 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.buy_resource_package(body, async_req=True)
42+
>>> result = thread.get()
43+
44+
:param async_req bool
45+
:param BuyResourcePackageRequest body: (required)
46+
:return: BuyResourcePackageResponse
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.buy_resource_package_with_http_info(body, **kwargs) # noqa: E501
53+
else:
54+
(data) = self.buy_resource_package_with_http_info(body, **kwargs) # noqa: E501
55+
return data
56+
57+
def buy_resource_package_with_http_info(self, body, **kwargs): # noqa: E501
58+
"""buy_resource_package # 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.buy_resource_package_with_http_info(body, async_req=True)
63+
>>> result = thread.get()
64+
65+
:param async_req bool
66+
:param BuyResourcePackageRequest body: (required)
67+
:return: BuyResourcePackageResponse
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 buy_resource_package" % 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 `buy_resource_package`") # 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+
'/BuyResourcePackage/2024-07-31/tis/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='BuyResourcePackageResponse', # 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)
132+
133+
def get_access_token(self, body, **kwargs): # noqa: E501
134+
"""get_access_token # noqa: E501
135+
136+
This method makes a synchronous HTTP request by default. To make an
137+
asynchronous HTTP request, please pass async_req=True
138+
>>> thread = api.get_access_token(body, async_req=True)
139+
>>> result = thread.get()
140+
141+
:param async_req bool
142+
:param GetAccessTokenRequest body: (required)
143+
:return: GetAccessTokenResponse
144+
If the method is called asynchronously,
145+
returns the request thread.
146+
"""
147+
kwargs['_return_http_data_only'] = True
148+
if kwargs.get('async_req'):
149+
return self.get_access_token_with_http_info(body, **kwargs) # noqa: E501
150+
else:
151+
(data) = self.get_access_token_with_http_info(body, **kwargs) # noqa: E501
152+
return data
153+
154+
def get_access_token_with_http_info(self, body, **kwargs): # noqa: E501
155+
"""get_access_token # noqa: E501
156+
157+
This method makes a synchronous HTTP request by default. To make an
158+
asynchronous HTTP request, please pass async_req=True
159+
>>> thread = api.get_access_token_with_http_info(body, async_req=True)
160+
>>> result = thread.get()
161+
162+
:param async_req bool
163+
:param GetAccessTokenRequest body: (required)
164+
:return: GetAccessTokenResponse
165+
If the method is called asynchronously,
166+
returns the request thread.
167+
"""
168+
169+
all_params = ['body'] # noqa: E501
170+
all_params.append('async_req')
171+
all_params.append('_return_http_data_only')
172+
all_params.append('_preload_content')
173+
all_params.append('_request_timeout')
174+
175+
params = locals()
176+
for key, val in six.iteritems(params['kwargs']):
177+
if key not in all_params:
178+
raise TypeError(
179+
"Got an unexpected keyword argument '%s'"
180+
" to method get_access_token" % key
181+
)
182+
params[key] = val
183+
del params['kwargs']
184+
# verify the required parameter 'body' is set
185+
if self.api_client.client_side_validation and ('body' not in params or
186+
params['body'] is None): # noqa: E501
187+
raise ValueError("Missing the required parameter `body` when calling `get_access_token`") # noqa: E501
188+
189+
collection_formats = {}
190+
191+
path_params = {}
192+
193+
query_params = []
194+
195+
header_params = {}
196+
197+
form_params = []
198+
local_var_files = {}
199+
200+
body_params = None
201+
if 'body' in params:
202+
body_params = params['body']
203+
# HTTP header `Accept`
204+
header_params['Accept'] = self.api_client.select_header_accept(
205+
['application/json']) # noqa: E501
206+
207+
# HTTP header `Content-Type`
208+
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
209+
['application/json']) # noqa: E501
210+
211+
# Authentication setting
212+
auth_settings = ['volcengineSign'] # noqa: E501
213+
214+
return self.api_client.call_api(
215+
'/GetAccessToken/2024-07-31/tis/post/application_json/', 'POST',
216+
path_params,
217+
query_params,
218+
header_params,
219+
body=body_params,
220+
post_params=form_params,
221+
files=local_var_files,
222+
response_type='GetAccessTokenResponse', # noqa: E501
223+
auth_settings=auth_settings,
224+
async_req=params.get('async_req'),
225+
_return_http_data_only=params.get('_return_http_data_only'),
226+
_preload_content=params.get('_preload_content', True),
227+
_request_timeout=params.get('_request_timeout'),
228+
collection_formats=collection_formats)
229+
230+
def get_quota_info(self, body, **kwargs): # noqa: E501
231+
"""get_quota_info # noqa: E501
232+
233+
This method makes a synchronous HTTP request by default. To make an
234+
asynchronous HTTP request, please pass async_req=True
235+
>>> thread = api.get_quota_info(body, async_req=True)
236+
>>> result = thread.get()
237+
238+
:param async_req bool
239+
:param GetQuotaInfoRequest body: (required)
240+
:return: GetQuotaInfoResponse
241+
If the method is called asynchronously,
242+
returns the request thread.
243+
"""
244+
kwargs['_return_http_data_only'] = True
245+
if kwargs.get('async_req'):
246+
return self.get_quota_info_with_http_info(body, **kwargs) # noqa: E501
247+
else:
248+
(data) = self.get_quota_info_with_http_info(body, **kwargs) # noqa: E501
249+
return data
250+
251+
def get_quota_info_with_http_info(self, body, **kwargs): # noqa: E501
252+
"""get_quota_info # noqa: E501
253+
254+
This method makes a synchronous HTTP request by default. To make an
255+
asynchronous HTTP request, please pass async_req=True
256+
>>> thread = api.get_quota_info_with_http_info(body, async_req=True)
257+
>>> result = thread.get()
258+
259+
:param async_req bool
260+
:param GetQuotaInfoRequest body: (required)
261+
:return: GetQuotaInfoResponse
262+
If the method is called asynchronously,
263+
returns the request thread.
264+
"""
265+
266+
all_params = ['body'] # noqa: E501
267+
all_params.append('async_req')
268+
all_params.append('_return_http_data_only')
269+
all_params.append('_preload_content')
270+
all_params.append('_request_timeout')
271+
272+
params = locals()
273+
for key, val in six.iteritems(params['kwargs']):
274+
if key not in all_params:
275+
raise TypeError(
276+
"Got an unexpected keyword argument '%s'"
277+
" to method get_quota_info" % key
278+
)
279+
params[key] = val
280+
del params['kwargs']
281+
# verify the required parameter 'body' is set
282+
if self.api_client.client_side_validation and ('body' not in params or
283+
params['body'] is None): # noqa: E501
284+
raise ValueError("Missing the required parameter `body` when calling `get_quota_info`") # noqa: E501
285+
286+
collection_formats = {}
287+
288+
path_params = {}
289+
290+
query_params = []
291+
292+
header_params = {}
293+
294+
form_params = []
295+
local_var_files = {}
296+
297+
body_params = None
298+
if 'body' in params:
299+
body_params = params['body']
300+
# HTTP header `Accept`
301+
header_params['Accept'] = self.api_client.select_header_accept(
302+
['application/json']) # noqa: E501
303+
304+
# HTTP header `Content-Type`
305+
header_params['Content-Type'] = self.api_client.select_header_content_type( # noqa: E501
306+
['application/json']) # noqa: E501
307+
308+
# Authentication setting
309+
auth_settings = ['volcengineSign'] # noqa: E501
310+
311+
return self.api_client.call_api(
312+
'/GetQuotaInfo/2024-07-31/tis/post/application_json/', 'POST',
313+
path_params,
314+
query_params,
315+
header_params,
316+
body=body_params,
317+
post_params=form_params,
318+
files=local_var_files,
319+
response_type='GetQuotaInfoResponse', # noqa: E501
320+
auth_settings=auth_settings,
321+
async_req=params.get('async_req'),
322+
_return_http_data_only=params.get('_return_http_data_only'),
323+
_preload_content=params.get('_preload_content', True),
324+
_request_timeout=params.get('_request_timeout'),
325+
collection_formats=collection_formats)

0 commit comments

Comments
 (0)