tencentcloud-sdk-python-hai 3.1.38__tar.gz → 3.1.41__tar.gz

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.
Files changed (17) hide show
  1. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/PKG-INFO +2 -2
  2. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/setup.py +1 -1
  3. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/tencentcloud/__init__.py +1 -1
  4. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/tencentcloud/hai/v20230812/errorcodes.py +15 -0
  5. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/tencentcloud/hai/v20230812/hai_client.py +46 -0
  6. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/tencentcloud/hai/v20230812/hai_client_async.py +36 -0
  7. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/tencentcloud/hai/v20230812/models.py +168 -0
  8. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/tencentcloud_sdk_python_hai.egg-info/PKG-INFO +2 -2
  9. tencentcloud_sdk_python_hai-3.1.41/tencentcloud_sdk_python_hai.egg-info/requires.txt +1 -0
  10. tencentcloud_sdk_python_hai-3.1.38/tencentcloud_sdk_python_hai.egg-info/requires.txt +0 -1
  11. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/README.rst +0 -0
  12. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/setup.cfg +0 -0
  13. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/tencentcloud/hai/__init__.py +0 -0
  14. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/tencentcloud/hai/v20230812/__init__.py +0 -0
  15. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/tencentcloud_sdk_python_hai.egg-info/SOURCES.txt +0 -0
  16. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/tencentcloud_sdk_python_hai.egg-info/dependency_links.txt +0 -0
  17. {tencentcloud_sdk_python_hai-3.1.38 → tencentcloud_sdk_python_hai-3.1.41}/tencentcloud_sdk_python_hai.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: tencentcloud-sdk-python-hai
3
- Version: 3.1.38
3
+ Version: 3.1.41
4
4
  Summary: Tencent Cloud Hai SDK for Python
5
5
  Home-page: https://github.com/TencentCloud/tencentcloud-sdk-python
6
6
  Author: Tencent Cloud
@@ -15,7 +15,7 @@ Classifier: Programming Language :: Python :: 2.7
15
15
  Classifier: Programming Language :: Python :: 3
16
16
  Classifier: Programming Language :: Python :: 3.6
17
17
  Classifier: Programming Language :: Python :: 3.7
18
- Requires-Dist: tencentcloud-sdk-python-common<4.0.0,>=3.1.38
18
+ Requires-Dist: tencentcloud-sdk-python-common<4.0.0,>=3.1.41
19
19
 
20
20
  ============================
21
21
  Tencent Cloud SDK for Python
@@ -8,7 +8,7 @@ ROOT = os.path.dirname(__file__)
8
8
 
9
9
  setup(
10
10
  name='tencentcloud-sdk-python-hai',
11
- install_requires=["tencentcloud-sdk-python-common>=3.1.38,<4.0.0"],
11
+ install_requires=["tencentcloud-sdk-python-common>=3.1.41,<4.0.0"],
12
12
 
13
13
  version=tencentcloud.__version__,
14
14
  description='Tencent Cloud Hai SDK for Python',
@@ -14,4 +14,4 @@
14
14
  # limitations under the License.
15
15
 
16
16
 
17
- __version__ = '3.1.38'
17
+ __version__ = '3.1.41'
@@ -98,18 +98,27 @@ INVALIDPARAMETERVALUE_INVALIDPASSWORD = 'InvalidParameterValue.InvalidPassword'
98
98
  # 场景ID格式非法
99
99
  INVALIDPARAMETERVALUE_INVALIDSCENEIDMALFORMED = 'InvalidParameterValue.InvalidSceneIdMalformed'
100
100
 
101
+ # 服务ID格式错误
102
+ INVALIDPARAMETERVALUE_INVALIDSERVICEIDMALFORMED = 'InvalidParameterValue.InvalidServiceIdMalformed'
103
+
101
104
  # 地域非法
102
105
  INVALIDPARAMETERVALUE_REGIONINVALID = 'InvalidParameterValue.RegionInvalid'
103
106
 
104
107
  # 无法找到指定的安全组
105
108
  INVALIDPARAMETERVALUE_SECURITYGROUPNOTFOUND = 'InvalidParameterValue.SecurityGroupNotFound'
106
109
 
110
+ # 服务ID不存在
111
+ INVALIDPARAMETERVALUE_SERVICEIDNOTFOUND = 'InvalidParameterValue.ServiceIdNotFound'
112
+
107
113
  # 入参中若存在子网ID,则必须同时存在VPC ID。
108
114
  INVALIDPARAMETERVALUE_SUBNETMUSTCOEXISTWITHVPC = 'InvalidParameterValue.SubnetMustCoexistWithVpc'
109
115
 
110
116
  # 无法找到指定的子网,或该子网不属于指定的VPC
111
117
  INVALIDPARAMETERVALUE_SUBNETNOTFOUND = 'InvalidParameterValue.SubnetNotFound'
112
118
 
119
+ # 目标副本数不能与运行中副本数相同
120
+ INVALIDPARAMETERVALUE_TARGETREPLICASMUSTDIFFERFROMRUNNINGREPLICAS = 'InvalidParameterValue.TargetReplicasMustDifferFromRunningReplicas'
121
+
113
122
  # 无法找到指定的VPC
114
123
  INVALIDPARAMETERVALUE_VPCNOTFOUND = 'InvalidParameterValue.VpcNotFound'
115
124
 
@@ -122,6 +131,9 @@ LIMITEXCEEDED_VPCLIMITEXCEEDED = 'LimitExceeded.VpcLimitExceeded'
122
131
  # 指定实例有正在执行的操作,不能执行新的操作
123
132
  OPERATIONDENIED_INSTANCEOPERATIONINPROGRESS = 'OperationDenied.InstanceOperationInProgress'
124
133
 
134
+ # 指定服务有正在执行的操作,不能执行新的操作
135
+ OPERATIONDENIED_SERVICEOPERATIONINPROGRESS = 'OperationDenied.ServiceOperationInProgress'
136
+
125
137
  # 指定的算力套餐库存不足
126
138
  RESOURCEINSUFFICIENT_BUNDLEINVENTORYSHORTAGE = 'ResourceInsufficient.BundleInventoryShortage'
127
139
 
@@ -166,3 +178,6 @@ UNSUPPORTEDOPERATION_INSTANCESTATETERMINATED = 'UnsupportedOperation.InstanceSta
166
178
 
167
179
  # 不支持同时操作预付费和后付费实例
168
180
  UNSUPPORTEDOPERATION_NOTSUPPORTTERMINATEPREPAIDANDPOSTPAID = 'UnsupportedOperation.NotSupportTerminatePrePaidAndPostPaid'
181
+
182
+ # 后付费服务缩容不支持询价
183
+ UNSUPPORTEDOPERATION_NOTSUPPORTTOINQUIRYPRICE = 'UnsupportedOperation.NotSupportToInquiryPrice'
@@ -256,6 +256,29 @@ class HaiClient(AbstractClient):
256
256
  raise TencentCloudSDKException(type(e).__name__, str(e))
257
257
 
258
258
 
259
+ def InquirePriceUpdateServiceConfigs(self, request):
260
+ r"""本接口(InquirePriceUpdateServiceConfigs)用于更新服务配置询价
261
+
262
+ :param request: Request instance for InquirePriceUpdateServiceConfigs.
263
+ :type request: :class:`tencentcloud.hai.v20230812.models.InquirePriceUpdateServiceConfigsRequest`
264
+ :rtype: :class:`tencentcloud.hai.v20230812.models.InquirePriceUpdateServiceConfigsResponse`
265
+
266
+ """
267
+ try:
268
+ params = request._serialize()
269
+ headers = request.headers
270
+ body = self.call("InquirePriceUpdateServiceConfigs", params, headers=headers)
271
+ response = json.loads(body)
272
+ model = models.InquirePriceUpdateServiceConfigsResponse()
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
+
259
282
  def ResetInstancesPassword(self, request):
260
283
  r"""本接口 (ResetInstancesPassword) 用于重置实例的用户密码。
261
284
 
@@ -389,6 +412,29 @@ class HaiClient(AbstractClient):
389
412
  model = models.TerminateInstancesResponse()
390
413
  model._deserialize(response["Response"])
391
414
  return model
415
+ except Exception as e:
416
+ if isinstance(e, TencentCloudSDKException):
417
+ raise
418
+ else:
419
+ raise TencentCloudSDKException(type(e).__name__, str(e))
420
+
421
+
422
+ def UpdateServiceConfigs(self, request):
423
+ r"""本接口(UpdateServiceConfigs)用于更新服务配置
424
+
425
+ :param request: Request instance for UpdateServiceConfigs.
426
+ :type request: :class:`tencentcloud.hai.v20230812.models.UpdateServiceConfigsRequest`
427
+ :rtype: :class:`tencentcloud.hai.v20230812.models.UpdateServiceConfigsResponse`
428
+
429
+ """
430
+ try:
431
+ params = request._serialize()
432
+ headers = request.headers
433
+ body = self.call("UpdateServiceConfigs", params, headers=headers)
434
+ response = json.loads(body)
435
+ model = models.UpdateServiceConfigsResponse()
436
+ model._deserialize(response["Response"])
437
+ return model
392
438
  except Exception as e:
393
439
  if isinstance(e, TencentCloudSDKException):
394
440
  raise
@@ -205,6 +205,24 @@ class HaiClient(AbstractClient):
205
205
 
206
206
  return await self.call_and_deserialize(**kwargs)
207
207
 
208
+ async def InquirePriceUpdateServiceConfigs(
209
+ self,
210
+ request: models.InquirePriceUpdateServiceConfigsRequest,
211
+ opts: Dict = None,
212
+ ) -> models.InquirePriceUpdateServiceConfigsResponse:
213
+ """
214
+ 本接口(InquirePriceUpdateServiceConfigs)用于更新服务配置询价
215
+ """
216
+
217
+ kwargs = {}
218
+ kwargs["action"] = "InquirePriceUpdateServiceConfigs"
219
+ kwargs["params"] = request._serialize()
220
+ kwargs["resp_cls"] = models.InquirePriceUpdateServiceConfigsResponse
221
+ kwargs["headers"] = request.headers
222
+ kwargs["opts"] = opts or {}
223
+
224
+ return await self.call_and_deserialize(**kwargs)
225
+
208
226
  async def ResetInstancesPassword(
209
227
  self,
210
228
  request: models.ResetInstancesPasswordRequest,
@@ -313,4 +331,22 @@ class HaiClient(AbstractClient):
313
331
  kwargs["headers"] = request.headers
314
332
  kwargs["opts"] = opts or {}
315
333
 
334
+ return await self.call_and_deserialize(**kwargs)
335
+
336
+ async def UpdateServiceConfigs(
337
+ self,
338
+ request: models.UpdateServiceConfigsRequest,
339
+ opts: Dict = None,
340
+ ) -> models.UpdateServiceConfigsResponse:
341
+ """
342
+ 本接口(UpdateServiceConfigs)用于更新服务配置
343
+ """
344
+
345
+ kwargs = {}
346
+ kwargs["action"] = "UpdateServiceConfigs"
347
+ kwargs["params"] = request._serialize()
348
+ kwargs["resp_cls"] = models.UpdateServiceConfigsResponse
349
+ kwargs["headers"] = request.headers
350
+ kwargs["opts"] = opts or {}
351
+
316
352
  return await self.call_and_deserialize(**kwargs)
@@ -1489,6 +1489,57 @@ class InquirePriceRunInstancesResponse(AbstractModel):
1489
1489
  self._RequestId = params.get("RequestId")
1490
1490
 
1491
1491
 
1492
+ class InquirePriceUpdateServiceConfigsRequest(AbstractModel):
1493
+ r"""InquirePriceUpdateServiceConfigs请求参数结构体
1494
+
1495
+ """
1496
+
1497
+
1498
+ class InquirePriceUpdateServiceConfigsResponse(AbstractModel):
1499
+ r"""InquirePriceUpdateServiceConfigs返回参数结构体
1500
+
1501
+ """
1502
+
1503
+ def __init__(self):
1504
+ r"""
1505
+ :param _Price: 发货参数对应的价格组合。
1506
+ :type Price: :class:`tencentcloud.hai.v20230812.models.ServicePriceDetail`
1507
+ :param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
1508
+ :type RequestId: str
1509
+ """
1510
+ self._Price = None
1511
+ self._RequestId = None
1512
+
1513
+ @property
1514
+ def Price(self):
1515
+ r"""发货参数对应的价格组合。
1516
+ :rtype: :class:`tencentcloud.hai.v20230812.models.ServicePriceDetail`
1517
+ """
1518
+ return self._Price
1519
+
1520
+ @Price.setter
1521
+ def Price(self, Price):
1522
+ self._Price = Price
1523
+
1524
+ @property
1525
+ def RequestId(self):
1526
+ r"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
1527
+ :rtype: str
1528
+ """
1529
+ return self._RequestId
1530
+
1531
+ @RequestId.setter
1532
+ def RequestId(self, RequestId):
1533
+ self._RequestId = RequestId
1534
+
1535
+
1536
+ def _deserialize(self, params):
1537
+ if params.get("Price") is not None:
1538
+ self._Price = ServicePriceDetail()
1539
+ self._Price._deserialize(params.get("Price"))
1540
+ self._RequestId = params.get("RequestId")
1541
+
1542
+
1492
1543
  class Instance(AbstractModel):
1493
1544
  r"""实例信息
1494
1545
 
@@ -3095,6 +3146,44 @@ class SceneInfo(AbstractModel):
3095
3146
 
3096
3147
 
3097
3148
 
3149
+ class ServicePriceDetail(AbstractModel):
3150
+ r"""推理集群费用数据结构体
3151
+
3152
+ """
3153
+
3154
+ def __init__(self):
3155
+ r"""
3156
+ :param _ServicePrice: 推理集群价格信息
3157
+ :type ServicePrice: :class:`tencentcloud.hai.v20230812.models.ItemPrice`
3158
+ """
3159
+ self._ServicePrice = None
3160
+
3161
+ @property
3162
+ def ServicePrice(self):
3163
+ r"""推理集群价格信息
3164
+ :rtype: :class:`tencentcloud.hai.v20230812.models.ItemPrice`
3165
+ """
3166
+ return self._ServicePrice
3167
+
3168
+ @ServicePrice.setter
3169
+ def ServicePrice(self, ServicePrice):
3170
+ self._ServicePrice = ServicePrice
3171
+
3172
+
3173
+ def _deserialize(self, params):
3174
+ if params.get("ServicePrice") is not None:
3175
+ self._ServicePrice = ItemPrice()
3176
+ self._ServicePrice._deserialize(params.get("ServicePrice"))
3177
+ memeber_set = set(params.keys())
3178
+ for name, value in vars(self).items():
3179
+ property_name = name[1:]
3180
+ if property_name in memeber_set:
3181
+ memeber_set.remove(property_name)
3182
+ if len(memeber_set) > 0:
3183
+ warnings.warn("%s fileds are useless." % ",".join(memeber_set))
3184
+
3185
+
3186
+
3098
3187
  class StartInstanceRequest(AbstractModel):
3099
3188
  r"""StartInstance请求参数结构体
3100
3189
 
@@ -3443,5 +3532,84 @@ class TerminateInstancesResponse(AbstractModel):
3443
3532
  self._RequestId = RequestId
3444
3533
 
3445
3534
 
3535
+ def _deserialize(self, params):
3536
+ self._RequestId = params.get("RequestId")
3537
+
3538
+
3539
+ class UpdateServiceConfigsRequest(AbstractModel):
3540
+ r"""UpdateServiceConfigs请求参数结构体
3541
+
3542
+ """
3543
+
3544
+ def __init__(self):
3545
+ r"""
3546
+ :param _ServiceId: 服务ID
3547
+ :type ServiceId: str
3548
+ :param _TargetReplicas: 期望副本数
3549
+ :type TargetReplicas: int
3550
+ """
3551
+ self._ServiceId = None
3552
+ self._TargetReplicas = None
3553
+
3554
+ @property
3555
+ def ServiceId(self):
3556
+ r"""服务ID
3557
+ :rtype: str
3558
+ """
3559
+ return self._ServiceId
3560
+
3561
+ @ServiceId.setter
3562
+ def ServiceId(self, ServiceId):
3563
+ self._ServiceId = ServiceId
3564
+
3565
+ @property
3566
+ def TargetReplicas(self):
3567
+ r"""期望副本数
3568
+ :rtype: int
3569
+ """
3570
+ return self._TargetReplicas
3571
+
3572
+ @TargetReplicas.setter
3573
+ def TargetReplicas(self, TargetReplicas):
3574
+ self._TargetReplicas = TargetReplicas
3575
+
3576
+
3577
+ def _deserialize(self, params):
3578
+ self._ServiceId = params.get("ServiceId")
3579
+ self._TargetReplicas = params.get("TargetReplicas")
3580
+ memeber_set = set(params.keys())
3581
+ for name, value in vars(self).items():
3582
+ property_name = name[1:]
3583
+ if property_name in memeber_set:
3584
+ memeber_set.remove(property_name)
3585
+ if len(memeber_set) > 0:
3586
+ warnings.warn("%s fileds are useless." % ",".join(memeber_set))
3587
+
3588
+
3589
+
3590
+ class UpdateServiceConfigsResponse(AbstractModel):
3591
+ r"""UpdateServiceConfigs返回参数结构体
3592
+
3593
+ """
3594
+
3595
+ def __init__(self):
3596
+ r"""
3597
+ :param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
3598
+ :type RequestId: str
3599
+ """
3600
+ self._RequestId = None
3601
+
3602
+ @property
3603
+ def RequestId(self):
3604
+ r"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
3605
+ :rtype: str
3606
+ """
3607
+ return self._RequestId
3608
+
3609
+ @RequestId.setter
3610
+ def RequestId(self, RequestId):
3611
+ self._RequestId = RequestId
3612
+
3613
+
3446
3614
  def _deserialize(self, params):
3447
3615
  self._RequestId = params.get("RequestId")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: tencentcloud-sdk-python-hai
3
- Version: 3.1.38
3
+ Version: 3.1.41
4
4
  Summary: Tencent Cloud Hai SDK for Python
5
5
  Home-page: https://github.com/TencentCloud/tencentcloud-sdk-python
6
6
  Author: Tencent Cloud
@@ -15,7 +15,7 @@ Classifier: Programming Language :: Python :: 2.7
15
15
  Classifier: Programming Language :: Python :: 3
16
16
  Classifier: Programming Language :: Python :: 3.6
17
17
  Classifier: Programming Language :: Python :: 3.7
18
- Requires-Dist: tencentcloud-sdk-python-common<4.0.0,>=3.1.38
18
+ Requires-Dist: tencentcloud-sdk-python-common<4.0.0,>=3.1.41
19
19
 
20
20
  ============================
21
21
  Tencent Cloud SDK for Python
@@ -0,0 +1 @@
1
+ tencentcloud-sdk-python-common<4.0.0,>=3.1.41
@@ -1 +0,0 @@
1
- tencentcloud-sdk-python-common<4.0.0,>=3.1.38