baiducloud-python-sdk-rds 0.0.4__py3-none-any.whl → 0.0.5__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- baiducloud_python_sdk_rds/__init__.py +1 -1
- baiducloud_python_sdk_rds/api/rds_client.py +36 -94
- baiducloud_python_sdk_rds/models/__init__.py +3 -12
- baiducloud_python_sdk_rds/models/instance.py +1 -1
- baiducloud_python_sdk_rds/models/instance_enables_automatic_renewal_request.py +76 -0
- baiducloud_python_sdk_rds/models/{query_the_details_of_the_specified_instance_request.py → renewal_example_request.py} +21 -11
- baiducloud_python_sdk_rds/models/renewal_example_response.py +61 -0
- {baiducloud_python_sdk_rds-0.0.4.dist-info → baiducloud_python_sdk_rds-0.0.5.dist-info}/METADATA +1 -1
- {baiducloud_python_sdk_rds-0.0.4.dist-info → baiducloud_python_sdk_rds-0.0.5.dist-info}/RECORD +12 -17
- baiducloud_python_sdk_rds/models/get_new_purchase_price_request.py +0 -85
- baiducloud_python_sdk_rds/models/get_new_purchase_price_response.py +0 -118
- baiducloud_python_sdk_rds/models/instance_subnet.py +0 -98
- baiducloud_python_sdk_rds/models/obtain_the_price_difference_of_prepaid_transformer_request.py +0 -102
- baiducloud_python_sdk_rds/models/obtain_the_price_difference_of_prepaid_transformer_response.py +0 -118
- baiducloud_python_sdk_rds/models/query_the_details_of_the_specified_instance_response.py +0 -1160
- baiducloud_python_sdk_rds/models/zone_migration_request.py +0 -99
- {baiducloud_python_sdk_rds-0.0.4.dist-info → baiducloud_python_sdk_rds-0.0.5.dist-info}/LICENSE +0 -0
- {baiducloud_python_sdk_rds-0.0.4.dist-info → baiducloud_python_sdk_rds-0.0.5.dist-info}/WHEEL +0 -0
- {baiducloud_python_sdk_rds-0.0.4.dist-info → baiducloud_python_sdk_rds-0.0.5.dist-info}/top_level.txt +0 -0
|
@@ -22,20 +22,14 @@ from baiducloud_python_sdk_rds.models.dial_test_interface_response import DialTe
|
|
|
22
22
|
from baiducloud_python_sdk_rds.models.does_the_instance_support_enabling_automatic_expansion_response import (
|
|
23
23
|
DoesTheInstanceSupportEnablingAutomaticExpansionResponse,
|
|
24
24
|
)
|
|
25
|
-
from baiducloud_python_sdk_rds.models.get_new_purchase_price_response import GetNewPurchasePriceResponse
|
|
26
|
-
from baiducloud_python_sdk_rds.models.obtain_the_price_difference_of_prepaid_transformer_response import (
|
|
27
|
-
ObtainThePriceDifferenceOfPrepaidTransformerResponse,
|
|
28
|
-
)
|
|
29
25
|
from baiducloud_python_sdk_rds.models.query_instance_list_response import QueryInstanceListResponse
|
|
30
26
|
from baiducloud_python_sdk_rds.models.query_subnet_list_response import QuerySubnetListResponse
|
|
31
27
|
from baiducloud_python_sdk_rds.models.query_task_list_response import QueryTaskListResponse
|
|
32
|
-
from baiducloud_python_sdk_rds.models.query_the_details_of_the_specified_instance_response import (
|
|
33
|
-
QueryTheDetailsOfTheSpecifiedInstanceResponse,
|
|
34
|
-
)
|
|
35
28
|
from baiducloud_python_sdk_rds.models.query_the_list_of_available_zones_response import (
|
|
36
29
|
QueryTheListOfAvailableZonesResponse,
|
|
37
30
|
)
|
|
38
31
|
from baiducloud_python_sdk_rds.models.release_instance_response import ReleaseInstanceResponse
|
|
32
|
+
from baiducloud_python_sdk_rds.models.renewal_example_response import RenewalExampleResponse
|
|
39
33
|
from baiducloud_python_sdk_rds.models.retrieve_instance_auto_scaling_config_response import (
|
|
40
34
|
RetrieveInstanceAutoScalingConfigResponse,
|
|
41
35
|
)
|
|
@@ -67,11 +61,7 @@ class RdsClient(BceBaseClient):
|
|
|
67
61
|
|
|
68
62
|
CONSTANT_TASK = b'task'
|
|
69
63
|
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
CONSTANT_PRICE = b'price'
|
|
73
|
-
|
|
74
|
-
CONSTANT_DIFF = b'diff'
|
|
64
|
+
CONSTANT_RENEW = b'renew'
|
|
75
65
|
|
|
76
66
|
CONSTANT_AUTO_RESIZE_CONFIG = b'autoResizeConfig'
|
|
77
67
|
|
|
@@ -304,58 +294,28 @@ class RdsClient(BceBaseClient):
|
|
|
304
294
|
model=DoesTheInstanceSupportEnablingAutomaticExpansionResponse,
|
|
305
295
|
)
|
|
306
296
|
|
|
307
|
-
def
|
|
308
|
-
"""
|
|
309
|
-
get_new_purchase_price
|
|
310
|
-
|
|
311
|
-
:param request: Request entity containing all parameters
|
|
312
|
-
:type request: RdsClientRequest
|
|
313
|
-
:param config: Optional request configuration override
|
|
314
|
-
:type config: baiducloud_python_sdk_core.BceClientConfiguration
|
|
315
|
-
|
|
316
|
-
:return: API response containing GetNewPurchasePriceResponse data
|
|
317
|
-
:rtype: GetNewPurchasePriceResponse
|
|
318
|
-
|
|
319
|
-
:raises BceClientError: Client error (network failure, invalid parameters, etc.)
|
|
320
|
-
:raises BceServerError: Server error (4xx/5xx HTTP status codes)
|
|
321
|
-
"""
|
|
322
|
-
path = utils.append_uri(RdsClient.VERSION_V1, RdsClient.CONSTANT_INSTANCE, RdsClient.CONSTANT_PRICE)
|
|
323
|
-
headers = None
|
|
324
|
-
merged_config = self._create_request_with_host(request, config)
|
|
325
|
-
return self._send_request(
|
|
326
|
-
http_methods.POST,
|
|
327
|
-
path=path,
|
|
328
|
-
body=request.to_json_string(),
|
|
329
|
-
config=merged_config,
|
|
330
|
-
model=GetNewPurchasePriceResponse,
|
|
331
|
-
)
|
|
332
|
-
|
|
333
|
-
def obtain_the_price_difference_of_prepaid_transformer(self, request, config=None):
|
|
297
|
+
def instance_enables_automatic_renewal(self, request, config=None):
|
|
334
298
|
"""
|
|
335
|
-
|
|
299
|
+
instance_enables_automatic_renewal
|
|
336
300
|
|
|
337
301
|
:param request: Request entity containing all parameters
|
|
338
302
|
:type request: RdsClientRequest
|
|
339
303
|
:param config: Optional request configuration override
|
|
340
304
|
:type config: baiducloud_python_sdk_core.BceClientConfiguration
|
|
341
305
|
|
|
342
|
-
:return: API response
|
|
343
|
-
:rtype:
|
|
306
|
+
:return: API response
|
|
307
|
+
:rtype: baiducloud_python_sdk_core.bce_response.BceResponse
|
|
344
308
|
|
|
345
309
|
:raises BceClientError: Client error (network failure, invalid parameters, etc.)
|
|
346
310
|
:raises BceServerError: Server error (4xx/5xx HTTP status codes)
|
|
347
311
|
"""
|
|
348
|
-
path = utils.append_uri(
|
|
349
|
-
RdsClient.VERSION_V1, RdsClient.CONSTANT_INSTANCE, RdsClient.CONSTANT_PRICE, RdsClient.CONSTANT_DIFF
|
|
350
|
-
)
|
|
312
|
+
path = utils.append_uri(RdsClient.VERSION_V1, RdsClient.CONSTANT_INSTANCE)
|
|
351
313
|
headers = None
|
|
314
|
+
params = {}
|
|
315
|
+
params['autoRenew'] = None
|
|
352
316
|
merged_config = self._create_request_with_host(request, config)
|
|
353
317
|
return self._send_request(
|
|
354
|
-
http_methods.
|
|
355
|
-
path=path,
|
|
356
|
-
body=request.to_json_string(),
|
|
357
|
-
config=merged_config,
|
|
358
|
-
model=ObtainThePriceDifferenceOfPrepaidTransformerResponse,
|
|
318
|
+
http_methods.PUT, path=path, body=request.to_json_string(), params=params, config=merged_config
|
|
359
319
|
)
|
|
360
320
|
|
|
361
321
|
def query_instance_list(self, request, config=None):
|
|
@@ -440,28 +400,6 @@ class RdsClient(BceBaseClient):
|
|
|
440
400
|
model=QueryTaskListResponse,
|
|
441
401
|
)
|
|
442
402
|
|
|
443
|
-
def query_the_details_of_the_specified_instance(self, request, config=None):
|
|
444
|
-
"""
|
|
445
|
-
query_the_details_of_the_specified_instance
|
|
446
|
-
|
|
447
|
-
:param request: Request entity containing all parameters
|
|
448
|
-
:type request: RdsClientRequest
|
|
449
|
-
:param config: Optional request configuration override
|
|
450
|
-
:type config: baiducloud_python_sdk_core.BceClientConfiguration
|
|
451
|
-
|
|
452
|
-
:return: API response containing QueryTheDetailsOfTheSpecifiedInstanceResponse data
|
|
453
|
-
:rtype: QueryTheDetailsOfTheSpecifiedInstanceResponse
|
|
454
|
-
|
|
455
|
-
:raises BceClientError: Client error (network failure, invalid parameters, etc.)
|
|
456
|
-
:raises BceServerError: Server error (4xx/5xx HTTP status codes)
|
|
457
|
-
"""
|
|
458
|
-
path = utils.append_uri(RdsClient.VERSION_V1, RdsClient.CONSTANT_INSTANCE, request.instance_id)
|
|
459
|
-
headers = None
|
|
460
|
-
merged_config = self._create_request_with_host(request, config)
|
|
461
|
-
return self._send_request(
|
|
462
|
-
http_methods.GET, path=path, config=merged_config, model=QueryTheDetailsOfTheSpecifiedInstanceResponse
|
|
463
|
-
)
|
|
464
|
-
|
|
465
403
|
def query_the_list_of_available_zones(self, config=None):
|
|
466
404
|
"""
|
|
467
405
|
query_the_list_of_available_zones
|
|
@@ -500,6 +438,32 @@ class RdsClient(BceBaseClient):
|
|
|
500
438
|
merged_config = self._create_request_with_host(request, config)
|
|
501
439
|
return self._send_request(http_methods.DELETE, path=path, config=merged_config, model=ReleaseInstanceResponse)
|
|
502
440
|
|
|
441
|
+
def renewal_example(self, request, config=None):
|
|
442
|
+
"""
|
|
443
|
+
renewal_example
|
|
444
|
+
|
|
445
|
+
:param request: Request entity containing all parameters
|
|
446
|
+
:type request: RdsClientRequest
|
|
447
|
+
:param config: Optional request configuration override
|
|
448
|
+
:type config: baiducloud_python_sdk_core.BceClientConfiguration
|
|
449
|
+
|
|
450
|
+
:return: API response containing RenewalExampleResponse data
|
|
451
|
+
:rtype: RenewalExampleResponse
|
|
452
|
+
|
|
453
|
+
:raises BceClientError: Client error (network failure, invalid parameters, etc.)
|
|
454
|
+
:raises BceServerError: Server error (4xx/5xx HTTP status codes)
|
|
455
|
+
"""
|
|
456
|
+
path = utils.append_uri(b'/', RdsClient.CONSTANT_V1, RdsClient.CONSTANT_INSTANCE, RdsClient.CONSTANT_RENEW)
|
|
457
|
+
headers = None
|
|
458
|
+
merged_config = self._create_request_with_host(request, config)
|
|
459
|
+
return self._send_request(
|
|
460
|
+
http_methods.POST,
|
|
461
|
+
path=path,
|
|
462
|
+
body=request.to_json_string(),
|
|
463
|
+
config=merged_config,
|
|
464
|
+
model=RenewalExampleResponse,
|
|
465
|
+
)
|
|
466
|
+
|
|
503
467
|
def restart_the_instance(self, request, config=None):
|
|
504
468
|
"""
|
|
505
469
|
restart_the_instance
|
|
@@ -725,28 +689,6 @@ class RdsClient(BceBaseClient):
|
|
|
725
689
|
merged_config = self._create_request_with_host(request, config)
|
|
726
690
|
return self._send_request(http_methods.PUT, path=path, body=request.to_json_string(), config=merged_config)
|
|
727
691
|
|
|
728
|
-
def zone_migration(self, request, config=None):
|
|
729
|
-
"""
|
|
730
|
-
zone_migration
|
|
731
|
-
|
|
732
|
-
:param request: Request entity containing all parameters
|
|
733
|
-
:type request: RdsClientRequest
|
|
734
|
-
:param config: Optional request configuration override
|
|
735
|
-
:type config: baiducloud_python_sdk_core.BceClientConfiguration
|
|
736
|
-
|
|
737
|
-
:return: API response
|
|
738
|
-
:rtype: baiducloud_python_sdk_core.bce_response.BceResponse
|
|
739
|
-
|
|
740
|
-
:raises BceClientError: Client error (network failure, invalid parameters, etc.)
|
|
741
|
-
:raises BceServerError: Server error (4xx/5xx HTTP status codes)
|
|
742
|
-
"""
|
|
743
|
-
path = utils.append_uri(
|
|
744
|
-
RdsClient.VERSION_V1, RdsClient.CONSTANT_INSTANCE, request.instance_id, RdsClient.CONSTANT_AZONE_MIGRATION
|
|
745
|
-
)
|
|
746
|
-
headers = None
|
|
747
|
-
merged_config = self._create_request_with_host(request, config)
|
|
748
|
-
return self._send_request(http_methods.PUT, path=path, body=request.to_json_string(), config=merged_config)
|
|
749
|
-
|
|
750
692
|
def _merge_config(self, config=None):
|
|
751
693
|
"""
|
|
752
694
|
:param config:
|
|
@@ -25,30 +25,23 @@ from .does_the_instance_support_enabling_automatic_expansion_response import (
|
|
|
25
25
|
)
|
|
26
26
|
from .encrypt_strategy import EncryptStrategy
|
|
27
27
|
from .endpoint import Endpoint
|
|
28
|
-
from .get_new_purchase_price_request import GetNewPurchasePriceRequest
|
|
29
|
-
from .get_new_purchase_price_response import GetNewPurchasePriceResponse
|
|
30
28
|
from .initial_data_reference import InitialDataReference
|
|
31
29
|
from .instance import Instance
|
|
32
30
|
from .instance_dict import InstanceDict
|
|
33
|
-
from .
|
|
31
|
+
from .instance_enables_automatic_renewal_request import InstanceEnablesAutomaticRenewalRequest
|
|
34
32
|
from .machine_po import MachinePO
|
|
35
33
|
from .master_id_mapping import MasterIdMapping
|
|
36
|
-
from .obtain_the_price_difference_of_prepaid_transformer_request import (
|
|
37
|
-
ObtainThePriceDifferenceOfPrepaidTransformerRequest,
|
|
38
|
-
)
|
|
39
|
-
from .obtain_the_price_difference_of_prepaid_transformer_response import (
|
|
40
|
-
ObtainThePriceDifferenceOfPrepaidTransformerResponse,
|
|
41
|
-
)
|
|
42
34
|
from .progress import Progress
|
|
43
35
|
from .query_instance_list_response import QueryInstanceListResponse
|
|
44
36
|
from .query_subnet_list_response import QuerySubnetListResponse
|
|
45
37
|
from .query_task_list_request import QueryTaskListRequest
|
|
46
38
|
from .query_task_list_response import QueryTaskListResponse
|
|
47
|
-
from .query_the_details_of_the_specified_instance_response import QueryTheDetailsOfTheSpecifiedInstanceResponse
|
|
48
39
|
from .query_the_list_of_available_zones_response import QueryTheListOfAvailableZonesResponse
|
|
49
40
|
from .read_replica_id_mapping import ReadReplicaIdMapping
|
|
50
41
|
from .recovery_to_source_instance_model import RecoveryToSourceInstanceModel
|
|
51
42
|
from .release_instance_response import ReleaseInstanceResponse
|
|
43
|
+
from .renewal_example_request import RenewalExampleRequest
|
|
44
|
+
from .renewal_example_response import RenewalExampleResponse
|
|
52
45
|
from .replica_request import ReplicaRequest
|
|
53
46
|
from .resource import Resource
|
|
54
47
|
from .resource_group import ResourceGroup
|
|
@@ -77,12 +70,10 @@ from .update_instance_public_network_access_status_request import UpdateInstance
|
|
|
77
70
|
from .update_instance_synchronization_mode_request import UpdateInstanceSynchronizationModeRequest
|
|
78
71
|
from .update_time_window_request import UpdateTimeWindowRequest
|
|
79
72
|
from .zone_detail import ZoneDetail
|
|
80
|
-
from .zone_migration_request import ZoneMigrationRequest
|
|
81
73
|
from .cluster_status_check_request import ClusterStatusCheckRequest
|
|
82
74
|
from .query_instance_list_request import QueryInstanceListRequest
|
|
83
75
|
from .dial_test_interface_request import DialTestInterfaceRequest
|
|
84
76
|
from .release_instance_request import ReleaseInstanceRequest
|
|
85
|
-
from .query_the_details_of_the_specified_instance_request import QueryTheDetailsOfTheSpecifiedInstanceRequest
|
|
86
77
|
from .retrieve_instance_auto_scaling_config_request import RetrieveInstanceAutoScalingConfigRequest
|
|
87
78
|
from .query_subnet_list_request import QuerySubnetListRequest
|
|
88
79
|
from .does_the_instance_support_enabling_automatic_expansion_request import (
|
|
@@ -316,7 +316,7 @@ class Instance(AbstractModel):
|
|
|
316
316
|
:type dcc_host_ids: DccHostInfo (optional)
|
|
317
317
|
|
|
318
318
|
:param machine_type: 主机类型,默认只有dcc
|
|
319
|
-
:type machine_type:
|
|
319
|
+
:type machine_type: str (optional)
|
|
320
320
|
|
|
321
321
|
:param weight: 权重
|
|
322
322
|
:type weight: int (optional)
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Request entity for InstanceEnablesAutomaticRenewalRequest information.
|
|
3
|
+
"""
|
|
4
|
+
|
|
5
|
+
from baiducloud_python_sdk_core.abstract_model import AbstractModel
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class InstanceEnablesAutomaticRenewalRequest(AbstractModel):
|
|
9
|
+
"""
|
|
10
|
+
Request entity for InstanceEnablesAutomaticRenewalRequest operation.
|
|
11
|
+
|
|
12
|
+
This class encapsulates all parameters for the API request.
|
|
13
|
+
"""
|
|
14
|
+
|
|
15
|
+
def __init__(self, instance_ids=None, auto_renew_time_unit=None, auto_renew_time=None):
|
|
16
|
+
"""
|
|
17
|
+
Initialize InstanceEnablesAutomaticRenewalRequest request entity.
|
|
18
|
+
|
|
19
|
+
:param instance_ids: 实例ID列表
|
|
20
|
+
:type instance_ids: List[str] (optional)
|
|
21
|
+
|
|
22
|
+
:param auto_renew_time_unit: 自动续费周期单位(年:year;月:month)
|
|
23
|
+
:type auto_renew_time_unit: str (optional)
|
|
24
|
+
|
|
25
|
+
:param auto_renew_time: 续费周期按月(不超过9个月)按年付费(不超过3年)
|
|
26
|
+
:type auto_renew_time: int (optional)
|
|
27
|
+
"""
|
|
28
|
+
super().__init__()
|
|
29
|
+
self.instance_ids = instance_ids
|
|
30
|
+
self.auto_renew_time_unit = auto_renew_time_unit
|
|
31
|
+
self.auto_renew_time = auto_renew_time
|
|
32
|
+
|
|
33
|
+
def to_dict(self):
|
|
34
|
+
"""
|
|
35
|
+
Convert the request entity to a dictionary representation.
|
|
36
|
+
|
|
37
|
+
Nested model objects are recursively converted to dictionaries.
|
|
38
|
+
|
|
39
|
+
:return: Dictionary representation of the request
|
|
40
|
+
:rtype: dict
|
|
41
|
+
"""
|
|
42
|
+
_map = super().to_dict()
|
|
43
|
+
if _map is not None:
|
|
44
|
+
return _map
|
|
45
|
+
result = dict()
|
|
46
|
+
if self.instance_ids is not None:
|
|
47
|
+
result['instanceIds'] = self.instance_ids
|
|
48
|
+
if self.auto_renew_time_unit is not None:
|
|
49
|
+
result['autoRenewTimeUnit'] = self.auto_renew_time_unit
|
|
50
|
+
if self.auto_renew_time is not None:
|
|
51
|
+
result['autoRenewTime'] = self.auto_renew_time
|
|
52
|
+
return result
|
|
53
|
+
|
|
54
|
+
def from_dict(self, m):
|
|
55
|
+
"""
|
|
56
|
+
Populate the request entity from a dictionary.
|
|
57
|
+
|
|
58
|
+
Nested dictionaries are recursively converted to model objects.
|
|
59
|
+
|
|
60
|
+
:param m: Dictionary containing request data
|
|
61
|
+
:type m: dict
|
|
62
|
+
|
|
63
|
+
:return: Self reference for method chaining
|
|
64
|
+
:rtype: InstanceEnablesAutomaticRenewalRequest
|
|
65
|
+
|
|
66
|
+
:raises TypeError: If input is not a dictionary or field type mismatch
|
|
67
|
+
:raises ValueError: If nested model conversion fails
|
|
68
|
+
"""
|
|
69
|
+
m = m or dict()
|
|
70
|
+
if m.get('instanceIds') is not None:
|
|
71
|
+
self.instance_ids = m.get('instanceIds')
|
|
72
|
+
if m.get('autoRenewTimeUnit') is not None:
|
|
73
|
+
self.auto_renew_time_unit = m.get('autoRenewTimeUnit')
|
|
74
|
+
if m.get('autoRenewTime') is not None:
|
|
75
|
+
self.auto_renew_time = m.get('autoRenewTime')
|
|
76
|
+
return self
|
|
@@ -1,26 +1,30 @@
|
|
|
1
1
|
"""
|
|
2
|
-
Request entity for
|
|
2
|
+
Request entity for RenewalExampleRequest information.
|
|
3
3
|
"""
|
|
4
4
|
|
|
5
5
|
from baiducloud_python_sdk_core.abstract_model import AbstractModel
|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
class
|
|
8
|
+
class RenewalExampleRequest(AbstractModel):
|
|
9
9
|
"""
|
|
10
|
-
Request entity for
|
|
10
|
+
Request entity for RenewalExampleRequest operation.
|
|
11
11
|
|
|
12
12
|
This class encapsulates all parameters for the API request.
|
|
13
13
|
"""
|
|
14
14
|
|
|
15
|
-
def __init__(self,
|
|
15
|
+
def __init__(self, duration, instance_ids):
|
|
16
16
|
"""
|
|
17
|
-
Initialize
|
|
17
|
+
Initialize RenewalExampleRequest request entity.
|
|
18
18
|
|
|
19
|
-
:param
|
|
20
|
-
:type
|
|
19
|
+
:param duration: 续费周期,单位为月
|
|
20
|
+
:type duration: int (required)
|
|
21
|
+
|
|
22
|
+
:param instance_ids: 实例ID列表
|
|
23
|
+
:type instance_ids: List[str] (required)
|
|
21
24
|
"""
|
|
22
25
|
super().__init__()
|
|
23
|
-
self.
|
|
26
|
+
self.duration = duration
|
|
27
|
+
self.instance_ids = instance_ids
|
|
24
28
|
|
|
25
29
|
def to_dict(self):
|
|
26
30
|
"""
|
|
@@ -35,6 +39,10 @@ class QueryTheDetailsOfTheSpecifiedInstanceRequest(AbstractModel):
|
|
|
35
39
|
if _map is not None:
|
|
36
40
|
return _map
|
|
37
41
|
result = dict()
|
|
42
|
+
if self.duration is not None:
|
|
43
|
+
result['duration'] = self.duration
|
|
44
|
+
if self.instance_ids is not None:
|
|
45
|
+
result['instanceIds'] = self.instance_ids
|
|
38
46
|
return result
|
|
39
47
|
|
|
40
48
|
def from_dict(self, m):
|
|
@@ -47,12 +55,14 @@ class QueryTheDetailsOfTheSpecifiedInstanceRequest(AbstractModel):
|
|
|
47
55
|
:type m: dict
|
|
48
56
|
|
|
49
57
|
:return: Self reference for method chaining
|
|
50
|
-
:rtype:
|
|
58
|
+
:rtype: RenewalExampleRequest
|
|
51
59
|
|
|
52
60
|
:raises TypeError: If input is not a dictionary or field type mismatch
|
|
53
61
|
:raises ValueError: If nested model conversion fails
|
|
54
62
|
"""
|
|
55
63
|
m = m or dict()
|
|
56
|
-
if m.get('
|
|
57
|
-
self.
|
|
64
|
+
if m.get('duration') is not None:
|
|
65
|
+
self.duration = m.get('duration')
|
|
66
|
+
if m.get('instanceIds') is not None:
|
|
67
|
+
self.instance_ids = m.get('instanceIds')
|
|
58
68
|
return self
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Request entity for RenewalExampleResponse information.
|
|
3
|
+
"""
|
|
4
|
+
|
|
5
|
+
from baiducloud_python_sdk_core.bce_response import BceResponse
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class RenewalExampleResponse(BceResponse):
|
|
9
|
+
"""
|
|
10
|
+
RenewalExampleResponse
|
|
11
|
+
"""
|
|
12
|
+
|
|
13
|
+
def __init__(self, order_id=None):
|
|
14
|
+
"""
|
|
15
|
+
Initialize RenewalExampleResponse response.
|
|
16
|
+
|
|
17
|
+
:param order_id: 续费订单ID
|
|
18
|
+
:type order_id: str (optional)
|
|
19
|
+
"""
|
|
20
|
+
super().__init__()
|
|
21
|
+
self.order_id = order_id
|
|
22
|
+
|
|
23
|
+
def to_dict(self):
|
|
24
|
+
"""
|
|
25
|
+
Convert the response instance to a dictionary representation.
|
|
26
|
+
|
|
27
|
+
Includes metadata from the parent BceResponse class.
|
|
28
|
+
Nested model objects are recursively converted to dictionaries.
|
|
29
|
+
|
|
30
|
+
:return: Dictionary representation of the response
|
|
31
|
+
:rtype: dict
|
|
32
|
+
"""
|
|
33
|
+
_map = super().to_dict()
|
|
34
|
+
if _map is not None:
|
|
35
|
+
return _map
|
|
36
|
+
result = dict()
|
|
37
|
+
if self.metadata is not None:
|
|
38
|
+
result['metadata'] = dict(self.metadata)
|
|
39
|
+
if self.order_id is not None:
|
|
40
|
+
result['orderId'] = self.order_id
|
|
41
|
+
return result
|
|
42
|
+
|
|
43
|
+
def from_dict(self, m):
|
|
44
|
+
"""
|
|
45
|
+
Populate the response instance from a dictionary.
|
|
46
|
+
|
|
47
|
+
Nested dictionaries are recursively converted to model objects.
|
|
48
|
+
|
|
49
|
+
:param m: Dictionary containing response data
|
|
50
|
+
:type m: dict
|
|
51
|
+
|
|
52
|
+
:return: Self reference for method chaining
|
|
53
|
+
:rtype: RenewalExampleResponse
|
|
54
|
+
|
|
55
|
+
:raises TypeError: If input is not a dictionary or field type mismatch
|
|
56
|
+
:raises ValueError: If nested model conversion fails
|
|
57
|
+
"""
|
|
58
|
+
m = m or dict()
|
|
59
|
+
if m.get('orderId') is not None:
|
|
60
|
+
self.order_id = m.get('orderId')
|
|
61
|
+
return self
|
{baiducloud_python_sdk_rds-0.0.4.dist-info → baiducloud_python_sdk_rds-0.0.5.dist-info}/RECORD
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
baiducloud_python_sdk_rds/__init__.py,sha256=
|
|
1
|
+
baiducloud_python_sdk_rds/__init__.py,sha256=DTcAOq3Jj_BUHKq5Qp-tOYl_OvB9zOGd6rQSG9njgqA,82
|
|
2
2
|
baiducloud_python_sdk_rds/api/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
3
|
-
baiducloud_python_sdk_rds/api/rds_client.py,sha256=
|
|
4
|
-
baiducloud_python_sdk_rds/models/__init__.py,sha256=
|
|
3
|
+
baiducloud_python_sdk_rds/api/rds_client.py,sha256=0K_qIyYQxYIc3p2aX1j43J4bYGUlfwpw3RJ2sgDqM94,30969
|
|
4
|
+
baiducloud_python_sdk_rds/models/__init__.py,sha256=tP30FfeUVul8CiKOHId3INVVA8QQgKZpFxBzUZSYMeE,4400
|
|
5
5
|
baiducloud_python_sdk_rds/models/app_list.py,sha256=OOL-zaQv_E8cnqUYaNIR7ntFal0qBEPK0ShGWsyKsLE,4423
|
|
6
6
|
baiducloud_python_sdk_rds/models/batch_configuration_of_instances_request.py,sha256=lqs9A7bRuA69dEHnS8Y3jzD5lDNmKmjpk_ghHbU0gy8,7796
|
|
7
7
|
baiducloud_python_sdk_rds/models/batch_configuration_of_instances_response.py,sha256=Epr3d7fBmQruqM90o2TBF6-cUPyuZoWvy1YC43HhT_A,1855
|
|
@@ -26,16 +26,12 @@ baiducloud_python_sdk_rds/models/does_the_instance_support_enabling_automatic_ex
|
|
|
26
26
|
baiducloud_python_sdk_rds/models/does_the_instance_support_enabling_automatic_expansion_response.py,sha256=PBIsCkgCFScl2oyYn-RjhyeP4uk5gMlWyGi0ZyxORe8,2213
|
|
27
27
|
baiducloud_python_sdk_rds/models/encrypt_strategy.py,sha256=ExM4J7PeIxCQ3JHh_O0LeqZ1B5bjd7gU-ngN4KQ7BGw,2877
|
|
28
28
|
baiducloud_python_sdk_rds/models/endpoint.py,sha256=3XIaK8yyw26rjyJiT6BNVHRDBiqyaakNLcFRqCeJ_qE,2921
|
|
29
|
-
baiducloud_python_sdk_rds/models/get_new_purchase_price_request.py,sha256=ZCw7sc06THUo8OhA69sNkgP5TkrbxYja8JbeVvJ-L4Q,2880
|
|
30
|
-
baiducloud_python_sdk_rds/models/get_new_purchase_price_response.py,sha256=EML4jd5kbS9MHgWFgDgyMTQ3iTeWLxes5URHHdgYeH4,3950
|
|
31
29
|
baiducloud_python_sdk_rds/models/initial_data_reference.py,sha256=37NFCXUf9e8okI9riJIo7g55QCJtyCXtwsoanjlsQCs,2671
|
|
32
|
-
baiducloud_python_sdk_rds/models/instance.py,sha256=
|
|
30
|
+
baiducloud_python_sdk_rds/models/instance.py,sha256=4hZ3mbfmOeqwcZUj2lpjKuHS1QefrJewKH1RR8ssKD4,45736
|
|
33
31
|
baiducloud_python_sdk_rds/models/instance_dict.py,sha256=XCxzhinxUb1ZD6dEZJABM5zT6rjKCA4PQkANONPAW_s,2297
|
|
34
|
-
baiducloud_python_sdk_rds/models/
|
|
32
|
+
baiducloud_python_sdk_rds/models/instance_enables_automatic_renewal_request.py,sha256=KQBgo5SBmeDO9NvbVwSscl9FvCdNXeLIUXnaKjdIxZ8,2706
|
|
35
33
|
baiducloud_python_sdk_rds/models/machine_po.py,sha256=z1FalL1WGW3yTgt4f4VyBulAEeyGAkw8TzQBpatUIfw,4865
|
|
36
34
|
baiducloud_python_sdk_rds/models/master_id_mapping.py,sha256=UsGBfR-ou15IptlNREnBhy-tS1B0wQF6ct25a5lZ-1w,3861
|
|
37
|
-
baiducloud_python_sdk_rds/models/obtain_the_price_difference_of_prepaid_transformer_request.py,sha256=UT8CcZJHnoYNm2fCfQi3OZiM_YlL1g37rx6EtLukc1c,3799
|
|
38
|
-
baiducloud_python_sdk_rds/models/obtain_the_price_difference_of_prepaid_transformer_response.py,sha256=IY0CYrbu3I2MZf4kwnhbKIwklABCm2xnfOVqFvoRVbw,4091
|
|
39
35
|
baiducloud_python_sdk_rds/models/progress.py,sha256=qsZvI6rE6IhifxhCsthdcG2Lj9BdK88K3OCi-Dw5v5w,3608
|
|
40
36
|
baiducloud_python_sdk_rds/models/query_instance_list_request.py,sha256=UGhjUpbsxKBwBVPc2X526rAo3X-wFkMZTmZ4tH6SbJ4,2024
|
|
41
37
|
baiducloud_python_sdk_rds/models/query_instance_list_response.py,sha256=KQFYJarA_WRseduZOSVUG88vTXVsIlVN4_RaMJv3HNI,3415
|
|
@@ -43,13 +39,13 @@ baiducloud_python_sdk_rds/models/query_subnet_list_request.py,sha256=lpaHvX-_TXQ
|
|
|
43
39
|
baiducloud_python_sdk_rds/models/query_subnet_list_response.py,sha256=0I6mjAbBazTb2PoE5ZMADSX0vpsmgqppVSnHLUbAR0k,1864
|
|
44
40
|
baiducloud_python_sdk_rds/models/query_task_list_request.py,sha256=4JEUmPpAkIay8at6kIXWnypioN7S1Z8ymqoEUD8opnA,4372
|
|
45
41
|
baiducloud_python_sdk_rds/models/query_task_list_response.py,sha256=2Dg5swZcTDAzeWcroXro7o0_c_PPhkrpC5j4JKtlYcA,2131
|
|
46
|
-
baiducloud_python_sdk_rds/models/query_the_details_of_the_specified_instance_request.py,sha256=o_M2R2bAGZnGpdCbDH1gXMW82FBl3U66k90yuET5myo,1735
|
|
47
|
-
baiducloud_python_sdk_rds/models/query_the_details_of_the_specified_instance_response.py,sha256=tKvysNUb6Y_Eu1WvtfD2EmiTjliZPSA7S__oWxTZmNg,49095
|
|
48
42
|
baiducloud_python_sdk_rds/models/query_the_list_of_available_zones_response.py,sha256=UimQvLsSWT50_7ifoU1GB12PbJgEPb7G3fSUYd__y1U,1918
|
|
49
43
|
baiducloud_python_sdk_rds/models/read_replica_id_mapping.py,sha256=KJ8gGJAe6Hwoiufe-W28h85EHF3DGCjQHLDZCFNRmcM,3886
|
|
50
44
|
baiducloud_python_sdk_rds/models/recovery_to_source_instance_model.py,sha256=sUwKr8oRZAyxlUMVCRt79s3tGji4-PJ0fzjW3phVbtA,2694
|
|
51
45
|
baiducloud_python_sdk_rds/models/release_instance_request.py,sha256=9Gp8uDS9A37F7k5zCHm3ikxcANpdpDri64W3LknD5XY,1634
|
|
52
46
|
baiducloud_python_sdk_rds/models/release_instance_response.py,sha256=zzxW05aoXwMKIFqNybmTsDzP3-Rn4sAzjFRjDmdcDMg,2631
|
|
47
|
+
baiducloud_python_sdk_rds/models/renewal_example_request.py,sha256=pN4ksVDVq8EZm7qJqRf7az6bYNVXwS9yeZzAR1bPbQI,2032
|
|
48
|
+
baiducloud_python_sdk_rds/models/renewal_example_response.py,sha256=fOMCy_KJg0qvl-9_pnOpTfCn-2LhcLF1mM8HgA37O5w,1736
|
|
53
49
|
baiducloud_python_sdk_rds/models/replica_request.py,sha256=dE9hSXZIcS9ix_j7oKpFDhLn3eslZmOV0mTRdpdrGq8,3039
|
|
54
50
|
baiducloud_python_sdk_rds/models/resource.py,sha256=oF-ZwES9w3HjGU8k_gklKzCv3-J_jPpMkJyxI6LT4yo,1879
|
|
55
51
|
baiducloud_python_sdk_rds/models/resource_group.py,sha256=H8oFKwSzZ1N_nUh5ae1a2lhL1ANlmXl_xG1oI89M_p0,4423
|
|
@@ -77,9 +73,8 @@ baiducloud_python_sdk_rds/models/update_instance_public_network_access_status_re
|
|
|
77
73
|
baiducloud_python_sdk_rds/models/update_instance_synchronization_mode_request.py,sha256=c-_5edBv3skaaoIW_3skCeMyFNyuZhB0zKsn8cTaE-Q,2075
|
|
78
74
|
baiducloud_python_sdk_rds/models/update_time_window_request.py,sha256=Zkki9rraINCnY-LxYM6wWJFu_ILglYbzwm043DadI1c,2613
|
|
79
75
|
baiducloud_python_sdk_rds/models/zone_detail.py,sha256=1H2p_JlMKucaCDRj2rDvZ50im5p6zyI6eUB5SMczNgg,5024
|
|
80
|
-
baiducloud_python_sdk_rds/
|
|
81
|
-
baiducloud_python_sdk_rds-0.0.
|
|
82
|
-
baiducloud_python_sdk_rds-0.0.
|
|
83
|
-
baiducloud_python_sdk_rds-0.0.
|
|
84
|
-
baiducloud_python_sdk_rds-0.0.
|
|
85
|
-
baiducloud_python_sdk_rds-0.0.4.dist-info/RECORD,,
|
|
76
|
+
baiducloud_python_sdk_rds-0.0.5.dist-info/LICENSE,sha256=vWvFalMLAgEWwNa8irw-tSDlh7k7bl4APjMGE_lGiws,10372
|
|
77
|
+
baiducloud_python_sdk_rds-0.0.5.dist-info/METADATA,sha256=lxDFKevhFh8mW9XND5yX99umugB5U6bqRY3xEBek5pc,2646
|
|
78
|
+
baiducloud_python_sdk_rds-0.0.5.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
|
|
79
|
+
baiducloud_python_sdk_rds-0.0.5.dist-info/top_level.txt,sha256=0qILxSFHEOGSJ-ZlGCQe1UlmggvvF0glErNBIodoZgc,26
|
|
80
|
+
baiducloud_python_sdk_rds-0.0.5.dist-info/RECORD,,
|
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
"""
|
|
2
|
-
Request entity for GetNewPurchasePriceRequest information.
|
|
3
|
-
"""
|
|
4
|
-
|
|
5
|
-
from baiducloud_python_sdk_core.abstract_model import AbstractModel
|
|
6
|
-
from baiducloud_python_sdk_rds.models.instance import Instance
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
class GetNewPurchasePriceRequest(AbstractModel):
|
|
10
|
-
"""
|
|
11
|
-
Request entity for GetNewPurchasePriceRequest operation.
|
|
12
|
-
|
|
13
|
-
This class encapsulates all parameters for the API request.
|
|
14
|
-
"""
|
|
15
|
-
|
|
16
|
-
def __init__(self, instance, product_type, duration=None, number=None):
|
|
17
|
-
"""
|
|
18
|
-
Initialize GetNewPurchasePriceRequest request entity.
|
|
19
|
-
|
|
20
|
-
:param instance: instance parameter
|
|
21
|
-
:type instance: Instance (required)
|
|
22
|
-
|
|
23
|
-
:param duration: 时长。支付方式为后支付时不需要设置,预支付时必须设置。时间单位默认为month。
|
|
24
|
-
:type duration: int (optional)
|
|
25
|
-
|
|
26
|
-
:param number: 购买数量,默认值为1。
|
|
27
|
-
:type number: int (optional)
|
|
28
|
-
|
|
29
|
-
:param product_type: 付费方式。 预付费:prepay,后付费:postpay。
|
|
30
|
-
:type product_type: str (required)
|
|
31
|
-
"""
|
|
32
|
-
super().__init__()
|
|
33
|
-
self.instance = instance
|
|
34
|
-
self.duration = duration
|
|
35
|
-
self.number = number
|
|
36
|
-
self.product_type = product_type
|
|
37
|
-
|
|
38
|
-
def to_dict(self):
|
|
39
|
-
"""
|
|
40
|
-
Convert the request entity to a dictionary representation.
|
|
41
|
-
|
|
42
|
-
Nested model objects are recursively converted to dictionaries.
|
|
43
|
-
|
|
44
|
-
:return: Dictionary representation of the request
|
|
45
|
-
:rtype: dict
|
|
46
|
-
"""
|
|
47
|
-
_map = super().to_dict()
|
|
48
|
-
if _map is not None:
|
|
49
|
-
return _map
|
|
50
|
-
result = dict()
|
|
51
|
-
if self.instance is not None:
|
|
52
|
-
result['instance'] = self.instance.to_dict()
|
|
53
|
-
if self.duration is not None:
|
|
54
|
-
result['duration'] = self.duration
|
|
55
|
-
if self.number is not None:
|
|
56
|
-
result['number'] = self.number
|
|
57
|
-
if self.product_type is not None:
|
|
58
|
-
result['productType'] = self.product_type
|
|
59
|
-
return result
|
|
60
|
-
|
|
61
|
-
def from_dict(self, m):
|
|
62
|
-
"""
|
|
63
|
-
Populate the request entity from a dictionary.
|
|
64
|
-
|
|
65
|
-
Nested dictionaries are recursively converted to model objects.
|
|
66
|
-
|
|
67
|
-
:param m: Dictionary containing request data
|
|
68
|
-
:type m: dict
|
|
69
|
-
|
|
70
|
-
:return: Self reference for method chaining
|
|
71
|
-
:rtype: GetNewPurchasePriceRequest
|
|
72
|
-
|
|
73
|
-
:raises TypeError: If input is not a dictionary or field type mismatch
|
|
74
|
-
:raises ValueError: If nested model conversion fails
|
|
75
|
-
"""
|
|
76
|
-
m = m or dict()
|
|
77
|
-
if m.get('instance') is not None:
|
|
78
|
-
self.instance = Instance().from_dict(m.get('instance'))
|
|
79
|
-
if m.get('duration') is not None:
|
|
80
|
-
self.duration = m.get('duration')
|
|
81
|
-
if m.get('number') is not None:
|
|
82
|
-
self.number = m.get('number')
|
|
83
|
-
if m.get('productType') is not None:
|
|
84
|
-
self.product_type = m.get('productType')
|
|
85
|
-
return self
|