tccli 3.0.1288.1__py2.py3-none-any.whl → 3.0.1289.1__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.
- tccli/__init__.py +1 -1
- tccli/plugins/sso/__init__.py +11 -1
- tccli/plugins/sso/login.py +3 -3
- tccli/services/asr/v20190614/api.json +6 -6
- tccli/services/asr/v20190614/examples.json +4 -4
- tccli/services/bi/v20220105/api.json +43 -0
- tccli/services/billing/v20180709/api.json +310 -250
- tccli/services/cdwpg/v20201230/api.json +5 -5
- tccli/services/cdwpg/v20201230/examples.json +6 -6
- tccli/services/cdz/v20221123/api.json +4 -4
- tccli/services/cfg/v20210820/api.json +197 -197
- tccli/services/cfg/v20210820/examples.json +1 -1
- tccli/services/clb/v20180317/api.json +2 -2
- tccli/services/cwp/v20180228/api.json +39 -9
- tccli/services/dbbrain/dbbrain_client.py +383 -12
- tccli/services/dbbrain/v20210527/api.json +884 -101
- tccli/services/dbbrain/v20210527/examples.json +56 -0
- tccli/services/domain/v20180808/api.json +3 -3
- tccli/services/dts/v20180330/api.json +34 -34
- tccli/services/dts/v20180330/examples.json +1 -1
- tccli/services/dts/v20211206/api.json +225 -223
- tccli/services/dts/v20211206/examples.json +2 -2
- tccli/services/ess/v20201111/api.json +30 -3
- tccli/services/essbasic/v20210526/api.json +29 -2
- tccli/services/iotexplorer/iotexplorer_client.py +159 -0
- tccli/services/iotexplorer/v20190423/api.json +561 -0
- tccli/services/iotexplorer/v20190423/examples.json +24 -0
- tccli/services/iotvideo/iotvideo_client.py +106 -0
- tccli/services/iotvideo/v20211125/api.json +105 -0
- tccli/services/iotvideo/v20211125/examples.json +16 -0
- tccli/services/lighthouse/v20200324/api.json +46 -46
- tccli/services/lighthouse/v20200324/examples.json +2 -2
- tccli/services/lke/v20231130/api.json +2 -2
- tccli/services/lkeap/v20240522/api.json +2 -2
- tccli/services/mps/v20190612/api.json +88 -6
- tccli/services/mqtt/v20240516/api.json +3 -3
- tccli/services/mqtt/v20240516/examples.json +5 -11
- tccli/services/organization/v20210331/api.json +113 -113
- tccli/services/svp/v20240125/api.json +1 -1
- tccli/services/tcb/v20180608/api.json +4 -4
- tccli/services/teo/v20220901/api.json +541 -5
- tccli/services/teo/v20220901/examples.json +21 -3
- tccli/services/tione/v20211111/api.json +64 -6
- tccli/services/vdb/v20230616/api.json +31 -2
- tccli/services/vdb/v20230616/examples.json +8 -2
- tccli/services/vrs/v20200824/api.json +14 -2
- tccli/services/vrs/v20200824/examples.json +1 -1
- tccli/services/wedata/v20210820/api.json +48 -0
- {tccli-3.0.1288.1.dist-info → tccli-3.0.1289.1.dist-info}/METADATA +2 -2
- {tccli-3.0.1288.1.dist-info → tccli-3.0.1289.1.dist-info}/RECORD +53 -53
- {tccli-3.0.1288.1.dist-info → tccli-3.0.1289.1.dist-info}/WHEEL +0 -0
- {tccli-3.0.1288.1.dist-info → tccli-3.0.1289.1.dist-info}/entry_points.txt +0 -0
- {tccli-3.0.1288.1.dist-info → tccli-3.0.1289.1.dist-info}/license_files/LICENSE +0 -0
@@ -2309,6 +2309,58 @@ def doModifyDeviceLogLevel(args, parsed_globals):
|
|
2309
2309
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
2310
2310
|
|
2311
2311
|
|
2312
|
+
def doDescribeP2PRoute(args, parsed_globals):
|
2313
|
+
g_param = parse_global_arg(parsed_globals)
|
2314
|
+
|
2315
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
2316
|
+
cred = credential.CVMRoleCredential()
|
2317
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2318
|
+
cred = credential.STSAssumeRoleCredential(
|
2319
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2320
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2321
|
+
)
|
2322
|
+
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):
|
2323
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
2324
|
+
else:
|
2325
|
+
cred = credential.Credential(
|
2326
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
2327
|
+
)
|
2328
|
+
http_profile = HttpProfile(
|
2329
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
2330
|
+
reqMethod="POST",
|
2331
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
2332
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
2333
|
+
)
|
2334
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
2335
|
+
if g_param[OptionsDefine.Language]:
|
2336
|
+
profile.language = g_param[OptionsDefine.Language]
|
2337
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
2338
|
+
client = mod.IotvideoClient(cred, g_param[OptionsDefine.Region], profile)
|
2339
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
2340
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
2341
|
+
model = models.DescribeP2PRouteRequest()
|
2342
|
+
model.from_json_string(json.dumps(args))
|
2343
|
+
start_time = time.time()
|
2344
|
+
while True:
|
2345
|
+
rsp = client.DescribeP2PRoute(model)
|
2346
|
+
result = rsp.to_json_string()
|
2347
|
+
try:
|
2348
|
+
json_obj = json.loads(result)
|
2349
|
+
except TypeError as e:
|
2350
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
2351
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
2352
|
+
break
|
2353
|
+
cur_time = time.time()
|
2354
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
2355
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
2356
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
2357
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
2358
|
+
else:
|
2359
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
2360
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
2361
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
2362
|
+
|
2363
|
+
|
2312
2364
|
def doDescribeFirmware(args, parsed_globals):
|
2313
2365
|
g_param = parse_global_arg(parsed_globals)
|
2314
2366
|
|
@@ -2985,6 +3037,58 @@ def doDeleteIotDataType(args, parsed_globals):
|
|
2985
3037
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
2986
3038
|
|
2987
3039
|
|
3040
|
+
def doChangeP2PRoute(args, parsed_globals):
|
3041
|
+
g_param = parse_global_arg(parsed_globals)
|
3042
|
+
|
3043
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
3044
|
+
cred = credential.CVMRoleCredential()
|
3045
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3046
|
+
cred = credential.STSAssumeRoleCredential(
|
3047
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3048
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3049
|
+
)
|
3050
|
+
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):
|
3051
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
3052
|
+
else:
|
3053
|
+
cred = credential.Credential(
|
3054
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
3055
|
+
)
|
3056
|
+
http_profile = HttpProfile(
|
3057
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
3058
|
+
reqMethod="POST",
|
3059
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
3060
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
3061
|
+
)
|
3062
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
3063
|
+
if g_param[OptionsDefine.Language]:
|
3064
|
+
profile.language = g_param[OptionsDefine.Language]
|
3065
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
3066
|
+
client = mod.IotvideoClient(cred, g_param[OptionsDefine.Region], profile)
|
3067
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
3068
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
3069
|
+
model = models.ChangeP2PRouteRequest()
|
3070
|
+
model.from_json_string(json.dumps(args))
|
3071
|
+
start_time = time.time()
|
3072
|
+
while True:
|
3073
|
+
rsp = client.ChangeP2PRoute(model)
|
3074
|
+
result = rsp.to_json_string()
|
3075
|
+
try:
|
3076
|
+
json_obj = json.loads(result)
|
3077
|
+
except TypeError as e:
|
3078
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
3079
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
3080
|
+
break
|
3081
|
+
cur_time = time.time()
|
3082
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
3083
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
3084
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
3085
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
3086
|
+
else:
|
3087
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
3088
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
3089
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
3090
|
+
|
3091
|
+
|
2988
3092
|
def doDisableOtaVersion(args, parsed_globals):
|
2989
3093
|
g_param = parse_global_arg(parsed_globals)
|
2990
3094
|
|
@@ -8608,6 +8712,7 @@ ACTION_MAP = {
|
|
8608
8712
|
"ControlDeviceData": doControlDeviceData,
|
8609
8713
|
"UpgradeDevice": doUpgradeDevice,
|
8610
8714
|
"ModifyDeviceLogLevel": doModifyDeviceLogLevel,
|
8715
|
+
"DescribeP2PRoute": doDescribeP2PRoute,
|
8611
8716
|
"DescribeFirmware": doDescribeFirmware,
|
8612
8717
|
"DescribeCloudStorageDate": doDescribeCloudStorageDate,
|
8613
8718
|
"DescribeFreeCloudStorageNum": doDescribeFreeCloudStorageNum,
|
@@ -8621,6 +8726,7 @@ ACTION_MAP = {
|
|
8621
8726
|
"CreateProduct": doCreateProduct,
|
8622
8727
|
"SetMessageQueue": doSetMessageQueue,
|
8623
8728
|
"DeleteIotDataType": doDeleteIotDataType,
|
8729
|
+
"ChangeP2PRoute": doChangeP2PRoute,
|
8624
8730
|
"DisableOtaVersion": doDisableOtaVersion,
|
8625
8731
|
"InheritCloudStorageUser": doInheritCloudStorageUser,
|
8626
8732
|
"GetFirmwareURL": doGetFirmwareURL,
|
@@ -56,6 +56,13 @@
|
|
56
56
|
"output": "CancelDeviceFirmwareTaskResponse",
|
57
57
|
"status": "online"
|
58
58
|
},
|
59
|
+
"ChangeP2PRoute": {
|
60
|
+
"document": "p2p路线切换",
|
61
|
+
"input": "ChangeP2PRouteRequest",
|
62
|
+
"name": "p2p线路切换",
|
63
|
+
"output": "ChangeP2PRouteResponse",
|
64
|
+
"status": "online"
|
65
|
+
},
|
59
66
|
"CheckForwardAuth": {
|
60
67
|
"document": "判断是否开启转发的权限",
|
61
68
|
"input": "CheckForwardAuthRequest",
|
@@ -490,6 +497,13 @@
|
|
490
497
|
"output": "DescribeP2PInfoResponse",
|
491
498
|
"status": "online"
|
492
499
|
},
|
500
|
+
"DescribeP2PRoute": {
|
501
|
+
"document": "当前p2p线路",
|
502
|
+
"input": "DescribeP2PRouteRequest",
|
503
|
+
"name": "查询当前P2P线路",
|
504
|
+
"output": "DescribeP2PRouteResponse",
|
505
|
+
"status": "online"
|
506
|
+
},
|
493
507
|
"DescribePackageConsumeTask": {
|
494
508
|
"document": "查询套餐消耗记录详情",
|
495
509
|
"input": "DescribePackageConsumeTaskRequest",
|
@@ -1632,6 +1646,51 @@
|
|
1632
1646
|
],
|
1633
1647
|
"type": "object"
|
1634
1648
|
},
|
1649
|
+
"ChangeP2PRouteRequest": {
|
1650
|
+
"document": "ChangeP2PRoute请求参数结构体",
|
1651
|
+
"members": [
|
1652
|
+
{
|
1653
|
+
"disabled": false,
|
1654
|
+
"document": "产品ID",
|
1655
|
+
"example": "H541SOP191",
|
1656
|
+
"member": "string",
|
1657
|
+
"name": "ProductId",
|
1658
|
+
"required": true,
|
1659
|
+
"type": "string"
|
1660
|
+
},
|
1661
|
+
{
|
1662
|
+
"disabled": false,
|
1663
|
+
"document": "设备名称",
|
1664
|
+
"example": "event_36502632_1",
|
1665
|
+
"member": "string",
|
1666
|
+
"name": "DeviceName",
|
1667
|
+
"required": true,
|
1668
|
+
"type": "string"
|
1669
|
+
},
|
1670
|
+
{
|
1671
|
+
"disabled": false,
|
1672
|
+
"document": "P2P线路",
|
1673
|
+
"example": "1",
|
1674
|
+
"member": "uint64",
|
1675
|
+
"name": "RouteId",
|
1676
|
+
"required": true,
|
1677
|
+
"type": "int"
|
1678
|
+
}
|
1679
|
+
],
|
1680
|
+
"type": "object"
|
1681
|
+
},
|
1682
|
+
"ChangeP2PRouteResponse": {
|
1683
|
+
"document": "ChangeP2PRoute返回参数结构体",
|
1684
|
+
"members": [
|
1685
|
+
{
|
1686
|
+
"document": "唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。",
|
1687
|
+
"member": "string",
|
1688
|
+
"name": "RequestId",
|
1689
|
+
"type": "string"
|
1690
|
+
}
|
1691
|
+
],
|
1692
|
+
"type": "object"
|
1693
|
+
},
|
1635
1694
|
"CheckForwardAuthRequest": {
|
1636
1695
|
"document": "CheckForwardAuth请求参数结构体",
|
1637
1696
|
"members": [
|
@@ -6722,6 +6781,52 @@
|
|
6722
6781
|
],
|
6723
6782
|
"type": "object"
|
6724
6783
|
},
|
6784
|
+
"DescribeP2PRouteRequest": {
|
6785
|
+
"document": "DescribeP2PRoute请求参数结构体",
|
6786
|
+
"members": [
|
6787
|
+
{
|
6788
|
+
"disabled": false,
|
6789
|
+
"document": "产品ID",
|
6790
|
+
"example": "H541SOP191",
|
6791
|
+
"member": "string",
|
6792
|
+
"name": "ProductId",
|
6793
|
+
"required": true,
|
6794
|
+
"type": "string"
|
6795
|
+
},
|
6796
|
+
{
|
6797
|
+
"disabled": false,
|
6798
|
+
"document": "设备名称",
|
6799
|
+
"example": "event_36502632_1",
|
6800
|
+
"member": "string",
|
6801
|
+
"name": "DeviceName",
|
6802
|
+
"required": true,
|
6803
|
+
"type": "string"
|
6804
|
+
}
|
6805
|
+
],
|
6806
|
+
"type": "object"
|
6807
|
+
},
|
6808
|
+
"DescribeP2PRouteResponse": {
|
6809
|
+
"document": "DescribeP2PRoute返回参数结构体",
|
6810
|
+
"members": [
|
6811
|
+
{
|
6812
|
+
"disabled": false,
|
6813
|
+
"document": "当前p2p线路",
|
6814
|
+
"example": "1",
|
6815
|
+
"member": "uint64",
|
6816
|
+
"name": "RouteId",
|
6817
|
+
"output_required": true,
|
6818
|
+
"type": "int",
|
6819
|
+
"value_allowed_null": false
|
6820
|
+
},
|
6821
|
+
{
|
6822
|
+
"document": "唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。",
|
6823
|
+
"member": "string",
|
6824
|
+
"name": "RequestId",
|
6825
|
+
"type": "string"
|
6826
|
+
}
|
6827
|
+
],
|
6828
|
+
"type": "object"
|
6829
|
+
},
|
6725
6830
|
"DescribePackageConsumeTaskRequest": {
|
6726
6831
|
"document": "DescribePackageConsumeTask请求参数结构体",
|
6727
6832
|
"members": [
|
@@ -64,6 +64,14 @@
|
|
64
64
|
"title": "取消设备升级任务"
|
65
65
|
}
|
66
66
|
],
|
67
|
+
"ChangeP2PRoute": [
|
68
|
+
{
|
69
|
+
"document": "切换p2p线路",
|
70
|
+
"input": "POST / HTTP/1.1\nHost: iotvideo.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: ChangeP2PRoute\n<公共请求参数>\n\n{\n \"ProductId\": \"dddd\",\n \"DeviceName\": \"ddd\",\n \"RouteId\": 1\n}",
|
71
|
+
"output": "{\n \"Response\": {\n \"RequestId\": \"4ca95e7d-5075-4cd7-9dcb-c1c058557ac6\"\n }\n}",
|
72
|
+
"title": "切换p2p线路"
|
73
|
+
}
|
74
|
+
],
|
67
75
|
"CheckForwardAuth": [
|
68
76
|
{
|
69
77
|
"document": "通用场景",
|
@@ -560,6 +568,14 @@
|
|
560
568
|
"title": "拉取设备p2p信息"
|
561
569
|
}
|
562
570
|
],
|
571
|
+
"DescribeP2PRoute": [
|
572
|
+
{
|
573
|
+
"document": "查询当前p2p示例",
|
574
|
+
"input": "POST / HTTP/1.1\nHost: iotvideo.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: DescribeP2PRoute\n<公共请求参数>\n\n{\n \"ProductId\": \"sdfdsf\",\n \"DeviceName\": \"dsfddd\"\n}",
|
575
|
+
"output": "{\n \"Response\": {\n \"RequestId\": \"1b2b3a4d-2ab6-478b-b880-721b5dd8928b\",\n \"RouteId\": 1\n }\n}",
|
576
|
+
"title": "查询当前p2p示例"
|
577
|
+
}
|
578
|
+
],
|
563
579
|
"DescribePackageConsumeTask": [
|
564
580
|
{
|
565
581
|
"document": "",
|