tccli 3.0.1233.1__py2.py3-none-any.whl → 3.0.1235.1__py2.py3-none-any.whl

Sign up to get free protection for your applications and to get access to all the features.
Files changed (41) hide show
  1. tccli/__init__.py +1 -1
  2. tccli/services/cdb/v20170320/api.json +15 -15
  3. tccli/services/cls/v20201016/api.json +4 -4
  4. tccli/services/cwp/cwp_client.py +326 -8
  5. tccli/services/cwp/v20180228/api.json +488 -1
  6. tccli/services/cwp/v20180228/examples.json +48 -0
  7. tccli/services/ess/v20201111/api.json +1 -1
  8. tccli/services/essbasic/v20210526/api.json +11 -11
  9. tccli/services/faceid/v20180301/api.json +19 -0
  10. tccli/services/hunyuan/v20230901/api.json +12 -3
  11. tccli/services/iotexplorer/iotexplorer_client.py +106 -0
  12. tccli/services/iotexplorer/v20190423/api.json +173 -4
  13. tccli/services/iotexplorer/v20190423/examples.json +16 -0
  14. tccli/services/iotvideo/iotvideo_client.py +106 -0
  15. tccli/services/iotvideo/v20211125/api.json +169 -0
  16. tccli/services/iotvideo/v20211125/examples.json +16 -0
  17. tccli/services/ivld/v20210903/api.json +1 -1
  18. tccli/services/lighthouse/v20200324/api.json +59 -59
  19. tccli/services/lighthouse/v20200324/examples.json +4 -4
  20. tccli/services/lke/v20231130/api.json +2 -2
  21. tccli/services/memcached/v20190318/api.json +6 -6
  22. tccli/services/ocr/v20181119/api.json +5 -5
  23. tccli/services/ocr/v20181119/examples.json +7 -7
  24. tccli/services/privatedns/v20201028/api.json +8 -8
  25. tccli/services/smh/v20210712/api.json +7 -7
  26. tccli/services/smh/v20210712/examples.json +1 -1
  27. tccli/services/ssl/v20191205/api.json +46 -33
  28. tccli/services/ssl/v20191205/examples.json +15 -15
  29. tccli/services/tcbr/v20220217/api.json +71 -71
  30. tccli/services/tcbr/v20220217/examples.json +13 -31
  31. tccli/services/teo/v20220901/api.json +1 -1
  32. tccli/services/trocket/v20230308/api.json +19 -0
  33. tccli/services/tsf/v20180326/api.json +1577 -1408
  34. tccli/services/tsf/v20180326/examples.json +55 -61
  35. tccli/services/vpc/v20170312/api.json +9 -0
  36. tccli/services/wedata/v20210820/api.json +87 -0
  37. {tccli-3.0.1233.1.dist-info → tccli-3.0.1235.1.dist-info}/METADATA +2 -2
  38. {tccli-3.0.1233.1.dist-info → tccli-3.0.1235.1.dist-info}/RECORD +41 -41
  39. {tccli-3.0.1233.1.dist-info → tccli-3.0.1235.1.dist-info}/WHEEL +0 -0
  40. {tccli-3.0.1233.1.dist-info → tccli-3.0.1235.1.dist-info}/entry_points.txt +0 -0
  41. {tccli-3.0.1233.1.dist-info → tccli-3.0.1235.1.dist-info}/license_files/LICENSE +0 -0
@@ -5065,6 +5065,58 @@ def doCreateCOSCredentials(args, parsed_globals):
5065
5065
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
5066
5066
 
5067
5067
 
5068
+ def doCreateFreeCloudStorage(args, parsed_globals):
5069
+ g_param = parse_global_arg(parsed_globals)
5070
+
5071
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
5072
+ cred = credential.CVMRoleCredential()
5073
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
5074
+ cred = credential.STSAssumeRoleCredential(
5075
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
5076
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
5077
+ )
5078
+ elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
5079
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
5080
+ else:
5081
+ cred = credential.Credential(
5082
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
5083
+ )
5084
+ http_profile = HttpProfile(
5085
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
5086
+ reqMethod="POST",
5087
+ endpoint=g_param[OptionsDefine.Endpoint],
5088
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
5089
+ )
5090
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
5091
+ if g_param[OptionsDefine.Language]:
5092
+ profile.language = g_param[OptionsDefine.Language]
5093
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
5094
+ client = mod.IotvideoClient(cred, g_param[OptionsDefine.Region], profile)
5095
+ client._sdkVersion += ("_CLI_" + __version__)
5096
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
5097
+ model = models.CreateFreeCloudStorageRequest()
5098
+ model.from_json_string(json.dumps(args))
5099
+ start_time = time.time()
5100
+ while True:
5101
+ rsp = client.CreateFreeCloudStorage(model)
5102
+ result = rsp.to_json_string()
5103
+ try:
5104
+ json_obj = json.loads(result)
5105
+ except TypeError as e:
5106
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
5107
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
5108
+ break
5109
+ cur_time = time.time()
5110
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
5111
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
5112
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
5113
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
5114
+ else:
5115
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
5116
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
5117
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
5118
+
5119
+
5068
5120
  def doSendOnlineMsg(args, parsed_globals):
5069
5121
  g_param = parse_global_arg(parsed_globals)
5070
5122
 
@@ -6521,6 +6573,58 @@ def doDisableDevice(args, parsed_globals):
6521
6573
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
6522
6574
 
6523
6575
 
6576
+ def doCreateDeviceChannel(args, parsed_globals):
6577
+ g_param = parse_global_arg(parsed_globals)
6578
+
6579
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
6580
+ cred = credential.CVMRoleCredential()
6581
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
6582
+ cred = credential.STSAssumeRoleCredential(
6583
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
6584
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
6585
+ )
6586
+ elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
6587
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
6588
+ else:
6589
+ cred = credential.Credential(
6590
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
6591
+ )
6592
+ http_profile = HttpProfile(
6593
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
6594
+ reqMethod="POST",
6595
+ endpoint=g_param[OptionsDefine.Endpoint],
6596
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
6597
+ )
6598
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
6599
+ if g_param[OptionsDefine.Language]:
6600
+ profile.language = g_param[OptionsDefine.Language]
6601
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
6602
+ client = mod.IotvideoClient(cred, g_param[OptionsDefine.Region], profile)
6603
+ client._sdkVersion += ("_CLI_" + __version__)
6604
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
6605
+ model = models.CreateDeviceChannelRequest()
6606
+ model.from_json_string(json.dumps(args))
6607
+ start_time = time.time()
6608
+ while True:
6609
+ rsp = client.CreateDeviceChannel(model)
6610
+ result = rsp.to_json_string()
6611
+ try:
6612
+ json_obj = json.loads(result)
6613
+ except TypeError as e:
6614
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
6615
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
6616
+ break
6617
+ cur_time = time.time()
6618
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
6619
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
6620
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
6621
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
6622
+ else:
6623
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
6624
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
6625
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
6626
+
6627
+
6524
6628
  def doRunTestOtaVersion(args, parsed_globals):
6525
6629
  g_param = parse_global_arg(parsed_globals)
6526
6630
 
@@ -8505,6 +8609,7 @@ ACTION_MAP = {
8505
8609
  "DescribeDeviceActionHistory": doDescribeDeviceActionHistory,
8506
8610
  "DescribeIotModel": doDescribeIotModel,
8507
8611
  "CreateCOSCredentials": doCreateCOSCredentials,
8612
+ "CreateFreeCloudStorage": doCreateFreeCloudStorage,
8508
8613
  "SendOnlineMsg": doSendOnlineMsg,
8509
8614
  "CreateTraceIds": doCreateTraceIds,
8510
8615
  "CreateBatch": doCreateBatch,
@@ -8533,6 +8638,7 @@ ACTION_MAP = {
8533
8638
  "DescribeMessageDataStats": doDescribeMessageDataStats,
8534
8639
  "DeleteCloudStorageEvent": doDeleteCloudStorageEvent,
8535
8640
  "DisableDevice": doDisableDevice,
8641
+ "CreateDeviceChannel": doCreateDeviceChannel,
8536
8642
  "RunTestOtaVersion": doRunTestOtaVersion,
8537
8643
  "DescribeP2PInfo": doDescribeP2PInfo,
8538
8644
  "CreateIotDataType": doCreateIotDataType,
@@ -105,6 +105,13 @@
105
105
  "output": "CreateDataForwardResponse",
106
106
  "status": "online"
107
107
  },
108
+ "CreateDeviceChannel": {
109
+ "document": "创建设备通道",
110
+ "input": "CreateDeviceChannelRequest",
111
+ "name": "创建设备通道",
112
+ "output": "CreateDeviceChannelResponse",
113
+ "status": "online"
114
+ },
108
115
  "CreateForwardRule": {
109
116
  "document": "创建转发规则",
110
117
  "input": "CreateForwardRuleRequest",
@@ -112,6 +119,13 @@
112
119
  "output": "CreateForwardRuleResponse",
113
120
  "status": "online"
114
121
  },
122
+ "CreateFreeCloudStorage": {
123
+ "document": "开通免费云存服务",
124
+ "input": "CreateFreeCloudStorageRequest",
125
+ "name": "开通云存卡服务",
126
+ "output": "CreateFreeCloudStorageResponse",
127
+ "status": "online"
128
+ },
115
129
  "CreateProduct": {
116
130
  "document": "创建产品",
117
131
  "input": "CreateProductRequest",
@@ -2274,6 +2288,51 @@
2274
2288
  ],
2275
2289
  "type": "object"
2276
2290
  },
2291
+ "CreateDeviceChannelRequest": {
2292
+ "document": "CreateDeviceChannel请求参数结构体",
2293
+ "members": [
2294
+ {
2295
+ "disabled": false,
2296
+ "document": "产品ID",
2297
+ "example": "H541SOP191",
2298
+ "member": "string",
2299
+ "name": "ProductId",
2300
+ "required": true,
2301
+ "type": "string"
2302
+ },
2303
+ {
2304
+ "disabled": false,
2305
+ "document": "设备名称",
2306
+ "example": "event_36502632_1",
2307
+ "member": "string",
2308
+ "name": "DeviceName",
2309
+ "required": true,
2310
+ "type": "string"
2311
+ },
2312
+ {
2313
+ "disabled": false,
2314
+ "document": "通道ID",
2315
+ "example": "1",
2316
+ "member": "uint64",
2317
+ "name": "ChannelId",
2318
+ "required": true,
2319
+ "type": "int"
2320
+ }
2321
+ ],
2322
+ "type": "object"
2323
+ },
2324
+ "CreateDeviceChannelResponse": {
2325
+ "document": "CreateDeviceChannel返回参数结构体",
2326
+ "members": [
2327
+ {
2328
+ "document": "唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。",
2329
+ "member": "string",
2330
+ "name": "RequestId",
2331
+ "type": "string"
2332
+ }
2333
+ ],
2334
+ "type": "object"
2335
+ },
2277
2336
  "CreateForwardRuleRequest": {
2278
2337
  "document": "CreateForwardRule请求参数结构体",
2279
2338
  "members": [
@@ -2502,6 +2561,116 @@
2502
2561
  ],
2503
2562
  "type": "object"
2504
2563
  },
2564
+ "CreateFreeCloudStorageRequest": {
2565
+ "document": "CreateFreeCloudStorage请求参数结构体",
2566
+ "members": [
2567
+ {
2568
+ "disabled": false,
2569
+ "document": "产品ID",
2570
+ "example": "H541SOP191",
2571
+ "member": "string",
2572
+ "name": "ProductId",
2573
+ "required": true,
2574
+ "type": "string"
2575
+ },
2576
+ {
2577
+ "disabled": false,
2578
+ "document": "设备名称",
2579
+ "example": "event_36502632_1",
2580
+ "member": "string",
2581
+ "name": "DeviceName",
2582
+ "required": true,
2583
+ "type": "string"
2584
+ },
2585
+ {
2586
+ "disabled": false,
2587
+ "document": "云存套餐ID:\nlye1w3d:低功耗事件3天周套餐。\nye1w3d:事件3天周套餐",
2588
+ "example": "lye1w3d",
2589
+ "member": "string",
2590
+ "name": "PackageId",
2591
+ "required": true,
2592
+ "type": "string"
2593
+ },
2594
+ {
2595
+ "disabled": false,
2596
+ "document": "如果当前设备已开启云存套餐,Override=1会使用新套餐覆盖原有套餐。不传此参数则默认为0。",
2597
+ "example": "0",
2598
+ "member": "uint64",
2599
+ "name": "Override",
2600
+ "required": false,
2601
+ "type": "int"
2602
+ },
2603
+ {
2604
+ "disabled": false,
2605
+ "document": "套餐列表顺序:PackageQueue=front会立即使用新购买的套餐,新购套餐结束后,列表中下一个未过期的套餐继续生效;PackageQueue=end会等设备当前所有已购买套餐过期后才会生效新购套餐。与Override参数不能同时使用。",
2606
+ "example": "front",
2607
+ "member": "string",
2608
+ "name": "PackageQueue",
2609
+ "required": false,
2610
+ "type": "string"
2611
+ },
2612
+ {
2613
+ "disabled": false,
2614
+ "document": "订单id",
2615
+ "example": "slfie21321",
2616
+ "member": "string",
2617
+ "name": "OrderId",
2618
+ "required": false,
2619
+ "type": "string"
2620
+ },
2621
+ {
2622
+ "disabled": false,
2623
+ "document": "通道ID",
2624
+ "example": "1",
2625
+ "member": "uint64",
2626
+ "name": "ChannelId",
2627
+ "required": false,
2628
+ "type": "int"
2629
+ },
2630
+ {
2631
+ "disabled": false,
2632
+ "document": "云存视频存储区域,国内默认为ap-guangzhou。海外默认为东南亚ap-singapore,可选美东na-ashburn、欧洲eu-frankfurt。",
2633
+ "example": "ap-guangzhou",
2634
+ "member": "string",
2635
+ "name": "StorageRegion",
2636
+ "required": false,
2637
+ "type": "string"
2638
+ }
2639
+ ],
2640
+ "type": "object"
2641
+ },
2642
+ "CreateFreeCloudStorageResponse": {
2643
+ "document": "CreateFreeCloudStorage返回参数结构体",
2644
+ "members": [
2645
+ {
2646
+ "disabled": false,
2647
+ "document": "订单金额,单位为分\n注意:此字段可能返回 null,表示取不到有效值。",
2648
+ "example": "100",
2649
+ "member": "uint64",
2650
+ "name": "Price",
2651
+ "output_required": false,
2652
+ "type": "int",
2653
+ "value_allowed_null": true
2654
+ },
2655
+ {
2656
+ "disabled": false,
2657
+ "document": "支付金额,单位为分\n注意:此字段可能返回 null,表示取不到有效值。",
2658
+ "example": "100",
2659
+ "member": "uint64",
2660
+ "name": "Amount",
2661
+ "output_required": false,
2662
+ "type": "int",
2663
+ "value_allowed_null": true
2664
+ },
2665
+ {
2666
+ "document": "唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。",
2667
+ "member": "string",
2668
+ "name": "RequestId",
2669
+ "type": "string"
2670
+ }
2671
+ ],
2672
+ "type": "object"
2673
+ },
2505
2674
  "CreateProductRequest": {
2506
2675
  "document": "CreateProduct请求参数结构体",
2507
2676
  "members": [
@@ -120,6 +120,14 @@
120
120
  "title": "创建数据转发"
121
121
  }
122
122
  ],
123
+ "CreateDeviceChannel": [
124
+ {
125
+ "document": "",
126
+ "input": "POST / HTTP/1.1\nHost: iotvideo.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: CreateCloudStorage\n<公共请求参数>\n\n{\n \"ProductId\": \"H541SOP191\",\n \"DeviceName\": \"event_36502632_1\",\n \"ChannelId\": 1\n}",
127
+ "output": "{\n \"Response\": {\n \"RequestId\": \"a9a9d232-01c0-494a-baa3-57c384463c3f\"\n }\n}",
128
+ "title": "创建设备通道示例"
129
+ }
130
+ ],
123
131
  "CreateForwardRule": [
124
132
  {
125
133
  "document": "创建转发规则",
@@ -128,6 +136,14 @@
128
136
  "title": "创建转发规则"
129
137
  }
130
138
  ],
139
+ "CreateFreeCloudStorage": [
140
+ {
141
+ "document": "",
142
+ "input": "POST / HTTP/1.1\nHost: iotvideo.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: CreateCloudStorage\n<公共请求参数>\n\n{\n \"ProductId\": \"H541SOP191\",\n \"DeviceName\": \"event_36502632_1\",\n \"PackageId\": \"yc1m3d\"\n}",
143
+ "output": "{\n \"Response\": {\n \"Amount\": 0,\n \"Price\": 0,\n \"RequestId\": \"a9a9d232-01c0-494a-baa3-57c384463c3f\"\n }\n}",
144
+ "title": "开通免费实例"
145
+ }
146
+ ],
131
147
  "CreateProduct": [
132
148
  {
133
149
  "document": "",
@@ -1468,7 +1468,7 @@
1468
1468
  {
1469
1469
  "disabled": false,
1470
1470
  "document": "满足过滤条件的自定义人物数量",
1471
- "example": "123",
1471
+ "example": "798",
1472
1472
  "member": "int64",
1473
1473
  "name": "TotalCount",
1474
1474
  "output_required": true,