tccli-intl-en 3.0.1273.1__py2.py3-none-any.whl → 3.0.1275.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 CHANGED
@@ -1 +1 @@
1
- __version__ = '3.0.1273.1'
1
+ __version__ = '3.0.1275.1'
@@ -745,6 +745,58 @@ def doCreateStreamPackageHarvestJob(args, parsed_globals):
745
745
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
746
746
 
747
747
 
748
+ def doBindSSAICDNDomainWithChannel(args, parsed_globals):
749
+ g_param = parse_global_arg(parsed_globals)
750
+
751
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
752
+ cred = credential.CVMRoleCredential()
753
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
754
+ cred = credential.STSAssumeRoleCredential(
755
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
756
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
757
+ )
758
+ 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):
759
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
760
+ else:
761
+ cred = credential.Credential(
762
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
763
+ )
764
+ http_profile = HttpProfile(
765
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
766
+ reqMethod="POST",
767
+ endpoint=g_param[OptionsDefine.Endpoint],
768
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
769
+ )
770
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
771
+ if g_param[OptionsDefine.Language]:
772
+ profile.language = g_param[OptionsDefine.Language]
773
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
774
+ client = mod.MdpClient(cred, g_param[OptionsDefine.Region], profile)
775
+ client._sdkVersion += ("_CLI_" + __version__)
776
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
777
+ model = models.BindSSAICDNDomainWithChannelRequest()
778
+ model.from_json_string(json.dumps(args))
779
+ start_time = time.time()
780
+ while True:
781
+ rsp = client.BindSSAICDNDomainWithChannel(model)
782
+ result = rsp.to_json_string()
783
+ try:
784
+ json_obj = json.loads(result)
785
+ except TypeError as e:
786
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
787
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
788
+ break
789
+ cur_time = time.time()
790
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
791
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
792
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
793
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
794
+ else:
795
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
796
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
797
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
798
+
799
+
748
800
  def doDescribeLinearAssemblyCDNDomainWithChannel(args, parsed_globals):
749
801
  g_param = parse_global_arg(parsed_globals)
750
802
 
@@ -2045,6 +2097,58 @@ def doCreateStreamPackageLinearAssemblyProgram(args, parsed_globals):
2045
2097
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
2046
2098
 
2047
2099
 
2100
+ def doDescribeStreamPackageLinearAssemblyChannels(args, parsed_globals):
2101
+ g_param = parse_global_arg(parsed_globals)
2102
+
2103
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
2104
+ cred = credential.CVMRoleCredential()
2105
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
2106
+ cred = credential.STSAssumeRoleCredential(
2107
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
2108
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
2109
+ )
2110
+ 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):
2111
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
2112
+ else:
2113
+ cred = credential.Credential(
2114
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
2115
+ )
2116
+ http_profile = HttpProfile(
2117
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
2118
+ reqMethod="POST",
2119
+ endpoint=g_param[OptionsDefine.Endpoint],
2120
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
2121
+ )
2122
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
2123
+ if g_param[OptionsDefine.Language]:
2124
+ profile.language = g_param[OptionsDefine.Language]
2125
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
2126
+ client = mod.MdpClient(cred, g_param[OptionsDefine.Region], profile)
2127
+ client._sdkVersion += ("_CLI_" + __version__)
2128
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
2129
+ model = models.DescribeStreamPackageLinearAssemblyChannelsRequest()
2130
+ model.from_json_string(json.dumps(args))
2131
+ start_time = time.time()
2132
+ while True:
2133
+ rsp = client.DescribeStreamPackageLinearAssemblyChannels(model)
2134
+ result = rsp.to_json_string()
2135
+ try:
2136
+ json_obj = json.loads(result)
2137
+ except TypeError as e:
2138
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
2139
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
2140
+ break
2141
+ cur_time = time.time()
2142
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
2143
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
2144
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
2145
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
2146
+ else:
2147
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
2148
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
2149
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
2150
+
2151
+
2048
2152
  def doDeleteStreamPackageLinearAssemblyPrograms(args, parsed_globals):
2049
2153
  g_param = parse_global_arg(parsed_globals)
2050
2154
 
@@ -2617,7 +2721,7 @@ def doDescribeStreamPackageChannel(args, parsed_globals):
2617
2721
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
2618
2722
 
2619
2723
 
2620
- def doDescribeStreamPackageLinearAssemblyChannels(args, parsed_globals):
2724
+ def doUnbindSSAICDNDomainWithChannel(args, parsed_globals):
2621
2725
  g_param = parse_global_arg(parsed_globals)
2622
2726
 
2623
2727
  if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
@@ -2646,11 +2750,11 @@ def doDescribeStreamPackageLinearAssemblyChannels(args, parsed_globals):
2646
2750
  client = mod.MdpClient(cred, g_param[OptionsDefine.Region], profile)
2647
2751
  client._sdkVersion += ("_CLI_" + __version__)
2648
2752
  models = MODELS_MAP[g_param[OptionsDefine.Version]]
2649
- model = models.DescribeStreamPackageLinearAssemblyChannelsRequest()
2753
+ model = models.UnbindSSAICDNDomainWithChannelRequest()
2650
2754
  model.from_json_string(json.dumps(args))
2651
2755
  start_time = time.time()
2652
2756
  while True:
2653
- rsp = client.DescribeStreamPackageLinearAssemblyChannels(model)
2757
+ rsp = client.UnbindSSAICDNDomainWithChannel(model)
2654
2758
  result = rsp.to_json_string()
2655
2759
  try:
2656
2760
  json_obj = json.loads(result)
@@ -3162,6 +3266,7 @@ ACTION_MAP = {
3162
3266
  "ModifyStreamPackageLinearAssemblyProgram": doModifyStreamPackageLinearAssemblyProgram,
3163
3267
  "ModifyStreamPackageSource": doModifyStreamPackageSource,
3164
3268
  "CreateStreamPackageHarvestJob": doCreateStreamPackageHarvestJob,
3269
+ "BindSSAICDNDomainWithChannel": doBindSSAICDNDomainWithChannel,
3165
3270
  "DescribeLinearAssemblyCDNDomainWithChannel": doDescribeLinearAssemblyCDNDomainWithChannel,
3166
3271
  "ModifyStreamPackageChannelEndpoint": doModifyStreamPackageChannelEndpoint,
3167
3272
  "DescribeStreamPackageSSAIUsage": doDescribeStreamPackageSSAIUsage,
@@ -3187,6 +3292,7 @@ ACTION_MAP = {
3187
3292
  "DeleteStreamPackageSource": doDeleteStreamPackageSource,
3188
3293
  "ModifyStreamPackageLinearAssemblyChannel": doModifyStreamPackageLinearAssemblyChannel,
3189
3294
  "CreateStreamPackageLinearAssemblyProgram": doCreateStreamPackageLinearAssemblyProgram,
3295
+ "DescribeStreamPackageLinearAssemblyChannels": doDescribeStreamPackageLinearAssemblyChannels,
3190
3296
  "DeleteStreamPackageLinearAssemblyPrograms": doDeleteStreamPackageLinearAssemblyPrograms,
3191
3297
  "DescribeStreamPackageLinearAssemblyProgramSchedules": doDescribeStreamPackageLinearAssemblyProgramSchedules,
3192
3298
  "DeleteStreamPackageSourceLocation": doDeleteStreamPackageSourceLocation,
@@ -3198,7 +3304,7 @@ ACTION_MAP = {
3198
3304
  "DescribeStreamPackageSourceLocation": doDescribeStreamPackageSourceLocation,
3199
3305
  "DeleteStreamPackageLinearAssemblyChannels": doDeleteStreamPackageLinearAssemblyChannels,
3200
3306
  "DescribeStreamPackageChannel": doDescribeStreamPackageChannel,
3201
- "DescribeStreamPackageLinearAssemblyChannels": doDescribeStreamPackageLinearAssemblyChannels,
3307
+ "UnbindSSAICDNDomainWithChannel": doUnbindSSAICDNDomainWithChannel,
3202
3308
  "DeleteStreamPackageVodRemuxTasks": doDeleteStreamPackageVodRemuxTasks,
3203
3309
  "CreateStreamPackageChannel": doCreateStreamPackageChannel,
3204
3310
  "DescribeStreamPackageSourceLocationAlerts": doDescribeStreamPackageSourceLocationAlerts,
@@ -14,6 +14,13 @@
14
14
  "output": "BindNewLVBDomainWithChannelResponse",
15
15
  "status": "online"
16
16
  },
17
+ "BindSSAICDNDomainWithChannel": {
18
+ "document": "BindSSAICDNDomainWithChannel",
19
+ "input": "BindSSAICDNDomainWithChannelRequest",
20
+ "name": "BindSSAICDNDomainWithChannel",
21
+ "output": "BindSSAICDNDomainWithChannelResponse",
22
+ "status": "online"
23
+ },
17
24
  "CreateStreamPackageChannel": {
18
25
  "document": "This API is used to create a StreamPackage channel.",
19
26
  "input": "CreateStreamPackageChannelRequest",
@@ -419,6 +426,13 @@
419
426
  "name": "UnbindLinearAssemblyCDNDomainWithChannel",
420
427
  "output": "UnbindLinearAssemblyCDNDomainWithChannelResponse",
421
428
  "status": "online"
429
+ },
430
+ "UnbindSSAICDNDomainWithChannel": {
431
+ "document": "UnbindSSAICDNDomainWithChannel",
432
+ "input": "UnbindSSAICDNDomainWithChannelRequest",
433
+ "name": "UnbindSSAICDNDomainWithChannel",
434
+ "output": "UnbindSSAICDNDomainWithChannelResponse",
435
+ "status": "online"
422
436
  }
423
437
  },
424
438
  "metadata": {
@@ -629,6 +643,42 @@
629
643
  ],
630
644
  "type": "object"
631
645
  },
646
+ "BindSSAICDNDomainWithChannelRequest": {
647
+ "document": "BindSSAICDNDomainWithChannel request structure.",
648
+ "members": [
649
+ {
650
+ "disabled": false,
651
+ "document": "Channel Id",
652
+ "example": "ChannelId",
653
+ "member": "string",
654
+ "name": "ChannelId",
655
+ "required": true,
656
+ "type": "string"
657
+ },
658
+ {
659
+ "disabled": false,
660
+ "document": "The domain name for CDN playback.",
661
+ "example": "CdnDomain",
662
+ "member": "string",
663
+ "name": "CdnDomain",
664
+ "required": true,
665
+ "type": "string"
666
+ }
667
+ ],
668
+ "type": "object"
669
+ },
670
+ "BindSSAICDNDomainWithChannelResponse": {
671
+ "document": "BindSSAICDNDomainWithChannel response structure.",
672
+ "members": [
673
+ {
674
+ "document": "The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.",
675
+ "member": "string",
676
+ "name": "RequestId",
677
+ "type": "string"
678
+ }
679
+ ],
680
+ "type": "object"
681
+ },
632
682
  "CacheInfo": {
633
683
  "document": "Cache configuration",
634
684
  "members": [
@@ -6613,6 +6663,42 @@
6613
6663
  ],
6614
6664
  "type": "object"
6615
6665
  },
6666
+ "UnbindSSAICDNDomainWithChannelRequest": {
6667
+ "document": "UnbindSSAICDNDomainWithChannel request structure.",
6668
+ "members": [
6669
+ {
6670
+ "disabled": false,
6671
+ "document": "Channel Id",
6672
+ "example": "ChannelId",
6673
+ "member": "string",
6674
+ "name": "ChannelId",
6675
+ "required": true,
6676
+ "type": "string"
6677
+ },
6678
+ {
6679
+ "disabled": false,
6680
+ "document": "The domain name for CDN playback.",
6681
+ "example": "CdnDomain",
6682
+ "member": "string",
6683
+ "name": "CdnDomain",
6684
+ "required": true,
6685
+ "type": "string"
6686
+ }
6687
+ ],
6688
+ "type": "object"
6689
+ },
6690
+ "UnbindSSAICDNDomainWithChannelResponse": {
6691
+ "document": "UnbindSSAICDNDomainWithChannel response structure.",
6692
+ "members": [
6693
+ {
6694
+ "document": "The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.",
6695
+ "member": "string",
6696
+ "name": "RequestId",
6697
+ "type": "string"
6698
+ }
6699
+ ],
6700
+ "type": "object"
6701
+ },
6616
6702
  "UsageDetail": {
6617
6703
  "document": "Ad insertion configuration and SSAI usage detail by advertisement type dimension.",
6618
6704
  "members": [
@@ -16,6 +16,14 @@
16
16
  "title": "Sample request"
17
17
  }
18
18
  ],
19
+ "BindSSAICDNDomainWithChannel": [
20
+ {
21
+ "document": "SSAI Channel binding CDN playback domain name.",
22
+ "input": "POST / HTTP/1.1\nHost: mdp.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: BindSSAICDNDomainWithChannel\n<Public request parameters>\n\n{\n \"ChannelId\": \"68F6FB29000040E1DC40\",\n \"CdnDomain\": \"xxx\"\n}",
23
+ "output": "{\n \"Response\": {\n \"RequestId\": \"85bc94cc-9e55-4400-bf1b-f45dd12089\"\n }\n}",
24
+ "title": "Request Example"
25
+ }
26
+ ],
19
27
  "CreateStreamPackageChannel": [
20
28
  {
21
29
  "document": " ",
@@ -479,6 +487,14 @@
479
487
  "output": "{\n \"Response\": {\n \"RequestId\": \"XXXREQ\"\n }\n}",
480
488
  "title": "Sample request"
481
489
  }
490
+ ],
491
+ "UnbindSSAICDNDomainWithChannel": [
492
+ {
493
+ "document": "Cancel the association between the channel and CDN playback domain.",
494
+ "input": "POST / HTTP/1.1\nHost: mdp.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: UnbindSSAICDNDomainWithChannel\n<Public request parameters>\n\n{\n \"ChannelId\": \"68F6FB29000040E1DC40\",\n \"CdnDomain\": \"xxx\"\n}",
495
+ "output": "{\n \"Response\": {\n \"RequestId\": \"85bc94cc-9e55-4400-bf1b-f45dd1208990\"\n }\n}",
496
+ "title": "Request Example"
497
+ }
482
498
  ]
483
499
  },
484
500
  "version": "1.0"
@@ -69,6 +69,58 @@ def doTerminateDBInstances(args, parsed_globals):
69
69
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
70
70
 
71
71
 
72
+ def doDescribeDBInstanceNodeProperty(args, parsed_globals):
73
+ g_param = parse_global_arg(parsed_globals)
74
+
75
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
76
+ cred = credential.CVMRoleCredential()
77
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
78
+ cred = credential.STSAssumeRoleCredential(
79
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
80
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
81
+ )
82
+ 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):
83
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
84
+ else:
85
+ cred = credential.Credential(
86
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
87
+ )
88
+ http_profile = HttpProfile(
89
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
90
+ reqMethod="POST",
91
+ endpoint=g_param[OptionsDefine.Endpoint],
92
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
93
+ )
94
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
95
+ if g_param[OptionsDefine.Language]:
96
+ profile.language = g_param[OptionsDefine.Language]
97
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
98
+ client = mod.MongodbClient(cred, g_param[OptionsDefine.Region], profile)
99
+ client._sdkVersion += ("_CLI_" + __version__)
100
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
101
+ model = models.DescribeDBInstanceNodePropertyRequest()
102
+ model.from_json_string(json.dumps(args))
103
+ start_time = time.time()
104
+ while True:
105
+ rsp = client.DescribeDBInstanceNodeProperty(model)
106
+ result = rsp.to_json_string()
107
+ try:
108
+ json_obj = json.loads(result)
109
+ except TypeError as e:
110
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
111
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
112
+ break
113
+ cur_time = time.time()
114
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
115
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
116
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
117
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
118
+ else:
119
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
120
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
121
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
122
+
123
+
72
124
  def doDescribeDBInstanceDeal(args, parsed_globals):
73
125
  g_param = parse_global_arg(parsed_globals)
74
126
 
@@ -1693,6 +1745,7 @@ MODELS_MAP = {
1693
1745
 
1694
1746
  ACTION_MAP = {
1695
1747
  "TerminateDBInstances": doTerminateDBInstances,
1748
+ "DescribeDBInstanceNodeProperty": doDescribeDBInstanceNodeProperty,
1696
1749
  "DescribeDBInstanceDeal": doDescribeDBInstanceDeal,
1697
1750
  "DescribeDBInstanceNamespace": doDescribeDBInstanceNamespace,
1698
1751
  "DescribeClientConnections": doDescribeClientConnections,