tccli 3.0.846.1__py2.py3-none-any.whl → 3.0.847.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/billing/v20180709/api.json +2 -20
- tccli/services/billing/v20180709/examples.json +2 -2
- tccli/services/cat/v20180409/api.json +0 -28
- tccli/services/cat/v20180409/examples.json +7 -7
- tccli/services/ccc/v20200210/api.json +16 -7
- tccli/services/ccc/v20200210/examples.json +2 -2
- tccli/services/cdb/v20170320/api.json +63 -46
- tccli/services/cdb/v20170320/examples.json +3 -3
- tccli/services/cdn/v20180606/api.json +1 -11
- tccli/services/cdn/v20180606/examples.json +1 -1
- tccli/services/cls/v20201016/api.json +44 -33
- tccli/services/cls/v20201016/examples.json +3 -3
- tccli/services/cvm/v20170312/api.json +2 -4
- tccli/services/ess/ess_client.py +212 -0
- tccli/services/ess/v20201111/api.json +456 -21
- tccli/services/ess/v20201111/examples.json +45 -1
- tccli/services/essbasic/v20210526/api.json +1 -1
- tccli/services/iotexplorer/v20190423/api.json +25 -33
- tccli/services/iotexplorer/v20190423/examples.json +9 -9
- tccli/services/monitor/v20180724/api.json +8 -0
- tccli/services/monitor/v20180724/examples.json +2 -2
- tccli/services/mps/v20190612/api.json +2 -7
- tccli/services/ocr/v20181119/api.json +45 -66
- tccli/services/ocr/v20181119/examples.json +16 -16
- tccli/services/tcss/v20201101/api.json +40 -7
- tccli/services/tcss/v20201101/examples.json +3 -3
- tccli/services/trtc/v20190722/api.json +41 -29
- tccli/services/trtc/v20190722/examples.json +10 -10
- {tccli-3.0.846.1.dist-info → tccli-3.0.847.1.dist-info}/METADATA +2 -2
- {tccli-3.0.846.1.dist-info → tccli-3.0.847.1.dist-info}/RECORD +35 -35
- {tccli-3.0.846.1.dist-info → tccli-3.0.847.1.dist-info}/LICENSE +0 -0
- {tccli-3.0.846.1.dist-info → tccli-3.0.847.1.dist-info}/WHEEL +0 -0
- {tccli-3.0.846.1.dist-info → tccli-3.0.847.1.dist-info}/entry_points.txt +0 -0
- {tccli-3.0.846.1.dist-info → tccli-3.0.847.1.dist-info}/top_level.txt +0 -0
tccli/services/ess/ess_client.py
CHANGED
@@ -693,6 +693,58 @@ def doCreateFlowApprovers(args, parsed_globals):
|
|
693
693
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
694
694
|
|
695
695
|
|
696
|
+
def doDeleteIntegrationRoleUsers(args, parsed_globals):
|
697
|
+
g_param = parse_global_arg(parsed_globals)
|
698
|
+
|
699
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
700
|
+
cred = credential.CVMRoleCredential()
|
701
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
702
|
+
cred = credential.STSAssumeRoleCredential(
|
703
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
704
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
705
|
+
)
|
706
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
707
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
708
|
+
else:
|
709
|
+
cred = credential.Credential(
|
710
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
711
|
+
)
|
712
|
+
http_profile = HttpProfile(
|
713
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
714
|
+
reqMethod="POST",
|
715
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
716
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
717
|
+
)
|
718
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
719
|
+
if g_param[OptionsDefine.Language]:
|
720
|
+
profile.language = g_param[OptionsDefine.Language]
|
721
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
722
|
+
client = mod.EssClient(cred, g_param[OptionsDefine.Region], profile)
|
723
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
724
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
725
|
+
model = models.DeleteIntegrationRoleUsersRequest()
|
726
|
+
model.from_json_string(json.dumps(args))
|
727
|
+
start_time = time.time()
|
728
|
+
while True:
|
729
|
+
rsp = client.DeleteIntegrationRoleUsers(model)
|
730
|
+
result = rsp.to_json_string()
|
731
|
+
try:
|
732
|
+
json_obj = json.loads(result)
|
733
|
+
except TypeError as e:
|
734
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
735
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
736
|
+
break
|
737
|
+
cur_time = time.time()
|
738
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
739
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
740
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
741
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
742
|
+
else:
|
743
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
744
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
745
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
746
|
+
|
747
|
+
|
696
748
|
def doCreateFlowSignReview(args, parsed_globals):
|
697
749
|
g_param = parse_global_arg(parsed_globals)
|
698
750
|
|
@@ -1213,6 +1265,58 @@ def doCreateFlowByFiles(args, parsed_globals):
|
|
1213
1265
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1214
1266
|
|
1215
1267
|
|
1268
|
+
def doDescribeIntegrationRoles(args, parsed_globals):
|
1269
|
+
g_param = parse_global_arg(parsed_globals)
|
1270
|
+
|
1271
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
1272
|
+
cred = credential.CVMRoleCredential()
|
1273
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1274
|
+
cred = credential.STSAssumeRoleCredential(
|
1275
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1276
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1277
|
+
)
|
1278
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1279
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
1280
|
+
else:
|
1281
|
+
cred = credential.Credential(
|
1282
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
1283
|
+
)
|
1284
|
+
http_profile = HttpProfile(
|
1285
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
1286
|
+
reqMethod="POST",
|
1287
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
1288
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
1289
|
+
)
|
1290
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
1291
|
+
if g_param[OptionsDefine.Language]:
|
1292
|
+
profile.language = g_param[OptionsDefine.Language]
|
1293
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
1294
|
+
client = mod.EssClient(cred, g_param[OptionsDefine.Region], profile)
|
1295
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
1296
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
1297
|
+
model = models.DescribeIntegrationRolesRequest()
|
1298
|
+
model.from_json_string(json.dumps(args))
|
1299
|
+
start_time = time.time()
|
1300
|
+
while True:
|
1301
|
+
rsp = client.DescribeIntegrationRoles(model)
|
1302
|
+
result = rsp.to_json_string()
|
1303
|
+
try:
|
1304
|
+
json_obj = json.loads(result)
|
1305
|
+
except TypeError as e:
|
1306
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
1307
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
1308
|
+
break
|
1309
|
+
cur_time = time.time()
|
1310
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
1311
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
1312
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
1313
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
1314
|
+
else:
|
1315
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
1316
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
1317
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1318
|
+
|
1319
|
+
|
1216
1320
|
def doCreateMultiFlowSignQRCode(args, parsed_globals):
|
1217
1321
|
g_param = parse_global_arg(parsed_globals)
|
1218
1322
|
|
@@ -1577,6 +1681,58 @@ def doDescribeFlowBriefs(args, parsed_globals):
|
|
1577
1681
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1578
1682
|
|
1579
1683
|
|
1684
|
+
def doCreateIntegrationUserRoles(args, parsed_globals):
|
1685
|
+
g_param = parse_global_arg(parsed_globals)
|
1686
|
+
|
1687
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
1688
|
+
cred = credential.CVMRoleCredential()
|
1689
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
1690
|
+
cred = credential.STSAssumeRoleCredential(
|
1691
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
1692
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
1693
|
+
)
|
1694
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
1695
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
1696
|
+
else:
|
1697
|
+
cred = credential.Credential(
|
1698
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
1699
|
+
)
|
1700
|
+
http_profile = HttpProfile(
|
1701
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
1702
|
+
reqMethod="POST",
|
1703
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
1704
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
1705
|
+
)
|
1706
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
1707
|
+
if g_param[OptionsDefine.Language]:
|
1708
|
+
profile.language = g_param[OptionsDefine.Language]
|
1709
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
1710
|
+
client = mod.EssClient(cred, g_param[OptionsDefine.Region], profile)
|
1711
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
1712
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
1713
|
+
model = models.CreateIntegrationUserRolesRequest()
|
1714
|
+
model.from_json_string(json.dumps(args))
|
1715
|
+
start_time = time.time()
|
1716
|
+
while True:
|
1717
|
+
rsp = client.CreateIntegrationUserRoles(model)
|
1718
|
+
result = rsp.to_json_string()
|
1719
|
+
try:
|
1720
|
+
json_obj = json.loads(result)
|
1721
|
+
except TypeError as e:
|
1722
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
1723
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
1724
|
+
break
|
1725
|
+
cur_time = time.time()
|
1726
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
1727
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
1728
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
1729
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
1730
|
+
else:
|
1731
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
1732
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
1733
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1734
|
+
|
1735
|
+
|
1580
1736
|
def doUploadFiles(args, parsed_globals):
|
1581
1737
|
g_param = parse_global_arg(parsed_globals)
|
1582
1738
|
|
@@ -2045,6 +2201,58 @@ def doCreateIntegrationEmployees(args, parsed_globals):
|
|
2045
2201
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
2046
2202
|
|
2047
2203
|
|
2204
|
+
def doUpdateIntegrationEmployees(args, parsed_globals):
|
2205
|
+
g_param = parse_global_arg(parsed_globals)
|
2206
|
+
|
2207
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
2208
|
+
cred = credential.CVMRoleCredential()
|
2209
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2210
|
+
cred = credential.STSAssumeRoleCredential(
|
2211
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2212
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')]
|
2213
|
+
)
|
2214
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
2215
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
2216
|
+
else:
|
2217
|
+
cred = credential.Credential(
|
2218
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
2219
|
+
)
|
2220
|
+
http_profile = HttpProfile(
|
2221
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
2222
|
+
reqMethod="POST",
|
2223
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
2224
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
2225
|
+
)
|
2226
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
2227
|
+
if g_param[OptionsDefine.Language]:
|
2228
|
+
profile.language = g_param[OptionsDefine.Language]
|
2229
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
2230
|
+
client = mod.EssClient(cred, g_param[OptionsDefine.Region], profile)
|
2231
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
2232
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
2233
|
+
model = models.UpdateIntegrationEmployeesRequest()
|
2234
|
+
model.from_json_string(json.dumps(args))
|
2235
|
+
start_time = time.time()
|
2236
|
+
while True:
|
2237
|
+
rsp = client.UpdateIntegrationEmployees(model)
|
2238
|
+
result = rsp.to_json_string()
|
2239
|
+
try:
|
2240
|
+
json_obj = json.loads(result)
|
2241
|
+
except TypeError as e:
|
2242
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
2243
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
2244
|
+
break
|
2245
|
+
cur_time = time.time()
|
2246
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
2247
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
2248
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
2249
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
2250
|
+
else:
|
2251
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
2252
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
2253
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
2254
|
+
|
2255
|
+
|
2048
2256
|
CLIENT_MAP = {
|
2049
2257
|
"v20201111": ess_client_v20201111,
|
2050
2258
|
|
@@ -2069,6 +2277,7 @@ ACTION_MAP = {
|
|
2069
2277
|
"CreateBatchCancelFlowUrl": doCreateBatchCancelFlowUrl,
|
2070
2278
|
"CreatePreparedPersonalEsign": doCreatePreparedPersonalEsign,
|
2071
2279
|
"CreateFlowApprovers": doCreateFlowApprovers,
|
2280
|
+
"DeleteIntegrationRoleUsers": doDeleteIntegrationRoleUsers,
|
2072
2281
|
"CreateFlowSignReview": doCreateFlowSignReview,
|
2073
2282
|
"CreatePrepareFlow": doCreatePrepareFlow,
|
2074
2283
|
"CreateDocument": doCreateDocument,
|
@@ -2079,6 +2288,7 @@ ACTION_MAP = {
|
|
2079
2288
|
"DescribeUserAutoSignStatus": doDescribeUserAutoSignStatus,
|
2080
2289
|
"DisableUserAutoSign": doDisableUserAutoSign,
|
2081
2290
|
"CreateFlowByFiles": doCreateFlowByFiles,
|
2291
|
+
"DescribeIntegrationRoles": doDescribeIntegrationRoles,
|
2082
2292
|
"CreateMultiFlowSignQRCode": doCreateMultiFlowSignQRCode,
|
2083
2293
|
"GetTaskResultApi": doGetTaskResultApi,
|
2084
2294
|
"CancelMultiFlowSignQRCode": doCancelMultiFlowSignQRCode,
|
@@ -2086,6 +2296,7 @@ ACTION_MAP = {
|
|
2086
2296
|
"CreateFlowReminds": doCreateFlowReminds,
|
2087
2297
|
"CreateConvertTaskApi": doCreateConvertTaskApi,
|
2088
2298
|
"DescribeFlowBriefs": doDescribeFlowBriefs,
|
2299
|
+
"CreateIntegrationUserRoles": doCreateIntegrationUserRoles,
|
2089
2300
|
"UploadFiles": doUploadFiles,
|
2090
2301
|
"CreateFlowSignUrl": doCreateFlowSignUrl,
|
2091
2302
|
"DescribeIntegrationMainOrganizationUser": doDescribeIntegrationMainOrganizationUser,
|
@@ -2095,6 +2306,7 @@ ACTION_MAP = {
|
|
2095
2306
|
"CreateSchemeUrl": doCreateSchemeUrl,
|
2096
2307
|
"DescribeThirdPartyAuthCode": doDescribeThirdPartyAuthCode,
|
2097
2308
|
"CreateIntegrationEmployees": doCreateIntegrationEmployees,
|
2309
|
+
"UpdateIntegrationEmployees": doUpdateIntegrationEmployees,
|
2098
2310
|
|
2099
2311
|
}
|
2100
2312
|
|