tencentcloud-sdk-python-intl-en 3.0.1247__py2.py3-none-any.whl → 3.0.1249__py2.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.
tencentcloud/__init__.py CHANGED
@@ -13,4 +13,4 @@
13
13
  # See the License for the specific language governing permissions and
14
14
  # limitations under the License.
15
15
 
16
- __version__ = '3.0.1247'
16
+ __version__ = '3.0.1249'
File without changes
File without changes
@@ -0,0 +1,78 @@
1
+ # -*- coding: utf8 -*-
2
+ # Copyright (c) 2017-2025 Tencent. All Rights Reserved.
3
+ #
4
+ # Licensed under the Apache License, Version 2.0 (the "License");
5
+ # you may not use this file except in compliance with the License.
6
+ # You may obtain a copy of the License at
7
+ #
8
+ # http://www.apache.org/licenses/LICENSE-2.0
9
+ #
10
+ # Unless required by applicable law or agreed to in writing, software
11
+ # distributed under the License is distributed on an "AS IS" BASIS,
12
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ # See the License for the specific language governing permissions and
14
+ # limitations under the License.
15
+
16
+ import json
17
+
18
+ from tencentcloud.common.exception.tencent_cloud_sdk_exception import TencentCloudSDKException
19
+ from tencentcloud.common.abstract_client import AbstractClient
20
+ from tencentcloud.ctsdb.v20230202 import models
21
+
22
+
23
+ class CtsdbClient(AbstractClient):
24
+ _apiVersion = '2023-02-02'
25
+ _endpoint = 'ctsdb.intl.tencentcloudapi.com'
26
+ _service = 'ctsdb'
27
+
28
+
29
+ def DescribeClusters(self, request):
30
+ """This API is used to query the instance list and details.
31
+
32
+ :param request: Request instance for DescribeClusters.
33
+ :type request: :class:`tencentcloud.ctsdb.v20230202.models.DescribeClustersRequest`
34
+ :rtype: :class:`tencentcloud.ctsdb.v20230202.models.DescribeClustersResponse`
35
+
36
+ """
37
+ try:
38
+ params = request._serialize()
39
+ headers = request.headers
40
+ body = self.call("DescribeClusters", params, headers=headers)
41
+ response = json.loads(body)
42
+ model = models.DescribeClustersResponse()
43
+ model._deserialize(response["Response"])
44
+ return model
45
+ except Exception as e:
46
+ if isinstance(e, TencentCloudSDKException):
47
+ raise
48
+ else:
49
+ raise TencentCloudSDKException(type(e).__name__, str(e))
50
+
51
+
52
+ def DescribeDatabases(self, request):
53
+ """This API is used to query the database list.
54
+ ```
55
+ "Database":{
56
+ "ClusterID":"ctsdbi-rebg0ghl",
57
+ "Name":"" //This API is used to query all databases under the instance if the parameter is not specified.
58
+ }
59
+ ```
60
+
61
+ :param request: Request instance for DescribeDatabases.
62
+ :type request: :class:`tencentcloud.ctsdb.v20230202.models.DescribeDatabasesRequest`
63
+ :rtype: :class:`tencentcloud.ctsdb.v20230202.models.DescribeDatabasesResponse`
64
+
65
+ """
66
+ try:
67
+ params = request._serialize()
68
+ headers = request.headers
69
+ body = self.call("DescribeDatabases", params, headers=headers)
70
+ response = json.loads(body)
71
+ model = models.DescribeDatabasesResponse()
72
+ model._deserialize(response["Response"])
73
+ return model
74
+ except Exception as e:
75
+ if isinstance(e, TencentCloudSDKException):
76
+ raise
77
+ else:
78
+ raise TencentCloudSDKException(type(e).__name__, str(e))
@@ -0,0 +1,24 @@
1
+ # -*- coding: utf8 -*-
2
+ # Copyright (c) 2017-2025 Tencent. All Rights Reserved.
3
+ #
4
+ # Licensed under the Apache License, Version 2.0 (the "License");
5
+ # you may not use this file except in compliance with the License.
6
+ # You may obtain a copy of the License at
7
+ #
8
+ # http://www.apache.org/licenses/LICENSE-2.0
9
+ #
10
+ # Unless required by applicable law or agreed to in writing, software
11
+ # distributed under the License is distributed on an "AS IS" BASIS,
12
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ # See the License for the specific language governing permissions and
14
+ # limitations under the License.
15
+
16
+
17
+ # CAM signature/authentication error.
18
+ AUTHFAILURE = 'AuthFailure'
19
+
20
+ # Operation failed.
21
+ FAILEDOPERATION = 'FailedOperation'
22
+
23
+ # The resource does not exist.
24
+ RESOURCENOTFOUND = 'ResourceNotFound'