tencentcloud-sdk-python-intl-en 3.0.1141__py2.py3-none-any.whl → 3.0.1143__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.

Potentially problematic release.


This version of tencentcloud-sdk-python-intl-en might be problematic. Click here for more details.

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.1141'
16
+ __version__ = '3.0.1143'
File without changes
File without changes
@@ -0,0 +1,326 @@
1
+ # -*- coding: utf8 -*-
2
+ # Copyright (c) 2017-2021 THL A29 Limited, a Tencent company. 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.apm.v20210622 import models
21
+
22
+
23
+ class ApmClient(AbstractClient):
24
+ _apiVersion = '2021-06-22'
25
+ _endpoint = 'apm.tencentcloudapi.com'
26
+ _service = 'apm'
27
+
28
+
29
+ def CreateApmInstance(self, request):
30
+ """This API is used to create a business purchase in the APM business system.
31
+
32
+ :param request: Request instance for CreateApmInstance.
33
+ :type request: :class:`tencentcloud.apm.v20210622.models.CreateApmInstanceRequest`
34
+ :rtype: :class:`tencentcloud.apm.v20210622.models.CreateApmInstanceResponse`
35
+
36
+ """
37
+ try:
38
+ params = request._serialize()
39
+ headers = request.headers
40
+ body = self.call("CreateApmInstance", params, headers=headers)
41
+ response = json.loads(body)
42
+ model = models.CreateApmInstanceResponse()
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 DescribeApmAgent(self, request):
53
+ """Obtaining APM Access Point.
54
+
55
+ :param request: Request instance for DescribeApmAgent.
56
+ :type request: :class:`tencentcloud.apm.v20210622.models.DescribeApmAgentRequest`
57
+ :rtype: :class:`tencentcloud.apm.v20210622.models.DescribeApmAgentResponse`
58
+
59
+ """
60
+ try:
61
+ params = request._serialize()
62
+ headers = request.headers
63
+ body = self.call("DescribeApmAgent", params, headers=headers)
64
+ response = json.loads(body)
65
+ model = models.DescribeApmAgentResponse()
66
+ model._deserialize(response["Response"])
67
+ return model
68
+ except Exception as e:
69
+ if isinstance(e, TencentCloudSDKException):
70
+ raise
71
+ else:
72
+ raise TencentCloudSDKException(type(e).__name__, str(e))
73
+
74
+
75
+ def DescribeApmInstances(self, request):
76
+ """This API is used to obtain the list of APM business systems.
77
+
78
+ :param request: Request instance for DescribeApmInstances.
79
+ :type request: :class:`tencentcloud.apm.v20210622.models.DescribeApmInstancesRequest`
80
+ :rtype: :class:`tencentcloud.apm.v20210622.models.DescribeApmInstancesResponse`
81
+
82
+ """
83
+ try:
84
+ params = request._serialize()
85
+ headers = request.headers
86
+ body = self.call("DescribeApmInstances", params, headers=headers)
87
+ response = json.loads(body)
88
+ model = models.DescribeApmInstancesResponse()
89
+ model._deserialize(response["Response"])
90
+ return model
91
+ except Exception as e:
92
+ if isinstance(e, TencentCloudSDKException):
93
+ raise
94
+ else:
95
+ raise TencentCloudSDKException(type(e).__name__, str(e))
96
+
97
+
98
+ def DescribeGeneralApmApplicationConfig(self, request):
99
+ """This API is used to query the application configuration information.
100
+
101
+ :param request: Request instance for DescribeGeneralApmApplicationConfig.
102
+ :type request: :class:`tencentcloud.apm.v20210622.models.DescribeGeneralApmApplicationConfigRequest`
103
+ :rtype: :class:`tencentcloud.apm.v20210622.models.DescribeGeneralApmApplicationConfigResponse`
104
+
105
+ """
106
+ try:
107
+ params = request._serialize()
108
+ headers = request.headers
109
+ body = self.call("DescribeGeneralApmApplicationConfig", params, headers=headers)
110
+ response = json.loads(body)
111
+ model = models.DescribeGeneralApmApplicationConfigResponse()
112
+ model._deserialize(response["Response"])
113
+ return model
114
+ except Exception as e:
115
+ if isinstance(e, TencentCloudSDKException):
116
+ raise
117
+ else:
118
+ raise TencentCloudSDKException(type(e).__name__, str(e))
119
+
120
+
121
+ def DescribeGeneralMetricData(self, request):
122
+ """This API is a general API used to obtain metric data. Users submit request parameters as needed and receive the corresponding metric data.
123
+ The API call frequency is limited to 20 requests per second and 1200 requests per minute. The number of data points per request is limited to 1440.
124
+
125
+ :param request: Request instance for DescribeGeneralMetricData.
126
+ :type request: :class:`tencentcloud.apm.v20210622.models.DescribeGeneralMetricDataRequest`
127
+ :rtype: :class:`tencentcloud.apm.v20210622.models.DescribeGeneralMetricDataResponse`
128
+
129
+ """
130
+ try:
131
+ params = request._serialize()
132
+ headers = request.headers
133
+ body = self.call("DescribeGeneralMetricData", params, headers=headers)
134
+ response = json.loads(body)
135
+ model = models.DescribeGeneralMetricDataResponse()
136
+ model._deserialize(response["Response"])
137
+ return model
138
+ except Exception as e:
139
+ if isinstance(e, TencentCloudSDKException):
140
+ raise
141
+ else:
142
+ raise TencentCloudSDKException(type(e).__name__, str(e))
143
+
144
+
145
+ def DescribeGeneralOTSpanList(self, request):
146
+ """General Query OpenTelemetry Call Chain List.
147
+
148
+ :param request: Request instance for DescribeGeneralOTSpanList.
149
+ :type request: :class:`tencentcloud.apm.v20210622.models.DescribeGeneralOTSpanListRequest`
150
+ :rtype: :class:`tencentcloud.apm.v20210622.models.DescribeGeneralOTSpanListResponse`
151
+
152
+ """
153
+ try:
154
+ params = request._serialize()
155
+ headers = request.headers
156
+ body = self.call("DescribeGeneralOTSpanList", params, headers=headers)
157
+ response = json.loads(body)
158
+ model = models.DescribeGeneralOTSpanListResponse()
159
+ model._deserialize(response["Response"])
160
+ return model
161
+ except Exception as e:
162
+ if isinstance(e, TencentCloudSDKException):
163
+ raise
164
+ else:
165
+ raise TencentCloudSDKException(type(e).__name__, str(e))
166
+
167
+
168
+ def DescribeGeneralSpanList(self, request):
169
+ """General Query Call Chain List.
170
+
171
+ :param request: Request instance for DescribeGeneralSpanList.
172
+ :type request: :class:`tencentcloud.apm.v20210622.models.DescribeGeneralSpanListRequest`
173
+ :rtype: :class:`tencentcloud.apm.v20210622.models.DescribeGeneralSpanListResponse`
174
+
175
+ """
176
+ try:
177
+ params = request._serialize()
178
+ headers = request.headers
179
+ body = self.call("DescribeGeneralSpanList", params, headers=headers)
180
+ response = json.loads(body)
181
+ model = models.DescribeGeneralSpanListResponse()
182
+ model._deserialize(response["Response"])
183
+ return model
184
+ except Exception as e:
185
+ if isinstance(e, TencentCloudSDKException):
186
+ raise
187
+ else:
188
+ raise TencentCloudSDKException(type(e).__name__, str(e))
189
+
190
+
191
+ def DescribeMetricRecords(self, request):
192
+ """This API is used to query metric list. To query metrics, it is recommended to use the DescribeGeneralMetricData API.
193
+
194
+ :param request: Request instance for DescribeMetricRecords.
195
+ :type request: :class:`tencentcloud.apm.v20210622.models.DescribeMetricRecordsRequest`
196
+ :rtype: :class:`tencentcloud.apm.v20210622.models.DescribeMetricRecordsResponse`
197
+
198
+ """
199
+ try:
200
+ params = request._serialize()
201
+ headers = request.headers
202
+ body = self.call("DescribeMetricRecords", params, headers=headers)
203
+ response = json.loads(body)
204
+ model = models.DescribeMetricRecordsResponse()
205
+ model._deserialize(response["Response"])
206
+ return model
207
+ except Exception as e:
208
+ if isinstance(e, TencentCloudSDKException):
209
+ raise
210
+ else:
211
+ raise TencentCloudSDKException(type(e).__name__, str(e))
212
+
213
+
214
+ def DescribeServiceOverview(self, request):
215
+ """This API is used to pull application overview data.
216
+
217
+ :param request: Request instance for DescribeServiceOverview.
218
+ :type request: :class:`tencentcloud.apm.v20210622.models.DescribeServiceOverviewRequest`
219
+ :rtype: :class:`tencentcloud.apm.v20210622.models.DescribeServiceOverviewResponse`
220
+
221
+ """
222
+ try:
223
+ params = request._serialize()
224
+ headers = request.headers
225
+ body = self.call("DescribeServiceOverview", params, headers=headers)
226
+ response = json.loads(body)
227
+ model = models.DescribeServiceOverviewResponse()
228
+ model._deserialize(response["Response"])
229
+ return model
230
+ except Exception as e:
231
+ if isinstance(e, TencentCloudSDKException):
232
+ raise
233
+ else:
234
+ raise TencentCloudSDKException(type(e).__name__, str(e))
235
+
236
+
237
+ def DescribeTagValues(self, request):
238
+ """This API is used to query dimensional data by dimension name and filter condition.
239
+
240
+ :param request: Request instance for DescribeTagValues.
241
+ :type request: :class:`tencentcloud.apm.v20210622.models.DescribeTagValuesRequest`
242
+ :rtype: :class:`tencentcloud.apm.v20210622.models.DescribeTagValuesResponse`
243
+
244
+ """
245
+ try:
246
+ params = request._serialize()
247
+ headers = request.headers
248
+ body = self.call("DescribeTagValues", params, headers=headers)
249
+ response = json.loads(body)
250
+ model = models.DescribeTagValuesResponse()
251
+ model._deserialize(response["Response"])
252
+ return model
253
+ except Exception as e:
254
+ if isinstance(e, TencentCloudSDKException):
255
+ raise
256
+ else:
257
+ raise TencentCloudSDKException(type(e).__name__, str(e))
258
+
259
+
260
+ def ModifyApmInstance(self, request):
261
+ """This API is used to modify the APM business system.
262
+
263
+ :param request: Request instance for ModifyApmInstance.
264
+ :type request: :class:`tencentcloud.apm.v20210622.models.ModifyApmInstanceRequest`
265
+ :rtype: :class:`tencentcloud.apm.v20210622.models.ModifyApmInstanceResponse`
266
+
267
+ """
268
+ try:
269
+ params = request._serialize()
270
+ headers = request.headers
271
+ body = self.call("ModifyApmInstance", params, headers=headers)
272
+ response = json.loads(body)
273
+ model = models.ModifyApmInstanceResponse()
274
+ model._deserialize(response["Response"])
275
+ return model
276
+ except Exception as e:
277
+ if isinstance(e, TencentCloudSDKException):
278
+ raise
279
+ else:
280
+ raise TencentCloudSDKException(type(e).__name__, str(e))
281
+
282
+
283
+ def ModifyGeneralApmApplicationConfig(self, request):
284
+ """OpenAPI available for external use. Customers can flexibly specify the fields to be modified, and then add the list of services to be modified.
285
+
286
+ :param request: Request instance for ModifyGeneralApmApplicationConfig.
287
+ :type request: :class:`tencentcloud.apm.v20210622.models.ModifyGeneralApmApplicationConfigRequest`
288
+ :rtype: :class:`tencentcloud.apm.v20210622.models.ModifyGeneralApmApplicationConfigResponse`
289
+
290
+ """
291
+ try:
292
+ params = request._serialize()
293
+ headers = request.headers
294
+ body = self.call("ModifyGeneralApmApplicationConfig", params, headers=headers)
295
+ response = json.loads(body)
296
+ model = models.ModifyGeneralApmApplicationConfigResponse()
297
+ model._deserialize(response["Response"])
298
+ return model
299
+ except Exception as e:
300
+ if isinstance(e, TencentCloudSDKException):
301
+ raise
302
+ else:
303
+ raise TencentCloudSDKException(type(e).__name__, str(e))
304
+
305
+
306
+ def TerminateApmInstance(self, request):
307
+ """Termination of APM business system.
308
+
309
+ :param request: Request instance for TerminateApmInstance.
310
+ :type request: :class:`tencentcloud.apm.v20210622.models.TerminateApmInstanceRequest`
311
+ :rtype: :class:`tencentcloud.apm.v20210622.models.TerminateApmInstanceResponse`
312
+
313
+ """
314
+ try:
315
+ params = request._serialize()
316
+ headers = request.headers
317
+ body = self.call("TerminateApmInstance", params, headers=headers)
318
+ response = json.loads(body)
319
+ model = models.TerminateApmInstanceResponse()
320
+ model._deserialize(response["Response"])
321
+ return model
322
+ except Exception as e:
323
+ if isinstance(e, TencentCloudSDKException):
324
+ raise
325
+ else:
326
+ raise TencentCloudSDKException(type(e).__name__, str(e))
@@ -0,0 +1,138 @@
1
+ # -*- coding: utf8 -*-
2
+ # Copyright (c) 2017-2021 THL A29 Limited, a Tencent company. 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
+ # CAM authentication fails.
21
+ AUTHFAILURE_ACCESSCAMFAIL = 'AuthFailure.AccessCAMFail'
22
+
23
+ # AuthFailure.UnauthorizedOperation
24
+ AUTHFAILURE_UNAUTHORIZEDOPERATION = 'AuthFailure.UnauthorizedOperation'
25
+
26
+ # CAM authentication parsing failed.
27
+ AUTHFAILURE_UNMARSHALRESPONSE = 'AuthFailure.UnmarshalResponse'
28
+
29
+ # DryRun operation means the request will be successful, but the dryrun parameter is passed.
30
+ DRYRUNOPERATION = 'DryRunOperation'
31
+
32
+ # Operation failed.
33
+ FAILEDOPERATION = 'FailedOperation'
34
+
35
+ # Tag access failed.
36
+ FAILEDOPERATION_ACCESSTAGFAIL = 'FailedOperation.AccessTagFail'
37
+
38
+ # The token information does not exist.
39
+ FAILEDOPERATION_APMCREDENTIALNOTEXIST = 'FailedOperation.ApmCredentialNotExist'
40
+
41
+ # The appid does not match the business system information.
42
+ FAILEDOPERATION_APPIDNOTMATCHINSTANCEINFO = 'FailedOperation.AppIdNotMatchInstanceInfo'
43
+
44
+ # Modification to the API is not allowed when the allowlist is not hit and the business system id is the official demo business system id.
45
+ FAILEDOPERATION_DEMOINSTANCENOTALLOWMODIFIED = 'FailedOperation.DemoInstanceNotAllowModified'
46
+
47
+ # Do not enter duplicate application names.
48
+ FAILEDOPERATION_DUPLICATESERVICE = 'FailedOperation.DuplicateService'
49
+
50
+ # Do not enter duplicate Tag names.
51
+ FAILEDOPERATION_DUPLICATETAGFIELD = 'FailedOperation.DuplicateTagField'
52
+
53
+ # Modification of this business system is not allowed.
54
+ FAILEDOPERATION_INSTANCECANNOTMODIFY = 'FailedOperation.InstanceCannotModify'
55
+
56
+ # Destruction of the business system is not allowed.
57
+ FAILEDOPERATION_INSTANCECANNOTTERMINATE = 'FailedOperation.InstanceCannotTerminate'
58
+
59
+ # Business system id is empty.
60
+ FAILEDOPERATION_INSTANCEIDISEMPTY = 'FailedOperation.InstanceIdIsEmpty'
61
+
62
+ # The apm business system does not exist.
63
+ FAILEDOPERATION_INSTANCENOTFOUND = 'FailedOperation.InstanceNotFound'
64
+
65
+ # Invalid business system id.
66
+ FAILEDOPERATION_INVALIDINSTANCEID = 'FailedOperation.InvalidInstanceID'
67
+
68
+ # Invalid input parameter.
69
+ FAILEDOPERATION_INVALIDPARAM = 'FailedOperation.InvalidParam'
70
+
71
+ # Invalid regular expression.
72
+ FAILEDOPERATION_INVALIDREGEX = 'FailedOperation.InvalidRegex'
73
+
74
+ # Invalid request.
75
+ FAILEDOPERATION_INVALIDREQUEST = 'FailedOperation.InvalidRequest'
76
+
77
+ # Business system and application name do not match.
78
+ FAILEDOPERATION_INVALIDSERVICENAME = 'FailedOperation.InvalidServiceName'
79
+
80
+ # Invalid key specified in the tag.
81
+ FAILEDOPERATION_INVALIDTAGFIELD = 'FailedOperation.InvalidTagField'
82
+
83
+ # Invalid token.
84
+ FAILEDOPERATION_INVALIDTOKEN = 'FailedOperation.InvalidToken'
85
+
86
+ # The metric data query lacks filter parameters in the query criteria.
87
+ FAILEDOPERATION_METRICFILTERSLACKPARAMS = 'FailedOperation.MetricFiltersLackParams'
88
+
89
+ # Non-Private vpc.
90
+ FAILEDOPERATION_NOTINNERVPC = 'FailedOperation.NotInnerVPC'
91
+
92
+ # Query time range not supported.
93
+ FAILEDOPERATION_QUERYTIMEINTERVALISNOTSUPPORTED = 'FailedOperation.QueryTimeIntervalIsNotSupported'
94
+
95
+ # This region is not supported.
96
+ FAILEDOPERATION_REGIONNOTSUPPORT = 'FailedOperation.RegionNotSupport'
97
+
98
+ # Failed to send the query request.
99
+ FAILEDOPERATION_SENDREQUEST = 'FailedOperation.SendRequest'
100
+
101
+ # The number of applications exceeds 10.
102
+ FAILEDOPERATION_SERVICELISTEXCEEDINGLIMITNUMBER = 'FailedOperation.ServiceListExceedingLimitNumber'
103
+
104
+ # Application list is empty.
105
+ FAILEDOPERATION_SERVICELISTNULL = 'FailedOperation.ServiceListNull'
106
+
107
+ # The view name does not exist or is invalid.
108
+ FAILEDOPERATION_VIEWNAMENOTEXISTORILLEGAL = 'FailedOperation.ViewNameNotExistOrIllegal'
109
+
110
+ # Internal error.
111
+ INTERNALERROR = 'InternalError'
112
+
113
+ # Parameter error.
114
+ INVALIDPARAMETER = 'InvalidParameter'
115
+
116
+ # The field in filters does not exist or is invalid.
117
+ INVALIDPARAMETER_FILTERSFIELDSNOTEXISTORILLEGAL = 'InvalidParameter.FiltersFieldsNotExistOrIllegal'
118
+
119
+ # The field in groupby does not exist or is invalid.
120
+ INVALIDPARAMETER_GROUPBYFIELDSNOTEXISTORILLEGAL = 'InvalidParameter.GroupByFieldsNotExistOrIllegal'
121
+
122
+ # The service.name field must exist in filters, otherwise an error will occur.
123
+ INVALIDPARAMETER_METRICFILTERSLACKPARAMS = 'InvalidParameter.MetricFiltersLackParams'
124
+
125
+ # The field in metrics does not exist or is invalid.
126
+ INVALIDPARAMETER_METRICSFIELDNOTEXISTORILLEGAL = 'InvalidParameter.MetricsFieldNotExistOrIllegal'
127
+
128
+ # Metrics cannot be empty.
129
+ INVALIDPARAMETER_METRICSFIELDSNOTALLOWEMPTY = 'InvalidParameter.MetricsFieldsNotAllowEmpty'
130
+
131
+ # Period should not be empty, and can be 0 or 60.
132
+ INVALIDPARAMETER_PERIODISILLEGAL = 'InvalidParameter.PeriodIsIllegal'
133
+
134
+ # Query time not supported. up to 30 days of recent data can be queried.
135
+ INVALIDPARAMETER_QUERYTIMEINTERVALISNOTSUPPORTED = 'InvalidParameter.QueryTimeIntervalIsNotSupported'
136
+
137
+ # The view name does not exist or is invalid.
138
+ INVALIDPARAMETER_VIEWNAMENOTEXISTORILLEGAL = 'InvalidParameter.ViewNameNotExistOrIllegal'