Skip to content

Commit 6d33446

Browse files
committed
feat: update vpc api
1 parent 0ee6f2c commit 6d33446

File tree

3 files changed

+236
-5
lines changed

3 files changed

+236
-5
lines changed

volcenginesdkvpc/models/bandwidth_package_for_describe_bandwidth_packages_output.py

Lines changed: 53 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,11 @@ class BandwidthPackageForDescribeBandwidthPackagesOutput(object):
4242
'deleted_time': 'str',
4343
'description': 'str',
4444
'eip_addresses': 'list[EipAddressForDescribeBandwidthPackagesOutput]',
45+
'expired_time': 'str',
4546
'isp': 'str',
4647
'overdue_time': 'str',
4748
'project_name': 'str',
49+
'protocol': 'str',
4850
'security_protection_types': 'list[str]',
4951
'status': 'str',
5052
'tags': 'list[TagForDescribeBandwidthPackagesOutput]',
@@ -61,16 +63,18 @@ class BandwidthPackageForDescribeBandwidthPackagesOutput(object):
6163
'deleted_time': 'DeletedTime',
6264
'description': 'Description',
6365
'eip_addresses': 'EipAddresses',
66+
'expired_time': 'ExpiredTime',
6467
'isp': 'ISP',
6568
'overdue_time': 'OverdueTime',
6669
'project_name': 'ProjectName',
70+
'protocol': 'Protocol',
6771
'security_protection_types': 'SecurityProtectionTypes',
6872
'status': 'Status',
6973
'tags': 'Tags',
7074
'update_time': 'UpdateTime'
7175
}
7276

73-
def __init__(self, bandwidth=None, bandwidth_package_id=None, bandwidth_package_name=None, billing_type=None, business_status=None, creation_time=None, deleted_time=None, description=None, eip_addresses=None, isp=None, overdue_time=None, project_name=None, security_protection_types=None, status=None, tags=None, update_time=None, _configuration=None): # noqa: E501
77+
def __init__(self, bandwidth=None, bandwidth_package_id=None, bandwidth_package_name=None, billing_type=None, business_status=None, creation_time=None, deleted_time=None, description=None, eip_addresses=None, expired_time=None, isp=None, overdue_time=None, project_name=None, protocol=None, security_protection_types=None, status=None, tags=None, update_time=None, _configuration=None): # noqa: E501
7478
"""BandwidthPackageForDescribeBandwidthPackagesOutput - a model defined in Swagger""" # noqa: E501
7579
if _configuration is None:
7680
_configuration = Configuration()
@@ -85,9 +89,11 @@ def __init__(self, bandwidth=None, bandwidth_package_id=None, bandwidth_package_
8589
self._deleted_time = None
8690
self._description = None
8791
self._eip_addresses = None
92+
self._expired_time = None
8893
self._isp = None
8994
self._overdue_time = None
9095
self._project_name = None
96+
self._protocol = None
9197
self._security_protection_types = None
9298
self._status = None
9399
self._tags = None
@@ -112,12 +118,16 @@ def __init__(self, bandwidth=None, bandwidth_package_id=None, bandwidth_package_
112118
self.description = description
113119
if eip_addresses is not None:
114120
self.eip_addresses = eip_addresses
121+
if expired_time is not None:
122+
self.expired_time = expired_time
115123
if isp is not None:
116124
self.isp = isp
117125
if overdue_time is not None:
118126
self.overdue_time = overdue_time
119127
if project_name is not None:
120128
self.project_name = project_name
129+
if protocol is not None:
130+
self.protocol = protocol
121131
if security_protection_types is not None:
122132
self.security_protection_types = security_protection_types
123133
if status is not None:
@@ -316,6 +326,27 @@ def eip_addresses(self, eip_addresses):
316326

317327
self._eip_addresses = eip_addresses
318328

329+
@property
330+
def expired_time(self):
331+
"""Gets the expired_time of this BandwidthPackageForDescribeBandwidthPackagesOutput. # noqa: E501
332+
333+
334+
:return: The expired_time of this BandwidthPackageForDescribeBandwidthPackagesOutput. # noqa: E501
335+
:rtype: str
336+
"""
337+
return self._expired_time
338+
339+
@expired_time.setter
340+
def expired_time(self, expired_time):
341+
"""Sets the expired_time of this BandwidthPackageForDescribeBandwidthPackagesOutput.
342+
343+
344+
:param expired_time: The expired_time of this BandwidthPackageForDescribeBandwidthPackagesOutput. # noqa: E501
345+
:type: str
346+
"""
347+
348+
self._expired_time = expired_time
349+
319350
@property
320351
def isp(self):
321352
"""Gets the isp of this BandwidthPackageForDescribeBandwidthPackagesOutput. # noqa: E501
@@ -379,6 +410,27 @@ def project_name(self, project_name):
379410

380411
self._project_name = project_name
381412

413+
@property
414+
def protocol(self):
415+
"""Gets the protocol of this BandwidthPackageForDescribeBandwidthPackagesOutput. # noqa: E501
416+
417+
418+
:return: The protocol of this BandwidthPackageForDescribeBandwidthPackagesOutput. # noqa: E501
419+
:rtype: str
420+
"""
421+
return self._protocol
422+
423+
@protocol.setter
424+
def protocol(self, protocol):
425+
"""Sets the protocol of this BandwidthPackageForDescribeBandwidthPackagesOutput.
426+
427+
428+
:param protocol: The protocol of this BandwidthPackageForDescribeBandwidthPackagesOutput. # noqa: E501
429+
:type: str
430+
"""
431+
432+
self._protocol = protocol
433+
382434
@property
383435
def security_protection_types(self):
384436
"""Gets the security_protection_types of this BandwidthPackageForDescribeBandwidthPackagesOutput. # noqa: E501

volcenginesdkvpc/models/create_bandwidth_package_request.py

Lines changed: 94 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,10 @@ class CreateBandwidthPackageRequest(object):
3838
'billing_type': 'int',
3939
'description': 'str',
4040
'isp': 'str',
41+
'period': 'int',
42+
'period_unit': 'int',
4143
'project_name': 'str',
44+
'protocol': 'str',
4245
'security_protection_types': 'list[str]',
4346
'tags': 'list[TagForCreateBandwidthPackageInput]'
4447
}
@@ -49,12 +52,15 @@ class CreateBandwidthPackageRequest(object):
4952
'billing_type': 'BillingType',
5053
'description': 'Description',
5154
'isp': 'ISP',
55+
'period': 'Period',
56+
'period_unit': 'PeriodUnit',
5257
'project_name': 'ProjectName',
58+
'protocol': 'Protocol',
5359
'security_protection_types': 'SecurityProtectionTypes',
5460
'tags': 'Tags'
5561
}
5662

57-
def __init__(self, bandwidth=None, bandwidth_package_name=None, billing_type=None, description=None, isp=None, project_name=None, security_protection_types=None, tags=None, _configuration=None): # noqa: E501
63+
def __init__(self, bandwidth=None, bandwidth_package_name=None, billing_type=None, description=None, isp=None, period=None, period_unit=None, project_name=None, protocol=None, security_protection_types=None, tags=None, _configuration=None): # noqa: E501
5864
"""CreateBandwidthPackageRequest - a model defined in Swagger""" # noqa: E501
5965
if _configuration is None:
6066
_configuration = Configuration()
@@ -65,7 +71,10 @@ def __init__(self, bandwidth=None, bandwidth_package_name=None, billing_type=Non
6571
self._billing_type = None
6672
self._description = None
6773
self._isp = None
74+
self._period = None
75+
self._period_unit = None
6876
self._project_name = None
77+
self._protocol = None
6978
self._security_protection_types = None
7079
self._tags = None
7180
self.discriminator = None
@@ -79,8 +88,14 @@ def __init__(self, bandwidth=None, bandwidth_package_name=None, billing_type=Non
7988
self.description = description
8089
if isp is not None:
8190
self.isp = isp
91+
if period is not None:
92+
self.period = period
93+
if period_unit is not None:
94+
self.period_unit = period_unit
8295
if project_name is not None:
8396
self.project_name = project_name
97+
if protocol is not None:
98+
self.protocol = protocol
8499
if security_protection_types is not None:
85100
self.security_protection_types = security_protection_types
86101
if tags is not None:
@@ -164,8 +179,8 @@ def billing_type(self, billing_type):
164179
billing_type is not None and billing_type > 4): # noqa: E501
165180
raise ValueError("Invalid value for `billing_type`, must be a value less than or equal to `4`") # noqa: E501
166181
if (self._configuration.client_side_validation and
167-
billing_type is not None and billing_type < 2): # noqa: E501
168-
raise ValueError("Invalid value for `billing_type`, must be a value greater than or equal to `2`") # noqa: E501
182+
billing_type is not None and billing_type < 1): # noqa: E501
183+
raise ValueError("Invalid value for `billing_type`, must be a value greater than or equal to `1`") # noqa: E501
169184

170185
self._billing_type = billing_type
171186

@@ -224,6 +239,54 @@ def isp(self, isp):
224239

225240
self._isp = isp
226241

242+
@property
243+
def period(self):
244+
"""Gets the period of this CreateBandwidthPackageRequest. # noqa: E501
245+
246+
247+
:return: The period of this CreateBandwidthPackageRequest. # noqa: E501
248+
:rtype: int
249+
"""
250+
return self._period
251+
252+
@period.setter
253+
def period(self, period):
254+
"""Sets the period of this CreateBandwidthPackageRequest.
255+
256+
257+
:param period: The period of this CreateBandwidthPackageRequest. # noqa: E501
258+
:type: int
259+
"""
260+
261+
self._period = period
262+
263+
@property
264+
def period_unit(self):
265+
"""Gets the period_unit of this CreateBandwidthPackageRequest. # noqa: E501
266+
267+
268+
:return: The period_unit of this CreateBandwidthPackageRequest. # noqa: E501
269+
:rtype: int
270+
"""
271+
return self._period_unit
272+
273+
@period_unit.setter
274+
def period_unit(self, period_unit):
275+
"""Sets the period_unit of this CreateBandwidthPackageRequest.
276+
277+
278+
:param period_unit: The period_unit of this CreateBandwidthPackageRequest. # noqa: E501
279+
:type: int
280+
"""
281+
if (self._configuration.client_side_validation and
282+
period_unit is not None and period_unit > 2): # noqa: E501
283+
raise ValueError("Invalid value for `period_unit`, must be a value less than or equal to `2`") # noqa: E501
284+
if (self._configuration.client_side_validation and
285+
period_unit is not None and period_unit < 1): # noqa: E501
286+
raise ValueError("Invalid value for `period_unit`, must be a value greater than or equal to `1`") # noqa: E501
287+
288+
self._period_unit = period_unit
289+
227290
@property
228291
def project_name(self):
229292
"""Gets the project_name of this CreateBandwidthPackageRequest. # noqa: E501
@@ -245,6 +308,34 @@ def project_name(self, project_name):
245308

246309
self._project_name = project_name
247310

311+
@property
312+
def protocol(self):
313+
"""Gets the protocol of this CreateBandwidthPackageRequest. # noqa: E501
314+
315+
316+
:return: The protocol of this CreateBandwidthPackageRequest. # noqa: E501
317+
:rtype: str
318+
"""
319+
return self._protocol
320+
321+
@protocol.setter
322+
def protocol(self, protocol):
323+
"""Sets the protocol of this CreateBandwidthPackageRequest.
324+
325+
326+
:param protocol: The protocol of this CreateBandwidthPackageRequest. # noqa: E501
327+
:type: str
328+
"""
329+
allowed_values = ["IPv4", "IPv6"] # noqa: E501
330+
if (self._configuration.client_side_validation and
331+
protocol not in allowed_values):
332+
raise ValueError(
333+
"Invalid value for `protocol` ({0}), must be one of {1}" # noqa: E501
334+
.format(protocol, allowed_values)
335+
)
336+
337+
self._protocol = protocol
338+
248339
@property
249340
def security_protection_types(self):
250341
"""Gets the security_protection_types of this CreateBandwidthPackageRequest. # noqa: E501

0 commit comments

Comments
 (0)