tccli 3.0.1144.1__py2.py3-none-any.whl → 3.0.1145.1__py2.py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- tccli/__init__.py +1 -1
- tccli/services/asr/v20190614/api.json +2 -2
- tccli/services/cdb/cdb_client.py +167 -8
- tccli/services/cdb/v20170320/api.json +156 -0
- tccli/services/cdb/v20170320/examples.json +24 -0
- tccli/services/ckafka/v20190819/api.json +1 -1
- tccli/services/ckafka/v20190819/examples.json +2 -2
- tccli/services/dbdc/v20201029/api.json +14 -12
- tccli/services/dbdc/v20201029/examples.json +1 -1
- tccli/services/dlc/v20210125/api.json +52 -2
- tccli/services/es/es_client.py +61 -8
- tccli/services/es/v20180416/api.json +83 -2
- tccli/services/es/v20180416/examples.json +11 -3
- tccli/services/iotexplorer/v20190423/api.json +11 -0
- tccli/services/iotvideo/v20211125/api.json +11 -0
- tccli/services/mps/mps_client.py +228 -16
- tccli/services/mps/v20190612/api.json +474 -1
- tccli/services/mps/v20190612/examples.json +32 -0
- tccli/services/smpn/v20190822/api.json +10 -10
- tccli/services/trtc/v20190722/api.json +13 -4
- tccli/services/tsi/v20210325/api.json +2 -2
- tccli/services/tts/v20190823/api.json +1 -1
- {tccli-3.0.1144.1.dist-info → tccli-3.0.1145.1.dist-info}/METADATA +2 -2
- {tccli-3.0.1144.1.dist-info → tccli-3.0.1145.1.dist-info}/RECORD +27 -27
- {tccli-3.0.1144.1.dist-info → tccli-3.0.1145.1.dist-info}/WHEEL +0 -0
- {tccli-3.0.1144.1.dist-info → tccli-3.0.1145.1.dist-info}/entry_points.txt +0 -0
- {tccli-3.0.1144.1.dist-info → tccli-3.0.1145.1.dist-info}/license_files/LICENSE +0 -0
tccli/services/mps/mps_client.py
CHANGED
@@ -1941,6 +1941,58 @@ def doResetWorkflow(args, parsed_globals):
|
|
1941
1941
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1942
1942
|
|
1943
1943
|
|
1944
|
+
def doDeleteQualityControlTemplate(args, parsed_globals):
|
1945
|
+
g_param = parse_global_arg(parsed_globals)
|
1946
|
+
|
1947
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
1948
|
+
cred = credential.CVMRoleCredential()
|
1949
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1950
|
+
cred = credential.STSAssumeRoleCredential(
|
1951
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1952
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
1953
|
+
)
|
1954
|
+
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):
|
1955
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
1956
|
+
else:
|
1957
|
+
cred = credential.Credential(
|
1958
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
1959
|
+
)
|
1960
|
+
http_profile = HttpProfile(
|
1961
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
1962
|
+
reqMethod="POST",
|
1963
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
1964
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
1965
|
+
)
|
1966
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
1967
|
+
if g_param[OptionsDefine.Language]:
|
1968
|
+
profile.language = g_param[OptionsDefine.Language]
|
1969
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
1970
|
+
client = mod.MpsClient(cred, g_param[OptionsDefine.Region], profile)
|
1971
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
1972
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
1973
|
+
model = models.DeleteQualityControlTemplateRequest()
|
1974
|
+
model.from_json_string(json.dumps(args))
|
1975
|
+
start_time = time.time()
|
1976
|
+
while True:
|
1977
|
+
rsp = client.DeleteQualityControlTemplate(model)
|
1978
|
+
result = rsp.to_json_string()
|
1979
|
+
try:
|
1980
|
+
json_obj = json.loads(result)
|
1981
|
+
except TypeError as e:
|
1982
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
1983
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
1984
|
+
break
|
1985
|
+
cur_time = time.time()
|
1986
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
1987
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
1988
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
1989
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
1990
|
+
else:
|
1991
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
1992
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
1993
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1994
|
+
|
1995
|
+
|
1944
1996
|
def doDeleteWorkflow(args, parsed_globals):
|
1945
1997
|
g_param = parse_global_arg(parsed_globals)
|
1946
1998
|
|
@@ -1993,6 +2045,58 @@ def doDeleteWorkflow(args, parsed_globals):
|
|
1993
2045
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1994
2046
|
|
1995
2047
|
|
2048
|
+
def doCreateQualityControlTemplate(args, parsed_globals):
|
2049
|
+
g_param = parse_global_arg(parsed_globals)
|
2050
|
+
|
2051
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
2052
|
+
cred = credential.CVMRoleCredential()
|
2053
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2054
|
+
cred = credential.STSAssumeRoleCredential(
|
2055
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2056
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2057
|
+
)
|
2058
|
+
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):
|
2059
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
2060
|
+
else:
|
2061
|
+
cred = credential.Credential(
|
2062
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
2063
|
+
)
|
2064
|
+
http_profile = HttpProfile(
|
2065
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
2066
|
+
reqMethod="POST",
|
2067
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
2068
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
2069
|
+
)
|
2070
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
2071
|
+
if g_param[OptionsDefine.Language]:
|
2072
|
+
profile.language = g_param[OptionsDefine.Language]
|
2073
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
2074
|
+
client = mod.MpsClient(cred, g_param[OptionsDefine.Region], profile)
|
2075
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
2076
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
2077
|
+
model = models.CreateQualityControlTemplateRequest()
|
2078
|
+
model.from_json_string(json.dumps(args))
|
2079
|
+
start_time = time.time()
|
2080
|
+
while True:
|
2081
|
+
rsp = client.CreateQualityControlTemplate(model)
|
2082
|
+
result = rsp.to_json_string()
|
2083
|
+
try:
|
2084
|
+
json_obj = json.loads(result)
|
2085
|
+
except TypeError as e:
|
2086
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
2087
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
2088
|
+
break
|
2089
|
+
cur_time = time.time()
|
2090
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
2091
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
2092
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
2093
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
2094
|
+
else:
|
2095
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
2096
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
2097
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
2098
|
+
|
2099
|
+
|
1996
2100
|
def doModifyImageSpriteTemplate(args, parsed_globals):
|
1997
2101
|
g_param = parse_global_arg(parsed_globals)
|
1998
2102
|
|
@@ -2513,6 +2617,58 @@ def doCreateAIAnalysisTemplate(args, parsed_globals):
|
|
2513
2617
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
2514
2618
|
|
2515
2619
|
|
2620
|
+
def doModifyQualityControlTemplate(args, parsed_globals):
|
2621
|
+
g_param = parse_global_arg(parsed_globals)
|
2622
|
+
|
2623
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
2624
|
+
cred = credential.CVMRoleCredential()
|
2625
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2626
|
+
cred = credential.STSAssumeRoleCredential(
|
2627
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2628
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2629
|
+
)
|
2630
|
+
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):
|
2631
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
2632
|
+
else:
|
2633
|
+
cred = credential.Credential(
|
2634
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
2635
|
+
)
|
2636
|
+
http_profile = HttpProfile(
|
2637
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
2638
|
+
reqMethod="POST",
|
2639
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
2640
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
2641
|
+
)
|
2642
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
2643
|
+
if g_param[OptionsDefine.Language]:
|
2644
|
+
profile.language = g_param[OptionsDefine.Language]
|
2645
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
2646
|
+
client = mod.MpsClient(cred, g_param[OptionsDefine.Region], profile)
|
2647
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
2648
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
2649
|
+
model = models.ModifyQualityControlTemplateRequest()
|
2650
|
+
model.from_json_string(json.dumps(args))
|
2651
|
+
start_time = time.time()
|
2652
|
+
while True:
|
2653
|
+
rsp = client.ModifyQualityControlTemplate(model)
|
2654
|
+
result = rsp.to_json_string()
|
2655
|
+
try:
|
2656
|
+
json_obj = json.loads(result)
|
2657
|
+
except TypeError as e:
|
2658
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
2659
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
2660
|
+
break
|
2661
|
+
cur_time = time.time()
|
2662
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
2663
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
2664
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
2665
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
2666
|
+
else:
|
2667
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
2668
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
2669
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
2670
|
+
|
2671
|
+
|
2516
2672
|
def doStopStreamLinkFlow(args, parsed_globals):
|
2517
2673
|
g_param = parse_global_arg(parsed_globals)
|
2518
2674
|
|
@@ -2773,7 +2929,7 @@ def doModifyTranscodeTemplate(args, parsed_globals):
|
|
2773
2929
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
2774
2930
|
|
2775
2931
|
|
2776
|
-
def
|
2932
|
+
def doDescribeAIRecognitionTemplates(args, parsed_globals):
|
2777
2933
|
g_param = parse_global_arg(parsed_globals)
|
2778
2934
|
|
2779
2935
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -2802,11 +2958,11 @@ def doDescribeContentReviewTemplates(args, parsed_globals):
|
|
2802
2958
|
client = mod.MpsClient(cred, g_param[OptionsDefine.Region], profile)
|
2803
2959
|
client._sdkVersion += ("_CLI_" + __version__)
|
2804
2960
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
2805
|
-
model = models.
|
2961
|
+
model = models.DescribeAIRecognitionTemplatesRequest()
|
2806
2962
|
model.from_json_string(json.dumps(args))
|
2807
2963
|
start_time = time.time()
|
2808
2964
|
while True:
|
2809
|
-
rsp = client.
|
2965
|
+
rsp = client.DescribeAIRecognitionTemplates(model)
|
2810
2966
|
result = rsp.to_json_string()
|
2811
2967
|
try:
|
2812
2968
|
json_obj = json.loads(result)
|
@@ -3189,7 +3345,7 @@ def doDescribeStreamLinkActivateState(args, parsed_globals):
|
|
3189
3345
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
3190
3346
|
|
3191
3347
|
|
3192
|
-
def
|
3348
|
+
def doCreateWatermarkTemplate(args, parsed_globals):
|
3193
3349
|
g_param = parse_global_arg(parsed_globals)
|
3194
3350
|
|
3195
3351
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -3218,11 +3374,11 @@ def doCreateImageSpriteTemplate(args, parsed_globals):
|
|
3218
3374
|
client = mod.MpsClient(cred, g_param[OptionsDefine.Region], profile)
|
3219
3375
|
client._sdkVersion += ("_CLI_" + __version__)
|
3220
3376
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
3221
|
-
model = models.
|
3377
|
+
model = models.CreateWatermarkTemplateRequest()
|
3222
3378
|
model.from_json_string(json.dumps(args))
|
3223
3379
|
start_time = time.time()
|
3224
3380
|
while True:
|
3225
|
-
rsp = client.
|
3381
|
+
rsp = client.CreateWatermarkTemplate(model)
|
3226
3382
|
result = rsp.to_json_string()
|
3227
3383
|
try:
|
3228
3384
|
json_obj = json.loads(result)
|
@@ -3917,7 +4073,7 @@ def doDescribeWatermarkTemplates(args, parsed_globals):
|
|
3917
4073
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
3918
4074
|
|
3919
4075
|
|
3920
|
-
def
|
4076
|
+
def doCreateImageSpriteTemplate(args, parsed_globals):
|
3921
4077
|
g_param = parse_global_arg(parsed_globals)
|
3922
4078
|
|
3923
4079
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -3946,11 +4102,11 @@ def doCreateWatermarkTemplate(args, parsed_globals):
|
|
3946
4102
|
client = mod.MpsClient(cred, g_param[OptionsDefine.Region], profile)
|
3947
4103
|
client._sdkVersion += ("_CLI_" + __version__)
|
3948
4104
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
3949
|
-
model = models.
|
4105
|
+
model = models.CreateImageSpriteTemplateRequest()
|
3950
4106
|
model.from_json_string(json.dumps(args))
|
3951
4107
|
start_time = time.time()
|
3952
4108
|
while True:
|
3953
|
-
rsp = client.
|
4109
|
+
rsp = client.CreateImageSpriteTemplate(model)
|
3954
4110
|
result = rsp.to_json_string()
|
3955
4111
|
try:
|
3956
4112
|
json_obj = json.loads(result)
|
@@ -4021,7 +4177,7 @@ def doModifyStreamLinkOutputInfo(args, parsed_globals):
|
|
4021
4177
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
4022
4178
|
|
4023
4179
|
|
4024
|
-
def
|
4180
|
+
def doDescribeContentReviewTemplates(args, parsed_globals):
|
4025
4181
|
g_param = parse_global_arg(parsed_globals)
|
4026
4182
|
|
4027
4183
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -4050,11 +4206,11 @@ def doDescribeAIRecognitionTemplates(args, parsed_globals):
|
|
4050
4206
|
client = mod.MpsClient(cred, g_param[OptionsDefine.Region], profile)
|
4051
4207
|
client._sdkVersion += ("_CLI_" + __version__)
|
4052
4208
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
4053
|
-
model = models.
|
4209
|
+
model = models.DescribeContentReviewTemplatesRequest()
|
4054
4210
|
model.from_json_string(json.dumps(args))
|
4055
4211
|
start_time = time.time()
|
4056
4212
|
while True:
|
4057
|
-
rsp = client.
|
4213
|
+
rsp = client.DescribeContentReviewTemplates(model)
|
4058
4214
|
result = rsp.to_json_string()
|
4059
4215
|
try:
|
4060
4216
|
json_obj = json.loads(result)
|
@@ -4749,6 +4905,58 @@ def doCreatePersonSample(args, parsed_globals):
|
|
4749
4905
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
4750
4906
|
|
4751
4907
|
|
4908
|
+
def doDescribeQualityControlTemplates(args, parsed_globals):
|
4909
|
+
g_param = parse_global_arg(parsed_globals)
|
4910
|
+
|
4911
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
4912
|
+
cred = credential.CVMRoleCredential()
|
4913
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
4914
|
+
cred = credential.STSAssumeRoleCredential(
|
4915
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
4916
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
4917
|
+
)
|
4918
|
+
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):
|
4919
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
4920
|
+
else:
|
4921
|
+
cred = credential.Credential(
|
4922
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
4923
|
+
)
|
4924
|
+
http_profile = HttpProfile(
|
4925
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
4926
|
+
reqMethod="POST",
|
4927
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
4928
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
4929
|
+
)
|
4930
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
4931
|
+
if g_param[OptionsDefine.Language]:
|
4932
|
+
profile.language = g_param[OptionsDefine.Language]
|
4933
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
4934
|
+
client = mod.MpsClient(cred, g_param[OptionsDefine.Region], profile)
|
4935
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
4936
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
4937
|
+
model = models.DescribeQualityControlTemplatesRequest()
|
4938
|
+
model.from_json_string(json.dumps(args))
|
4939
|
+
start_time = time.time()
|
4940
|
+
while True:
|
4941
|
+
rsp = client.DescribeQualityControlTemplates(model)
|
4942
|
+
result = rsp.to_json_string()
|
4943
|
+
try:
|
4944
|
+
json_obj = json.loads(result)
|
4945
|
+
except TypeError as e:
|
4946
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
4947
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
4948
|
+
break
|
4949
|
+
cur_time = time.time()
|
4950
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
4951
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
4952
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
4953
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
4954
|
+
else:
|
4955
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
4956
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
4957
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
4958
|
+
|
4959
|
+
|
4752
4960
|
def doDisableSchedule(args, parsed_globals):
|
4753
4961
|
g_param = parse_global_arg(parsed_globals)
|
4754
4962
|
|
@@ -5265,7 +5473,9 @@ ACTION_MAP = {
|
|
5265
5473
|
"DescribeMediaMetaData": doDescribeMediaMetaData,
|
5266
5474
|
"ModifySampleSnapshotTemplate": doModifySampleSnapshotTemplate,
|
5267
5475
|
"ResetWorkflow": doResetWorkflow,
|
5476
|
+
"DeleteQualityControlTemplate": doDeleteQualityControlTemplate,
|
5268
5477
|
"DeleteWorkflow": doDeleteWorkflow,
|
5478
|
+
"CreateQualityControlTemplate": doCreateQualityControlTemplate,
|
5269
5479
|
"ModifyImageSpriteTemplate": doModifyImageSpriteTemplate,
|
5270
5480
|
"DescribeTranscodeTemplates": doDescribeTranscodeTemplates,
|
5271
5481
|
"DeleteStreamLinkFlow": doDeleteStreamLinkFlow,
|
@@ -5276,12 +5486,13 @@ ACTION_MAP = {
|
|
5276
5486
|
"ModifyPersonSample": doModifyPersonSample,
|
5277
5487
|
"DeleteContentReviewTemplate": doDeleteContentReviewTemplate,
|
5278
5488
|
"CreateAIAnalysisTemplate": doCreateAIAnalysisTemplate,
|
5489
|
+
"ModifyQualityControlTemplate": doModifyQualityControlTemplate,
|
5279
5490
|
"StopStreamLinkFlow": doStopStreamLinkFlow,
|
5280
5491
|
"DescribeStreamLinkEventAttachedFlows": doDescribeStreamLinkEventAttachedFlows,
|
5281
5492
|
"ModifyStreamLinkEvent": doModifyStreamLinkEvent,
|
5282
5493
|
"ModifyAnimatedGraphicsTemplate": doModifyAnimatedGraphicsTemplate,
|
5283
5494
|
"ModifyTranscodeTemplate": doModifyTranscodeTemplate,
|
5284
|
-
"
|
5495
|
+
"DescribeAIRecognitionTemplates": doDescribeAIRecognitionTemplates,
|
5285
5496
|
"DescribeStreamLinkEvents": doDescribeStreamLinkEvents,
|
5286
5497
|
"DescribeStreamLinkFlowSRTStatistics": doDescribeStreamLinkFlowSRTStatistics,
|
5287
5498
|
"CreateStreamLinkOutputInfo": doCreateStreamLinkOutputInfo,
|
@@ -5289,7 +5500,7 @@ ACTION_MAP = {
|
|
5289
5500
|
"ModifyWatermarkTemplate": doModifyWatermarkTemplate,
|
5290
5501
|
"DeleteWordSamples": doDeleteWordSamples,
|
5291
5502
|
"DescribeStreamLinkActivateState": doDescribeStreamLinkActivateState,
|
5292
|
-
"
|
5503
|
+
"CreateWatermarkTemplate": doCreateWatermarkTemplate,
|
5293
5504
|
"DescribePersonSamples": doDescribePersonSamples,
|
5294
5505
|
"ParseNotification": doParseNotification,
|
5295
5506
|
"DeleteAIRecognitionTemplate": doDeleteAIRecognitionTemplate,
|
@@ -5303,9 +5514,9 @@ ACTION_MAP = {
|
|
5303
5514
|
"ModifyWordSample": doModifyWordSample,
|
5304
5515
|
"DescribeImageSpriteTemplates": doDescribeImageSpriteTemplates,
|
5305
5516
|
"DescribeWatermarkTemplates": doDescribeWatermarkTemplates,
|
5306
|
-
"
|
5517
|
+
"CreateImageSpriteTemplate": doCreateImageSpriteTemplate,
|
5307
5518
|
"ModifyStreamLinkOutputInfo": doModifyStreamLinkOutputInfo,
|
5308
|
-
"
|
5519
|
+
"DescribeContentReviewTemplates": doDescribeContentReviewTemplates,
|
5309
5520
|
"WithdrawsWatermark": doWithdrawsWatermark,
|
5310
5521
|
"DescribeStreamLinkFlow": doDescribeStreamLinkFlow,
|
5311
5522
|
"DeleteSchedule": doDeleteSchedule,
|
@@ -5319,6 +5530,7 @@ ACTION_MAP = {
|
|
5319
5530
|
"DescribeStreamLinkFlowMediaStatistics": doDescribeStreamLinkFlowMediaStatistics,
|
5320
5531
|
"CreateStreamLinkEvent": doCreateStreamLinkEvent,
|
5321
5532
|
"CreatePersonSample": doCreatePersonSample,
|
5533
|
+
"DescribeQualityControlTemplates": doDescribeQualityControlTemplates,
|
5322
5534
|
"DisableSchedule": doDisableSchedule,
|
5323
5535
|
"CreateStreamLinkInput": doCreateStreamLinkInput,
|
5324
5536
|
"ModifyContentReviewTemplate": doModifyContentReviewTemplate,
|