tencentcloud-sdk-python 3.0.1182__py2.py3-none-any.whl → 3.0.1183__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 +1 -1
- tencentcloud/bpaas/v20181217/models.py +52 -0
- tencentcloud/cls/v20201016/models.py +81 -0
- tencentcloud/cwp/v20180228/models.py +80 -17
- tencentcloud/dbbrain/v20210527/models.py +1 -1
- tencentcloud/fmu/v20191213/fmu_client.py +9 -3
- tencentcloud/hunyuan/v20230901/models.py +427 -4
- tencentcloud/iotexplorer/v20190423/models.py +79 -1
- tencentcloud/ocr/v20181119/models.py +2 -2
- tencentcloud/postgres/v20170312/errorcodes.py +3 -0
- tencentcloud/postgres/v20170312/models.py +20 -8
- tencentcloud/ssl/v20191205/models.py +39 -0
- tencentcloud/tiia/v20190529/tiia_client.py +3 -1
- tencentcloud/trocket/v20230308/models.py +37 -24
- tencentcloud/trocket/v20230308/trocket_client.py +4 -4
- tencentcloud/vod/v20180717/errorcodes.py +12 -0
- tencentcloud/vod/v20180717/models.py +25 -1
- tencentcloud/vod/v20180717/vod_client.py +3 -3
- {tencentcloud_sdk_python-3.0.1182.dist-info → tencentcloud_sdk_python-3.0.1183.dist-info}/METADATA +1 -1
- {tencentcloud_sdk_python-3.0.1182.dist-info → tencentcloud_sdk_python-3.0.1183.dist-info}/RECORD +23 -23
- {tencentcloud_sdk_python-3.0.1182.dist-info → tencentcloud_sdk_python-3.0.1183.dist-info}/LICENSE +0 -0
- {tencentcloud_sdk_python-3.0.1182.dist-info → tencentcloud_sdk_python-3.0.1183.dist-info}/WHEEL +0 -0
- {tencentcloud_sdk_python-3.0.1182.dist-info → tencentcloud_sdk_python-3.0.1183.dist-info}/top_level.txt +0 -0
@@ -25,7 +25,7 @@ class ChatCompletionsRequest(AbstractModel):
|
|
25
25
|
|
26
26
|
def __init__(self):
|
27
27
|
r"""
|
28
|
-
:param _Model: 模型名称,可选值包括 hunyuan-lite、hunyuan-standard、hunyuan-standard-256K、hunyuan-pro。
|
28
|
+
:param _Model: 模型名称,可选值包括 hunyuan-lite、hunyuan-standard、hunyuan-standard-256K、hunyuan-pro、 hunyuan-code、 hunyuan-role、 hunyuan-functioncall、 hunyuan-vision。
|
29
29
|
各模型介绍请阅读 [产品概述](https://cloud.tencent.com/document/product/1729/104753) 中的说明。
|
30
30
|
|
31
31
|
注意:
|
@@ -34,8 +34,8 @@ class ChatCompletionsRequest(AbstractModel):
|
|
34
34
|
:param _Messages: 聊天上下文信息。
|
35
35
|
说明:
|
36
36
|
1. 长度最多为 40,按对话时间从旧到新在数组中排列。
|
37
|
-
2. Message.Role 可选值:system、user、assistant。
|
38
|
-
其中,system 角色可选,如存在则必须位于列表的最开始。user 和 assistant 需交替出现(一问一答),以 user
|
37
|
+
2. Message.Role 可选值:system、user、assistant、 tool。
|
38
|
+
其中,system 角色可选,如存在则必须位于列表的最开始。user(tool) 和 assistant 需交替出现(一问一答),以 user 提问开始,user(tool)提问结束,且 Content 不能为空。Role 的顺序示例:[system(可选) user assistant user assistant user ...]。
|
39
39
|
3. Messages 中 Content 总长度不能超过模型输入长度上限(可参考 [产品概述](https://cloud.tencent.com/document/product/1729/104753) 文档),超过则会截断最前面的内容,只保留尾部内容。
|
40
40
|
:type Messages: list of Message
|
41
41
|
:param _Stream: 流式调用开关。
|
@@ -77,6 +77,16 @@ class ChatCompletionsRequest(AbstractModel):
|
|
77
77
|
3. 关闭时将直接由主模型生成回复内容,可以降低响应时延(对于流式输出时的首字时延尤为明显)。但在少数场景里,回复效果可能会下降。
|
78
78
|
4. 安全审核能力不属于功能增强范围,不受此字段影响。
|
79
79
|
:type EnableEnhancement: bool
|
80
|
+
:param _Tools: 可调用的工具列表,仅对 hunyuan-functioncall 模型生效。
|
81
|
+
:type Tools: list of Tool
|
82
|
+
:param _ToolChoice: 工具使用选项,可选值包括 none、auto、custom。
|
83
|
+
说明:
|
84
|
+
1. 仅对 hunyuan-functioncall 模型生效。
|
85
|
+
2. none:不调用工具;auto:模型自行选择生成回复或调用工具;custom:强制模型调用指定的工具。
|
86
|
+
3. 未设置时,默认值为auto
|
87
|
+
:type ToolChoice: str
|
88
|
+
:param _CustomTool: 强制模型调用指定的工具,当参数ToolChoice为custom时,此参数为必填
|
89
|
+
:type CustomTool: :class:`tencentcloud.hunyuan.v20230901.models.Tool`
|
80
90
|
"""
|
81
91
|
self._Model = None
|
82
92
|
self._Messages = None
|
@@ -85,6 +95,9 @@ class ChatCompletionsRequest(AbstractModel):
|
|
85
95
|
self._TopP = None
|
86
96
|
self._Temperature = None
|
87
97
|
self._EnableEnhancement = None
|
98
|
+
self._Tools = None
|
99
|
+
self._ToolChoice = None
|
100
|
+
self._CustomTool = None
|
88
101
|
|
89
102
|
@property
|
90
103
|
def Model(self):
|
@@ -142,6 +155,30 @@ class ChatCompletionsRequest(AbstractModel):
|
|
142
155
|
def EnableEnhancement(self, EnableEnhancement):
|
143
156
|
self._EnableEnhancement = EnableEnhancement
|
144
157
|
|
158
|
+
@property
|
159
|
+
def Tools(self):
|
160
|
+
return self._Tools
|
161
|
+
|
162
|
+
@Tools.setter
|
163
|
+
def Tools(self, Tools):
|
164
|
+
self._Tools = Tools
|
165
|
+
|
166
|
+
@property
|
167
|
+
def ToolChoice(self):
|
168
|
+
return self._ToolChoice
|
169
|
+
|
170
|
+
@ToolChoice.setter
|
171
|
+
def ToolChoice(self, ToolChoice):
|
172
|
+
self._ToolChoice = ToolChoice
|
173
|
+
|
174
|
+
@property
|
175
|
+
def CustomTool(self):
|
176
|
+
return self._CustomTool
|
177
|
+
|
178
|
+
@CustomTool.setter
|
179
|
+
def CustomTool(self, CustomTool):
|
180
|
+
self._CustomTool = CustomTool
|
181
|
+
|
145
182
|
|
146
183
|
def _deserialize(self, params):
|
147
184
|
self._Model = params.get("Model")
|
@@ -156,6 +193,16 @@ class ChatCompletionsRequest(AbstractModel):
|
|
156
193
|
self._TopP = params.get("TopP")
|
157
194
|
self._Temperature = params.get("Temperature")
|
158
195
|
self._EnableEnhancement = params.get("EnableEnhancement")
|
196
|
+
if params.get("Tools") is not None:
|
197
|
+
self._Tools = []
|
198
|
+
for item in params.get("Tools"):
|
199
|
+
obj = Tool()
|
200
|
+
obj._deserialize(item)
|
201
|
+
self._Tools.append(obj)
|
202
|
+
self._ToolChoice = params.get("ToolChoice")
|
203
|
+
if params.get("CustomTool") is not None:
|
204
|
+
self._CustomTool = Tool()
|
205
|
+
self._CustomTool._deserialize(params.get("CustomTool"))
|
159
206
|
memeber_set = set(params.keys())
|
160
207
|
for name, value in vars(self).items():
|
161
208
|
property_name = name[1:]
|
@@ -339,6 +386,70 @@ stop 表示输出正常结束,sensitive 只在开启流式输出审核时会
|
|
339
386
|
|
340
387
|
|
341
388
|
|
389
|
+
class Content(AbstractModel):
|
390
|
+
"""可以传入多种类型的内容,如图片或文本。当前只支持传入单张图片,传入多张图片时,以第一个图片为准。
|
391
|
+
|
392
|
+
"""
|
393
|
+
|
394
|
+
def __init__(self):
|
395
|
+
r"""
|
396
|
+
:param _Type: 内容类型
|
397
|
+
注意:
|
398
|
+
当前只支持传入单张图片,传入多张图片时,以第一个图片为准。
|
399
|
+
注意:此字段可能返回 null,表示取不到有效值。
|
400
|
+
:type Type: str
|
401
|
+
:param _Text: 当 Type 为 text 时使用,表示具体的文本内容
|
402
|
+
注意:此字段可能返回 null,表示取不到有效值。
|
403
|
+
:type Text: str
|
404
|
+
:param _ImageUrl: 当 Type 为 image_url 时使用,表示具体的图片内容
|
405
|
+
注意:此字段可能返回 null,表示取不到有效值。
|
406
|
+
:type ImageUrl: :class:`tencentcloud.hunyuan.v20230901.models.ImageUrl`
|
407
|
+
"""
|
408
|
+
self._Type = None
|
409
|
+
self._Text = None
|
410
|
+
self._ImageUrl = None
|
411
|
+
|
412
|
+
@property
|
413
|
+
def Type(self):
|
414
|
+
return self._Type
|
415
|
+
|
416
|
+
@Type.setter
|
417
|
+
def Type(self, Type):
|
418
|
+
self._Type = Type
|
419
|
+
|
420
|
+
@property
|
421
|
+
def Text(self):
|
422
|
+
return self._Text
|
423
|
+
|
424
|
+
@Text.setter
|
425
|
+
def Text(self, Text):
|
426
|
+
self._Text = Text
|
427
|
+
|
428
|
+
@property
|
429
|
+
def ImageUrl(self):
|
430
|
+
return self._ImageUrl
|
431
|
+
|
432
|
+
@ImageUrl.setter
|
433
|
+
def ImageUrl(self, ImageUrl):
|
434
|
+
self._ImageUrl = ImageUrl
|
435
|
+
|
436
|
+
|
437
|
+
def _deserialize(self, params):
|
438
|
+
self._Type = params.get("Type")
|
439
|
+
self._Text = params.get("Text")
|
440
|
+
if params.get("ImageUrl") is not None:
|
441
|
+
self._ImageUrl = ImageUrl()
|
442
|
+
self._ImageUrl._deserialize(params.get("ImageUrl"))
|
443
|
+
memeber_set = set(params.keys())
|
444
|
+
for name, value in vars(self).items():
|
445
|
+
property_name = name[1:]
|
446
|
+
if property_name in memeber_set:
|
447
|
+
memeber_set.remove(property_name)
|
448
|
+
if len(memeber_set) > 0:
|
449
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
450
|
+
|
451
|
+
|
452
|
+
|
342
453
|
class Delta(AbstractModel):
|
343
454
|
"""返回的内容(流式返回)
|
344
455
|
|
@@ -350,9 +461,16 @@ class Delta(AbstractModel):
|
|
350
461
|
:type Role: str
|
351
462
|
:param _Content: 内容详情。
|
352
463
|
:type Content: str
|
464
|
+
:param _ToolCalls: 模型生成的工具调用,仅 hunyuan-functioncall 模型支持
|
465
|
+
说明:
|
466
|
+
对于每一次的输出值应该以Id为标识对Type、Name、Arguments字段进行合并。
|
467
|
+
|
468
|
+
注意:此字段可能返回 null,表示取不到有效值。
|
469
|
+
:type ToolCalls: list of ToolCall
|
353
470
|
"""
|
354
471
|
self._Role = None
|
355
472
|
self._Content = None
|
473
|
+
self._ToolCalls = None
|
356
474
|
|
357
475
|
@property
|
358
476
|
def Role(self):
|
@@ -370,10 +488,24 @@ class Delta(AbstractModel):
|
|
370
488
|
def Content(self, Content):
|
371
489
|
self._Content = Content
|
372
490
|
|
491
|
+
@property
|
492
|
+
def ToolCalls(self):
|
493
|
+
return self._ToolCalls
|
494
|
+
|
495
|
+
@ToolCalls.setter
|
496
|
+
def ToolCalls(self, ToolCalls):
|
497
|
+
self._ToolCalls = ToolCalls
|
498
|
+
|
373
499
|
|
374
500
|
def _deserialize(self, params):
|
375
501
|
self._Role = params.get("Role")
|
376
502
|
self._Content = params.get("Content")
|
503
|
+
if params.get("ToolCalls") is not None:
|
504
|
+
self._ToolCalls = []
|
505
|
+
for item in params.get("ToolCalls"):
|
506
|
+
obj = ToolCall()
|
507
|
+
obj._deserialize(item)
|
508
|
+
self._ToolCalls.append(obj)
|
377
509
|
memeber_set = set(params.keys())
|
378
510
|
for name, value in vars(self).items():
|
379
511
|
property_name = name[1:]
|
@@ -720,6 +852,40 @@ class GetTokenCountResponse(AbstractModel):
|
|
720
852
|
self._RequestId = params.get("RequestId")
|
721
853
|
|
722
854
|
|
855
|
+
class ImageUrl(AbstractModel):
|
856
|
+
"""具体的图片内容
|
857
|
+
|
858
|
+
"""
|
859
|
+
|
860
|
+
def __init__(self):
|
861
|
+
r"""
|
862
|
+
:param _Url: 图片的 Url(以 http:// 或 https:// 开头)
|
863
|
+
注意:此字段可能返回 null,表示取不到有效值。
|
864
|
+
:type Url: str
|
865
|
+
"""
|
866
|
+
self._Url = None
|
867
|
+
|
868
|
+
@property
|
869
|
+
def Url(self):
|
870
|
+
return self._Url
|
871
|
+
|
872
|
+
@Url.setter
|
873
|
+
def Url(self, Url):
|
874
|
+
self._Url = Url
|
875
|
+
|
876
|
+
|
877
|
+
def _deserialize(self, params):
|
878
|
+
self._Url = params.get("Url")
|
879
|
+
memeber_set = set(params.keys())
|
880
|
+
for name, value in vars(self).items():
|
881
|
+
property_name = name[1:]
|
882
|
+
if property_name in memeber_set:
|
883
|
+
memeber_set.remove(property_name)
|
884
|
+
if len(memeber_set) > 0:
|
885
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
886
|
+
|
887
|
+
|
888
|
+
|
723
889
|
class Message(AbstractModel):
|
724
890
|
"""会话内容
|
725
891
|
|
@@ -727,13 +893,25 @@ class Message(AbstractModel):
|
|
727
893
|
|
728
894
|
def __init__(self):
|
729
895
|
r"""
|
730
|
-
:param _Role: 角色,可选值包括 system、user、assistant。
|
896
|
+
:param _Role: 角色,可选值包括 system、user、assistant、 tool。
|
731
897
|
:type Role: str
|
732
898
|
:param _Content: 文本内容
|
733
899
|
:type Content: str
|
900
|
+
:param _Contents: 多种类型内容(目前支持图片和文本),仅 hunyuan-vision 模型支持
|
901
|
+
注意:此字段可能返回 null,表示取不到有效值。
|
902
|
+
:type Contents: list of Content
|
903
|
+
:param _ToolCallId: 当role为tool时传入,标识具体的函数调用
|
904
|
+
注意:此字段可能返回 null,表示取不到有效值。
|
905
|
+
:type ToolCallId: str
|
906
|
+
:param _ToolCalls: 模型生成的工具调用,仅 hunyuan-functioncall 模型支持
|
907
|
+
注意:此字段可能返回 null,表示取不到有效值。
|
908
|
+
:type ToolCalls: list of ToolCall
|
734
909
|
"""
|
735
910
|
self._Role = None
|
736
911
|
self._Content = None
|
912
|
+
self._Contents = None
|
913
|
+
self._ToolCallId = None
|
914
|
+
self._ToolCalls = None
|
737
915
|
|
738
916
|
@property
|
739
917
|
def Role(self):
|
@@ -751,10 +929,47 @@ class Message(AbstractModel):
|
|
751
929
|
def Content(self, Content):
|
752
930
|
self._Content = Content
|
753
931
|
|
932
|
+
@property
|
933
|
+
def Contents(self):
|
934
|
+
return self._Contents
|
935
|
+
|
936
|
+
@Contents.setter
|
937
|
+
def Contents(self, Contents):
|
938
|
+
self._Contents = Contents
|
939
|
+
|
940
|
+
@property
|
941
|
+
def ToolCallId(self):
|
942
|
+
return self._ToolCallId
|
943
|
+
|
944
|
+
@ToolCallId.setter
|
945
|
+
def ToolCallId(self, ToolCallId):
|
946
|
+
self._ToolCallId = ToolCallId
|
947
|
+
|
948
|
+
@property
|
949
|
+
def ToolCalls(self):
|
950
|
+
return self._ToolCalls
|
951
|
+
|
952
|
+
@ToolCalls.setter
|
953
|
+
def ToolCalls(self, ToolCalls):
|
954
|
+
self._ToolCalls = ToolCalls
|
955
|
+
|
754
956
|
|
755
957
|
def _deserialize(self, params):
|
756
958
|
self._Role = params.get("Role")
|
757
959
|
self._Content = params.get("Content")
|
960
|
+
if params.get("Contents") is not None:
|
961
|
+
self._Contents = []
|
962
|
+
for item in params.get("Contents"):
|
963
|
+
obj = Content()
|
964
|
+
obj._deserialize(item)
|
965
|
+
self._Contents.append(obj)
|
966
|
+
self._ToolCallId = params.get("ToolCallId")
|
967
|
+
if params.get("ToolCalls") is not None:
|
968
|
+
self._ToolCalls = []
|
969
|
+
for item in params.get("ToolCalls"):
|
970
|
+
obj = ToolCall()
|
971
|
+
obj._deserialize(item)
|
972
|
+
self._ToolCalls.append(obj)
|
758
973
|
memeber_set = set(params.keys())
|
759
974
|
for name, value in vars(self).items():
|
760
975
|
property_name = name[1:]
|
@@ -1041,6 +1256,214 @@ class SubmitHunyuanImageJobResponse(AbstractModel):
|
|
1041
1256
|
self._RequestId = params.get("RequestId")
|
1042
1257
|
|
1043
1258
|
|
1259
|
+
class Tool(AbstractModel):
|
1260
|
+
"""用户指定模型使用的工具
|
1261
|
+
|
1262
|
+
"""
|
1263
|
+
|
1264
|
+
def __init__(self):
|
1265
|
+
r"""
|
1266
|
+
:param _Type: 工具类型,当前只支持function
|
1267
|
+
:type Type: str
|
1268
|
+
:param _Function: 具体要调用的function
|
1269
|
+
:type Function: :class:`tencentcloud.hunyuan.v20230901.models.ToolFunction`
|
1270
|
+
"""
|
1271
|
+
self._Type = None
|
1272
|
+
self._Function = None
|
1273
|
+
|
1274
|
+
@property
|
1275
|
+
def Type(self):
|
1276
|
+
return self._Type
|
1277
|
+
|
1278
|
+
@Type.setter
|
1279
|
+
def Type(self, Type):
|
1280
|
+
self._Type = Type
|
1281
|
+
|
1282
|
+
@property
|
1283
|
+
def Function(self):
|
1284
|
+
return self._Function
|
1285
|
+
|
1286
|
+
@Function.setter
|
1287
|
+
def Function(self, Function):
|
1288
|
+
self._Function = Function
|
1289
|
+
|
1290
|
+
|
1291
|
+
def _deserialize(self, params):
|
1292
|
+
self._Type = params.get("Type")
|
1293
|
+
if params.get("Function") is not None:
|
1294
|
+
self._Function = ToolFunction()
|
1295
|
+
self._Function._deserialize(params.get("Function"))
|
1296
|
+
memeber_set = set(params.keys())
|
1297
|
+
for name, value in vars(self).items():
|
1298
|
+
property_name = name[1:]
|
1299
|
+
if property_name in memeber_set:
|
1300
|
+
memeber_set.remove(property_name)
|
1301
|
+
if len(memeber_set) > 0:
|
1302
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
1303
|
+
|
1304
|
+
|
1305
|
+
|
1306
|
+
class ToolCall(AbstractModel):
|
1307
|
+
"""模型生成的工具调用
|
1308
|
+
|
1309
|
+
"""
|
1310
|
+
|
1311
|
+
def __init__(self):
|
1312
|
+
r"""
|
1313
|
+
:param _Id: 工具调用id
|
1314
|
+
:type Id: str
|
1315
|
+
:param _Type: 工具调用类型,当前只支持function
|
1316
|
+
:type Type: str
|
1317
|
+
:param _Function: 具体的function调用
|
1318
|
+
:type Function: :class:`tencentcloud.hunyuan.v20230901.models.ToolCallFunction`
|
1319
|
+
"""
|
1320
|
+
self._Id = None
|
1321
|
+
self._Type = None
|
1322
|
+
self._Function = None
|
1323
|
+
|
1324
|
+
@property
|
1325
|
+
def Id(self):
|
1326
|
+
return self._Id
|
1327
|
+
|
1328
|
+
@Id.setter
|
1329
|
+
def Id(self, Id):
|
1330
|
+
self._Id = Id
|
1331
|
+
|
1332
|
+
@property
|
1333
|
+
def Type(self):
|
1334
|
+
return self._Type
|
1335
|
+
|
1336
|
+
@Type.setter
|
1337
|
+
def Type(self, Type):
|
1338
|
+
self._Type = Type
|
1339
|
+
|
1340
|
+
@property
|
1341
|
+
def Function(self):
|
1342
|
+
return self._Function
|
1343
|
+
|
1344
|
+
@Function.setter
|
1345
|
+
def Function(self, Function):
|
1346
|
+
self._Function = Function
|
1347
|
+
|
1348
|
+
|
1349
|
+
def _deserialize(self, params):
|
1350
|
+
self._Id = params.get("Id")
|
1351
|
+
self._Type = params.get("Type")
|
1352
|
+
if params.get("Function") is not None:
|
1353
|
+
self._Function = ToolCallFunction()
|
1354
|
+
self._Function._deserialize(params.get("Function"))
|
1355
|
+
memeber_set = set(params.keys())
|
1356
|
+
for name, value in vars(self).items():
|
1357
|
+
property_name = name[1:]
|
1358
|
+
if property_name in memeber_set:
|
1359
|
+
memeber_set.remove(property_name)
|
1360
|
+
if len(memeber_set) > 0:
|
1361
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
1362
|
+
|
1363
|
+
|
1364
|
+
|
1365
|
+
class ToolCallFunction(AbstractModel):
|
1366
|
+
"""具体的function调用
|
1367
|
+
|
1368
|
+
"""
|
1369
|
+
|
1370
|
+
def __init__(self):
|
1371
|
+
r"""
|
1372
|
+
:param _Name: function名称
|
1373
|
+
:type Name: str
|
1374
|
+
:param _Arguments: function参数,一般为json字符串
|
1375
|
+
:type Arguments: str
|
1376
|
+
"""
|
1377
|
+
self._Name = None
|
1378
|
+
self._Arguments = None
|
1379
|
+
|
1380
|
+
@property
|
1381
|
+
def Name(self):
|
1382
|
+
return self._Name
|
1383
|
+
|
1384
|
+
@Name.setter
|
1385
|
+
def Name(self, Name):
|
1386
|
+
self._Name = Name
|
1387
|
+
|
1388
|
+
@property
|
1389
|
+
def Arguments(self):
|
1390
|
+
return self._Arguments
|
1391
|
+
|
1392
|
+
@Arguments.setter
|
1393
|
+
def Arguments(self, Arguments):
|
1394
|
+
self._Arguments = Arguments
|
1395
|
+
|
1396
|
+
|
1397
|
+
def _deserialize(self, params):
|
1398
|
+
self._Name = params.get("Name")
|
1399
|
+
self._Arguments = params.get("Arguments")
|
1400
|
+
memeber_set = set(params.keys())
|
1401
|
+
for name, value in vars(self).items():
|
1402
|
+
property_name = name[1:]
|
1403
|
+
if property_name in memeber_set:
|
1404
|
+
memeber_set.remove(property_name)
|
1405
|
+
if len(memeber_set) > 0:
|
1406
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
1407
|
+
|
1408
|
+
|
1409
|
+
|
1410
|
+
class ToolFunction(AbstractModel):
|
1411
|
+
"""function定义
|
1412
|
+
|
1413
|
+
"""
|
1414
|
+
|
1415
|
+
def __init__(self):
|
1416
|
+
r"""
|
1417
|
+
:param _Name: function名称,只能包含a-z,A-Z,0-9,\_或-
|
1418
|
+
:type Name: str
|
1419
|
+
:param _Parameters: function参数,一般为json字符串
|
1420
|
+
:type Parameters: str
|
1421
|
+
:param _Description: function的简单描述
|
1422
|
+
:type Description: str
|
1423
|
+
"""
|
1424
|
+
self._Name = None
|
1425
|
+
self._Parameters = None
|
1426
|
+
self._Description = None
|
1427
|
+
|
1428
|
+
@property
|
1429
|
+
def Name(self):
|
1430
|
+
return self._Name
|
1431
|
+
|
1432
|
+
@Name.setter
|
1433
|
+
def Name(self, Name):
|
1434
|
+
self._Name = Name
|
1435
|
+
|
1436
|
+
@property
|
1437
|
+
def Parameters(self):
|
1438
|
+
return self._Parameters
|
1439
|
+
|
1440
|
+
@Parameters.setter
|
1441
|
+
def Parameters(self, Parameters):
|
1442
|
+
self._Parameters = Parameters
|
1443
|
+
|
1444
|
+
@property
|
1445
|
+
def Description(self):
|
1446
|
+
return self._Description
|
1447
|
+
|
1448
|
+
@Description.setter
|
1449
|
+
def Description(self, Description):
|
1450
|
+
self._Description = Description
|
1451
|
+
|
1452
|
+
|
1453
|
+
def _deserialize(self, params):
|
1454
|
+
self._Name = params.get("Name")
|
1455
|
+
self._Parameters = params.get("Parameters")
|
1456
|
+
self._Description = params.get("Description")
|
1457
|
+
memeber_set = set(params.keys())
|
1458
|
+
for name, value in vars(self).items():
|
1459
|
+
property_name = name[1:]
|
1460
|
+
if property_name in memeber_set:
|
1461
|
+
memeber_set.remove(property_name)
|
1462
|
+
if len(memeber_set) > 0:
|
1463
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
1464
|
+
|
1465
|
+
|
1466
|
+
|
1044
1467
|
class Usage(AbstractModel):
|
1045
1468
|
"""Token 数量
|
1046
1469
|
|
@@ -25,7 +25,7 @@ class ActivateTWeCallLicenseRequest(AbstractModel):
|
|
25
25
|
|
26
26
|
def __init__(self):
|
27
27
|
r"""
|
28
|
-
:param _PkgType: TWecall类型: 1-家庭安防场景; 2-穿戴类场景; 3-生活娱乐场景; 4-对讲及其它场景
|
28
|
+
:param _PkgType: TWecall类型: 0-测试激活码; 1-家庭安防场景; 2-穿戴类场景; 3-生活娱乐场景; 4-对讲及其它场景
|
29
29
|
:type PkgType: int
|
30
30
|
:param _MiniProgramAppId: appId
|
31
31
|
:type MiniProgramAppId: str
|
@@ -87,11 +87,23 @@ class ActivateTWeCallLicenseResponse(AbstractModel):
|
|
87
87
|
|
88
88
|
def __init__(self):
|
89
89
|
r"""
|
90
|
+
:param _DeviceList: 设备激活返回数据
|
91
|
+
注意:此字段可能返回 null,表示取不到有效值。
|
92
|
+
:type DeviceList: list of DeviceActiveResult
|
90
93
|
:param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
91
94
|
:type RequestId: str
|
92
95
|
"""
|
96
|
+
self._DeviceList = None
|
93
97
|
self._RequestId = None
|
94
98
|
|
99
|
+
@property
|
100
|
+
def DeviceList(self):
|
101
|
+
return self._DeviceList
|
102
|
+
|
103
|
+
@DeviceList.setter
|
104
|
+
def DeviceList(self, DeviceList):
|
105
|
+
self._DeviceList = DeviceList
|
106
|
+
|
95
107
|
@property
|
96
108
|
def RequestId(self):
|
97
109
|
return self._RequestId
|
@@ -102,6 +114,12 @@ class ActivateTWeCallLicenseResponse(AbstractModel):
|
|
102
114
|
|
103
115
|
|
104
116
|
def _deserialize(self, params):
|
117
|
+
if params.get("DeviceList") is not None:
|
118
|
+
self._DeviceList = []
|
119
|
+
for item in params.get("DeviceList"):
|
120
|
+
obj = DeviceActiveResult()
|
121
|
+
obj._deserialize(item)
|
122
|
+
self._DeviceList.append(obj)
|
105
123
|
self._RequestId = params.get("RequestId")
|
106
124
|
|
107
125
|
|
@@ -9934,6 +9952,66 @@ class DescribeTopicRuleResponse(AbstractModel):
|
|
9934
9952
|
self._RequestId = params.get("RequestId")
|
9935
9953
|
|
9936
9954
|
|
9955
|
+
class DeviceActiveResult(AbstractModel):
|
9956
|
+
"""设备激活结果数据
|
9957
|
+
|
9958
|
+
"""
|
9959
|
+
|
9960
|
+
def __init__(self):
|
9961
|
+
r"""
|
9962
|
+
:param _ModelId: 模版ID
|
9963
|
+
注意:此字段可能返回 null,表示取不到有效值。
|
9964
|
+
:type ModelId: str
|
9965
|
+
:param _Sn: SN信息
|
9966
|
+
注意:此字段可能返回 null,表示取不到有效值。
|
9967
|
+
:type Sn: str
|
9968
|
+
:param _ErrCode: 设备激活状态,0:激活成功;9800020:设备数超出限制;9800040:资源包类型和设备类型不匹配;9800039:资源包余额不足;9800037:激活码序号已使用;9800038:设备有效期超出限制;
|
9969
|
+
注意:此字段可能返回 null,表示取不到有效值。
|
9970
|
+
:type ErrCode: int
|
9971
|
+
"""
|
9972
|
+
self._ModelId = None
|
9973
|
+
self._Sn = None
|
9974
|
+
self._ErrCode = None
|
9975
|
+
|
9976
|
+
@property
|
9977
|
+
def ModelId(self):
|
9978
|
+
return self._ModelId
|
9979
|
+
|
9980
|
+
@ModelId.setter
|
9981
|
+
def ModelId(self, ModelId):
|
9982
|
+
self._ModelId = ModelId
|
9983
|
+
|
9984
|
+
@property
|
9985
|
+
def Sn(self):
|
9986
|
+
return self._Sn
|
9987
|
+
|
9988
|
+
@Sn.setter
|
9989
|
+
def Sn(self, Sn):
|
9990
|
+
self._Sn = Sn
|
9991
|
+
|
9992
|
+
@property
|
9993
|
+
def ErrCode(self):
|
9994
|
+
return self._ErrCode
|
9995
|
+
|
9996
|
+
@ErrCode.setter
|
9997
|
+
def ErrCode(self, ErrCode):
|
9998
|
+
self._ErrCode = ErrCode
|
9999
|
+
|
10000
|
+
|
10001
|
+
def _deserialize(self, params):
|
10002
|
+
self._ModelId = params.get("ModelId")
|
10003
|
+
self._Sn = params.get("Sn")
|
10004
|
+
self._ErrCode = params.get("ErrCode")
|
10005
|
+
memeber_set = set(params.keys())
|
10006
|
+
for name, value in vars(self).items():
|
10007
|
+
property_name = name[1:]
|
10008
|
+
if property_name in memeber_set:
|
10009
|
+
memeber_set.remove(property_name)
|
10010
|
+
if len(memeber_set) > 0:
|
10011
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
10012
|
+
|
10013
|
+
|
10014
|
+
|
9937
10015
|
class DeviceData(AbstractModel):
|
9938
10016
|
"""DeviceData
|
9939
10017
|
|
@@ -17163,8 +17163,8 @@ class RecognizeGeneralTextImageWarnRequest(AbstractModel):
|
|
17163
17163
|
:param _PdfPageNumber: 需要识别的PDF页面的对应页码,传入时仅支持PDF单页识别,当上传文件为PDF且EnablePdf参数值为true时有效,默认值为1。 示例值:1
|
17164
17164
|
:type PdfPageNumber: int
|
17165
17165
|
:param _Type: 支持的模板类型
|
17166
|
-
- General
|
17167
|
-
- LicensePlate
|
17166
|
+
- General 通用告警(支持所有类型告警)
|
17167
|
+
- LicensePlate 车牌告警(支持翻拍告警)
|
17168
17168
|
:type Type: str
|
17169
17169
|
"""
|
17170
17170
|
self._ImageUrl = None
|
@@ -353,6 +353,9 @@ INVALIDPARAMETERVALUE_INVALIDACCOUNTFORMAT = 'InvalidParameterValue.InvalidAccou
|
|
353
353
|
# 当前账号名称不允许是保留字符。
|
354
354
|
INVALIDPARAMETERVALUE_INVALIDACCOUNTNAME = 'InvalidParameterValue.InvalidAccountName'
|
355
355
|
|
356
|
+
# 账号设置无效,请遵循账号命名规则:账号名需要1-16个字符,只能由字母、数字或下划线组成;不能为postgres;不能由数字、pg_及tencentdb_开头;所有规则均不区分大小写。
|
357
|
+
INVALIDPARAMETERVALUE_INVALIDACCOUNTNAMEERROR = 'InvalidParameterValue.InvalidAccountNameError'
|
358
|
+
|
356
359
|
# 数据库字符集错误,当前只支持UTF8、LATIN1。
|
357
360
|
INVALIDPARAMETERVALUE_INVALIDCHARSET = 'InvalidParameterValue.InvalidCharset'
|
358
361
|
|