tencentcloud-sdk-python-intl-en 3.0.1207__py2.py3-none-any.whl → 3.0.1209__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.1207'
16
+ __version__ = '3.0.1209'
@@ -26,6 +26,29 @@ class BillingClient(AbstractClient):
26
26
  _service = 'billing'
27
27
 
28
28
 
29
+ def CreateAllocationRule(self, request):
30
+ """Create a sharing rule.
31
+
32
+ :param request: Request instance for CreateAllocationRule.
33
+ :type request: :class:`tencentcloud.billing.v20180709.models.CreateAllocationRuleRequest`
34
+ :rtype: :class:`tencentcloud.billing.v20180709.models.CreateAllocationRuleResponse`
35
+
36
+ """
37
+ try:
38
+ params = request._serialize()
39
+ headers = request.headers
40
+ body = self.call("CreateAllocationRule", params, headers=headers)
41
+ response = json.loads(body)
42
+ model = models.CreateAllocationRuleResponse()
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
+
29
52
  def CreateAllocationTag(self, request):
30
53
  """This API is used to batch set cost allocation tags.
31
54
 
@@ -49,6 +72,75 @@ class BillingClient(AbstractClient):
49
72
  raise TencentCloudSDKException(type(e).__name__, str(e))
50
73
 
51
74
 
75
+ def CreateAllocationUnit(self, request):
76
+ """This API is used to create allocation units.
77
+
78
+ :param request: Request instance for CreateAllocationUnit.
79
+ :type request: :class:`tencentcloud.billing.v20180709.models.CreateAllocationUnitRequest`
80
+ :rtype: :class:`tencentcloud.billing.v20180709.models.CreateAllocationUnitResponse`
81
+
82
+ """
83
+ try:
84
+ params = request._serialize()
85
+ headers = request.headers
86
+ body = self.call("CreateAllocationUnit", params, headers=headers)
87
+ response = json.loads(body)
88
+ model = models.CreateAllocationUnitResponse()
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 CreateGatherRule(self, request):
99
+ """Create a collection rule.
100
+
101
+ :param request: Request instance for CreateGatherRule.
102
+ :type request: :class:`tencentcloud.billing.v20180709.models.CreateGatherRuleRequest`
103
+ :rtype: :class:`tencentcloud.billing.v20180709.models.CreateGatherRuleResponse`
104
+
105
+ """
106
+ try:
107
+ params = request._serialize()
108
+ headers = request.headers
109
+ body = self.call("CreateGatherRule", params, headers=headers)
110
+ response = json.loads(body)
111
+ model = models.CreateGatherRuleResponse()
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 DeleteAllocationRule(self, request):
122
+ """Delete sharing rule interface.
123
+
124
+ :param request: Request instance for DeleteAllocationRule.
125
+ :type request: :class:`tencentcloud.billing.v20180709.models.DeleteAllocationRuleRequest`
126
+ :rtype: :class:`tencentcloud.billing.v20180709.models.DeleteAllocationRuleResponse`
127
+
128
+ """
129
+ try:
130
+ params = request._serialize()
131
+ headers = request.headers
132
+ body = self.call("DeleteAllocationRule", params, headers=headers)
133
+ response = json.loads(body)
134
+ model = models.DeleteAllocationRuleResponse()
135
+ model._deserialize(response["Response"])
136
+ return model
137
+ except Exception as e:
138
+ if isinstance(e, TencentCloudSDKException):
139
+ raise
140
+ else:
141
+ raise TencentCloudSDKException(type(e).__name__, str(e))
142
+
143
+
52
144
  def DeleteAllocationTag(self, request):
53
145
  """u200cThis API is used to batch cancel cost allocation tags.
54
146
 
@@ -72,6 +164,52 @@ class BillingClient(AbstractClient):
72
164
  raise TencentCloudSDKException(type(e).__name__, str(e))
73
165
 
74
166
 
167
+ def DeleteAllocationUnit(self, request):
168
+ """Delete a cost allocation unit.
169
+
170
+ :param request: Request instance for DeleteAllocationUnit.
171
+ :type request: :class:`tencentcloud.billing.v20180709.models.DeleteAllocationUnitRequest`
172
+ :rtype: :class:`tencentcloud.billing.v20180709.models.DeleteAllocationUnitResponse`
173
+
174
+ """
175
+ try:
176
+ params = request._serialize()
177
+ headers = request.headers
178
+ body = self.call("DeleteAllocationUnit", params, headers=headers)
179
+ response = json.loads(body)
180
+ model = models.DeleteAllocationUnitResponse()
181
+ model._deserialize(response["Response"])
182
+ return model
183
+ except Exception as e:
184
+ if isinstance(e, TencentCloudSDKException):
185
+ raise
186
+ else:
187
+ raise TencentCloudSDKException(type(e).__name__, str(e))
188
+
189
+
190
+ def DeleteGatherRule(self, request):
191
+ """Delete a collection rule.
192
+
193
+ :param request: Request instance for DeleteGatherRule.
194
+ :type request: :class:`tencentcloud.billing.v20180709.models.DeleteGatherRuleRequest`
195
+ :rtype: :class:`tencentcloud.billing.v20180709.models.DeleteGatherRuleResponse`
196
+
197
+ """
198
+ try:
199
+ params = request._serialize()
200
+ headers = request.headers
201
+ body = self.call("DeleteGatherRule", params, headers=headers)
202
+ response = json.loads(body)
203
+ model = models.DeleteGatherRuleResponse()
204
+ model._deserialize(response["Response"])
205
+ return model
206
+ except Exception as e:
207
+ if isinstance(e, TencentCloudSDKException):
208
+ raise
209
+ else:
210
+ raise TencentCloudSDKException(type(e).__name__, str(e))
211
+
212
+
75
213
  def DescribeAccountBalance(self, request):
76
214
  """This API is used to check the Tencent Cloud account balance.
77
215
 
@@ -95,6 +233,75 @@ class BillingClient(AbstractClient):
95
233
  raise TencentCloudSDKException(type(e).__name__, str(e))
96
234
 
97
235
 
236
+ def DescribeAllocationRuleDetail(self, request):
237
+ """This API is used to query sharing rule details.
238
+
239
+ :param request: Request instance for DescribeAllocationRuleDetail.
240
+ :type request: :class:`tencentcloud.billing.v20180709.models.DescribeAllocationRuleDetailRequest`
241
+ :rtype: :class:`tencentcloud.billing.v20180709.models.DescribeAllocationRuleDetailResponse`
242
+
243
+ """
244
+ try:
245
+ params = request._serialize()
246
+ headers = request.headers
247
+ body = self.call("DescribeAllocationRuleDetail", params, headers=headers)
248
+ response = json.loads(body)
249
+ model = models.DescribeAllocationRuleDetailResponse()
250
+ model._deserialize(response["Response"])
251
+ return model
252
+ except Exception as e:
253
+ if isinstance(e, TencentCloudSDKException):
254
+ raise
255
+ else:
256
+ raise TencentCloudSDKException(type(e).__name__, str(e))
257
+
258
+
259
+ def DescribeAllocationRuleSummary(self, request):
260
+ """This API is used to query all sharing rule overviews.
261
+
262
+ :param request: Request instance for DescribeAllocationRuleSummary.
263
+ :type request: :class:`tencentcloud.billing.v20180709.models.DescribeAllocationRuleSummaryRequest`
264
+ :rtype: :class:`tencentcloud.billing.v20180709.models.DescribeAllocationRuleSummaryResponse`
265
+
266
+ """
267
+ try:
268
+ params = request._serialize()
269
+ headers = request.headers
270
+ body = self.call("DescribeAllocationRuleSummary", params, headers=headers)
271
+ response = json.loads(body)
272
+ model = models.DescribeAllocationRuleSummaryResponse()
273
+ model._deserialize(response["Response"])
274
+ return model
275
+ except Exception as e:
276
+ if isinstance(e, TencentCloudSDKException):
277
+ raise
278
+ else:
279
+ raise TencentCloudSDKException(type(e).__name__, str(e))
280
+
281
+
282
+ def DescribeAllocationTree(self, request):
283
+ """This API is used to query the cost tree.
284
+
285
+ :param request: Request instance for DescribeAllocationTree.
286
+ :type request: :class:`tencentcloud.billing.v20180709.models.DescribeAllocationTreeRequest`
287
+ :rtype: :class:`tencentcloud.billing.v20180709.models.DescribeAllocationTreeResponse`
288
+
289
+ """
290
+ try:
291
+ params = request._serialize()
292
+ headers = request.headers
293
+ body = self.call("DescribeAllocationTree", params, headers=headers)
294
+ response = json.loads(body)
295
+ model = models.DescribeAllocationTreeResponse()
296
+ model._deserialize(response["Response"])
297
+ return model
298
+ except Exception as e:
299
+ if isinstance(e, TencentCloudSDKException):
300
+ raise
301
+ else:
302
+ raise TencentCloudSDKException(type(e).__name__, str(e))
303
+
304
+
98
305
  def DescribeAllocationUnitDetail(self, request):
99
306
  """Query the details of a cost allocation unit.
100
307
 
@@ -605,6 +812,29 @@ class BillingClient(AbstractClient):
605
812
  raise TencentCloudSDKException(type(e).__name__, str(e))
606
813
 
607
814
 
815
+ def DescribeGatherRuleDetail(self, request):
816
+ """This API is used to query the collection rule details.
817
+
818
+ :param request: Request instance for DescribeGatherRuleDetail.
819
+ :type request: :class:`tencentcloud.billing.v20180709.models.DescribeGatherRuleDetailRequest`
820
+ :rtype: :class:`tencentcloud.billing.v20180709.models.DescribeGatherRuleDetailResponse`
821
+
822
+ """
823
+ try:
824
+ params = request._serialize()
825
+ headers = request.headers
826
+ body = self.call("DescribeGatherRuleDetail", params, headers=headers)
827
+ response = json.loads(body)
828
+ model = models.DescribeGatherRuleDetailResponse()
829
+ model._deserialize(response["Response"])
830
+ return model
831
+ except Exception as e:
832
+ if isinstance(e, TencentCloudSDKException):
833
+ raise
834
+ else:
835
+ raise TencentCloudSDKException(type(e).__name__, str(e))
836
+
837
+
608
838
  def DescribeTagList(self, request):
609
839
  """This API is used to get cost allocation tags.
610
840
 
@@ -667,6 +897,75 @@ class BillingClient(AbstractClient):
667
897
  model = models.DescribeVoucherUsageDetailsResponse()
668
898
  model._deserialize(response["Response"])
669
899
  return model
900
+ except Exception as e:
901
+ if isinstance(e, TencentCloudSDKException):
902
+ raise
903
+ else:
904
+ raise TencentCloudSDKException(type(e).__name__, str(e))
905
+
906
+
907
+ def ModifyAllocationRule(self, request):
908
+ """Edit sharing rules.
909
+
910
+ :param request: Request instance for ModifyAllocationRule.
911
+ :type request: :class:`tencentcloud.billing.v20180709.models.ModifyAllocationRuleRequest`
912
+ :rtype: :class:`tencentcloud.billing.v20180709.models.ModifyAllocationRuleResponse`
913
+
914
+ """
915
+ try:
916
+ params = request._serialize()
917
+ headers = request.headers
918
+ body = self.call("ModifyAllocationRule", params, headers=headers)
919
+ response = json.loads(body)
920
+ model = models.ModifyAllocationRuleResponse()
921
+ model._deserialize(response["Response"])
922
+ return model
923
+ except Exception as e:
924
+ if isinstance(e, TencentCloudSDKException):
925
+ raise
926
+ else:
927
+ raise TencentCloudSDKException(type(e).__name__, str(e))
928
+
929
+
930
+ def ModifyAllocationUnit(self, request):
931
+ """This API is used to modify cost allocation unit information.
932
+
933
+ :param request: Request instance for ModifyAllocationUnit.
934
+ :type request: :class:`tencentcloud.billing.v20180709.models.ModifyAllocationUnitRequest`
935
+ :rtype: :class:`tencentcloud.billing.v20180709.models.ModifyAllocationUnitResponse`
936
+
937
+ """
938
+ try:
939
+ params = request._serialize()
940
+ headers = request.headers
941
+ body = self.call("ModifyAllocationUnit", params, headers=headers)
942
+ response = json.loads(body)
943
+ model = models.ModifyAllocationUnitResponse()
944
+ model._deserialize(response["Response"])
945
+ return model
946
+ except Exception as e:
947
+ if isinstance(e, TencentCloudSDKException):
948
+ raise
949
+ else:
950
+ raise TencentCloudSDKException(type(e).__name__, str(e))
951
+
952
+
953
+ def ModifyGatherRule(self, request):
954
+ """Edit a collection rule.
955
+
956
+ :param request: Request instance for ModifyGatherRule.
957
+ :type request: :class:`tencentcloud.billing.v20180709.models.ModifyGatherRuleRequest`
958
+ :rtype: :class:`tencentcloud.billing.v20180709.models.ModifyGatherRuleResponse`
959
+
960
+ """
961
+ try:
962
+ params = request._serialize()
963
+ headers = request.headers
964
+ body = self.call("ModifyGatherRule", params, headers=headers)
965
+ response = json.loads(body)
966
+ model = models.ModifyGatherRuleResponse()
967
+ model._deserialize(response["Response"])
968
+ return model
670
969
  except Exception as e:
671
970
  if isinstance(e, TencentCloudSDKException):
672
971
  raise
@@ -23,6 +23,9 @@ FAILEDOPERATION = 'FailedOperation'
23
23
  # Invalid App ID.
24
24
  FAILEDOPERATION_INVALIDAPPID = 'FailedOperation.InvalidAppId'
25
25
 
26
+ # The quantity exceeds the maximum limit.
27
+ FAILEDOPERATION_NUMLIMITERROR = 'FailedOperation.NumLimitError'
28
+
26
29
  # Payment failed. Please contact Tencent Cloud to resolve this issue.
27
30
  FAILEDOPERATION_PAYPRICEERROR = 'FailedOperation.PayPriceError'
28
31
 
@@ -38,6 +41,9 @@ FAILEDOPERATION_TAGKEYNOTEXIST = 'FailedOperation.TagKeyNotExist'
38
41
  # Internal error.
39
42
  INTERNALERROR = 'InternalError'
40
43
 
44
+ # Database operation failed.
45
+ INTERNALERROR_DBOPERATERROR = 'InternalError.DbOperatError'
46
+
41
47
  # Gateway error.
42
48
  INTERNALERROR_GATEWAYERROR = 'InternalError.GatewayError'
43
49
 
@@ -56,6 +62,9 @@ INVALIDPARAMETER_INVALIDPARAMETER = 'InvalidParameter.InvalidParameter'
56
62
  # Invalid parameter value.
57
63
  INVALIDPARAMETERVALUE = 'InvalidParameterValue'
58
64
 
65
+ # Operation denied.
66
+ OPERATIONDENIED = 'OperationDenied'
67
+
59
68
  # The account does not have CAM permission.
60
69
  UNAUTHORIZEDOPERATION_CAMNOAUTH = 'UnauthorizedOperation.CamNoAuth'
61
70