tccli 3.0.1295.1__py2.py3-none-any.whl → 3.0.1297.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/services/antiddos/v20200309/api.json +125 -118
- tccli/services/batch/v20170312/api.json +9 -8
- tccli/services/bi/v20220105/api.json +17 -17
- tccli/services/bi/v20220105/examples.json +16 -16
- tccli/services/cam/v20190116/api.json +2 -2
- tccli/services/cam/v20190116/examples.json +1 -1
- tccli/services/ccc/ccc_client.py +230 -18
- tccli/services/ccc/v20200210/api.json +398 -17
- tccli/services/ccc/v20200210/examples.json +32 -0
- tccli/services/cdn/v20180606/api.json +61 -55
- tccli/services/cdn/v20180606/examples.json +11 -11
- tccli/services/cfw/v20190904/api.json +1 -1
- tccli/services/chc/v20230418/api.json +1 -1
- tccli/services/ckafka/v20190819/api.json +3 -3
- tccli/services/cme/v20191029/api.json +522 -501
- tccli/services/cme/v20191029/examples.json +138 -138
- tccli/services/cvm/v20170312/api.json +1 -1
- tccli/services/cwp/v20180228/api.json +40 -0
- tccli/services/cynosdb/v20190107/api.json +112 -92
- tccli/services/dnspod/v20210323/api.json +105 -88
- tccli/services/dnspod/v20210323/examples.json +1 -1
- tccli/services/domain/v20180808/api.json +5 -5
- tccli/services/dts/v20180330/api.json +2 -2
- tccli/services/dts/v20211206/api.json +16 -16
- tccli/services/ecdn/v20191012/api.json +4 -4
- tccli/services/emr/v20190103/api.json +2 -2
- tccli/services/ess/v20201111/api.json +13 -4
- tccli/services/essbasic/v20210526/api.json +1 -1
- tccli/services/gs/gs_client.py +53 -0
- tccli/services/gs/v20191118/api.json +53 -0
- tccli/services/gs/v20191118/examples.json +8 -0
- tccli/services/iotcloud/v20210408/api.json +46 -46
- tccli/services/iotcloud/v20210408/examples.json +7 -7
- tccli/services/iotexplorer/v20190423/api.json +20 -0
- tccli/services/iotvideo/v20201215/api.json +4 -4
- tccli/services/iotvideo/v20201215/examples.json +2 -2
- tccli/services/iotvideo/v20211125/api.json +27 -7
- tccli/services/iotvideo/v20211125/examples.json +5 -5
- tccli/services/iss/iss_client.py +411 -305
- tccli/services/iss/v20230517/api.json +236 -0
- tccli/services/iss/v20230517/examples.json +16 -0
- tccli/services/lighthouse/v20200324/api.json +3 -3
- tccli/services/live/v20180801/api.json +31 -2
- tccli/services/live/v20180801/examples.json +1 -1
- tccli/services/lke/v20231130/api.json +34 -1
- tccli/services/lkeap/v20240522/api.json +10 -0
- tccli/services/mmps/v20200710/api.json +8 -8
- tccli/services/mqtt/v20240516/api.json +82 -43
- tccli/services/mqtt/v20240516/examples.json +7 -7
- tccli/services/ocr/ocr_client.py +16 -175
- tccli/services/ocr/v20181119/api.json +15 -245
- tccli/services/ocr/v20181119/examples.json +1 -25
- tccli/services/partners/partners_client.py +118 -65
- tccli/services/partners/v20180321/api.json +93 -0
- tccli/services/partners/v20180321/examples.json +8 -0
- tccli/services/rce/v20201103/api.json +0 -9
- tccli/services/rce/v20201103/examples.json +1 -1
- tccli/services/sqlserver/v20180328/api.json +37 -0
- tccli/services/tag/v20180813/api.json +75 -73
- tccli/services/tag/v20180813/examples.json +10 -10
- tccli/services/tdid/v20210519/api.json +12 -12
- tccli/services/tdmq/tdmq_client.py +0 -53
- tccli/services/tdmq/v20200217/api.json +6 -58
- tccli/services/tdmq/v20200217/examples.json +0 -8
- tccli/services/thpc/v20230321/api.json +10 -0
- tccli/services/tione/tione_client.py +220 -8
- tccli/services/tione/v20211111/api.json +359 -0
- tccli/services/tione/v20211111/examples.json +32 -0
- tccli/services/tke/v20180525/api.json +5 -5
- tccli/services/tke/v20180525/examples.json +1 -1
- tccli/services/trtc/v20190722/api.json +29 -1
- tccli/services/vod/v20180717/api.json +735 -673
- tccli/services/vod/v20180717/examples.json +34 -34
- tccli/services/vpc/v20170312/api.json +53 -53
- tccli/services/vpc/v20170312/examples.json +5 -5
- {tccli-3.0.1295.1.dist-info → tccli-3.0.1297.1.dist-info}/METADATA +2 -2
- {tccli-3.0.1295.1.dist-info → tccli-3.0.1297.1.dist-info}/RECORD +81 -81
- {tccli-3.0.1295.1.dist-info → tccli-3.0.1297.1.dist-info}/WHEEL +0 -0
- {tccli-3.0.1295.1.dist-info → tccli-3.0.1297.1.dist-info}/entry_points.txt +0 -0
- {tccli-3.0.1295.1.dist-info → tccli-3.0.1297.1.dist-info}/license_files/LICENSE +0 -0
tccli/services/ccc/ccc_client.py
CHANGED
@@ -17,7 +17,7 @@ from tencentcloud.ccc.v20200210 import models as models_v20200210
|
|
17
17
|
from jmespath import search
|
18
18
|
import time
|
19
19
|
|
20
|
-
def
|
20
|
+
def doModifyCompanyApply(args, parsed_globals):
|
21
21
|
g_param = parse_global_arg(parsed_globals)
|
22
22
|
|
23
23
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -46,11 +46,11 @@ def doModifyStaff(args, parsed_globals):
|
|
46
46
|
client = mod.CccClient(cred, g_param[OptionsDefine.Region], profile)
|
47
47
|
client._sdkVersion += ("_CLI_" + __version__)
|
48
48
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
49
|
-
model = models.
|
49
|
+
model = models.ModifyCompanyApplyRequest()
|
50
50
|
model.from_json_string(json.dumps(args))
|
51
51
|
start_time = time.time()
|
52
52
|
while True:
|
53
|
-
rsp = client.
|
53
|
+
rsp = client.ModifyCompanyApply(model)
|
54
54
|
result = rsp.to_json_string()
|
55
55
|
try:
|
56
56
|
json_obj = json.loads(result)
|
@@ -69,7 +69,7 @@ def doModifyStaff(args, parsed_globals):
|
|
69
69
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
70
70
|
|
71
71
|
|
72
|
-
def
|
72
|
+
def doUnbindNumberCallOutSkillGroup(args, parsed_globals):
|
73
73
|
g_param = parse_global_arg(parsed_globals)
|
74
74
|
|
75
75
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -98,11 +98,63 @@ def doDescribeExtensions(args, parsed_globals):
|
|
98
98
|
client = mod.CccClient(cred, g_param[OptionsDefine.Region], profile)
|
99
99
|
client._sdkVersion += ("_CLI_" + __version__)
|
100
100
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
101
|
-
model = models.
|
101
|
+
model = models.UnbindNumberCallOutSkillGroupRequest()
|
102
102
|
model.from_json_string(json.dumps(args))
|
103
103
|
start_time = time.time()
|
104
104
|
while True:
|
105
|
-
rsp = client.
|
105
|
+
rsp = client.UnbindNumberCallOutSkillGroup(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
|
+
|
124
|
+
def doModifyStaff(args, parsed_globals):
|
125
|
+
g_param = parse_global_arg(parsed_globals)
|
126
|
+
|
127
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
128
|
+
cred = credential.CVMRoleCredential()
|
129
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
130
|
+
cred = credential.STSAssumeRoleCredential(
|
131
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
132
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
133
|
+
)
|
134
|
+
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):
|
135
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
136
|
+
else:
|
137
|
+
cred = credential.Credential(
|
138
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
139
|
+
)
|
140
|
+
http_profile = HttpProfile(
|
141
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
142
|
+
reqMethod="POST",
|
143
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
144
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
145
|
+
)
|
146
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
147
|
+
if g_param[OptionsDefine.Language]:
|
148
|
+
profile.language = g_param[OptionsDefine.Language]
|
149
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
150
|
+
client = mod.CccClient(cred, g_param[OptionsDefine.Region], profile)
|
151
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
152
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
153
|
+
model = models.ModifyStaffRequest()
|
154
|
+
model.from_json_string(json.dumps(args))
|
155
|
+
start_time = time.time()
|
156
|
+
while True:
|
157
|
+
rsp = client.ModifyStaff(model)
|
106
158
|
result = rsp.to_json_string()
|
107
159
|
try:
|
108
160
|
json_obj = json.loads(result)
|
@@ -173,6 +225,58 @@ def doDescribeAutoCalloutTasks(args, parsed_globals):
|
|
173
225
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
174
226
|
|
175
227
|
|
228
|
+
def doAbortAgentCruiseDialingCampaign(args, parsed_globals):
|
229
|
+
g_param = parse_global_arg(parsed_globals)
|
230
|
+
|
231
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
232
|
+
cred = credential.CVMRoleCredential()
|
233
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
234
|
+
cred = credential.STSAssumeRoleCredential(
|
235
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
236
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
237
|
+
)
|
238
|
+
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):
|
239
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
240
|
+
else:
|
241
|
+
cred = credential.Credential(
|
242
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
243
|
+
)
|
244
|
+
http_profile = HttpProfile(
|
245
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
246
|
+
reqMethod="POST",
|
247
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
248
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
249
|
+
)
|
250
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
251
|
+
if g_param[OptionsDefine.Language]:
|
252
|
+
profile.language = g_param[OptionsDefine.Language]
|
253
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
254
|
+
client = mod.CccClient(cred, g_param[OptionsDefine.Region], profile)
|
255
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
256
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
257
|
+
model = models.AbortAgentCruiseDialingCampaignRequest()
|
258
|
+
model.from_json_string(json.dumps(args))
|
259
|
+
start_time = time.time()
|
260
|
+
while True:
|
261
|
+
rsp = client.AbortAgentCruiseDialingCampaign(model)
|
262
|
+
result = rsp.to_json_string()
|
263
|
+
try:
|
264
|
+
json_obj = json.loads(result)
|
265
|
+
except TypeError as e:
|
266
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
267
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
268
|
+
break
|
269
|
+
cur_time = time.time()
|
270
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
271
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
272
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
273
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
274
|
+
else:
|
275
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
276
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
277
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
278
|
+
|
279
|
+
|
176
280
|
def doCreateAICall(args, parsed_globals):
|
177
281
|
g_param = parse_global_arg(parsed_globals)
|
178
282
|
|
@@ -225,6 +329,58 @@ def doCreateAICall(args, parsed_globals):
|
|
225
329
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
226
330
|
|
227
331
|
|
332
|
+
def doDescribeAgentCruiseDialingCampaign(args, parsed_globals):
|
333
|
+
g_param = parse_global_arg(parsed_globals)
|
334
|
+
|
335
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
336
|
+
cred = credential.CVMRoleCredential()
|
337
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
338
|
+
cred = credential.STSAssumeRoleCredential(
|
339
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
340
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
341
|
+
)
|
342
|
+
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):
|
343
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
344
|
+
else:
|
345
|
+
cred = credential.Credential(
|
346
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
347
|
+
)
|
348
|
+
http_profile = HttpProfile(
|
349
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
350
|
+
reqMethod="POST",
|
351
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
352
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
353
|
+
)
|
354
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
355
|
+
if g_param[OptionsDefine.Language]:
|
356
|
+
profile.language = g_param[OptionsDefine.Language]
|
357
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
358
|
+
client = mod.CccClient(cred, g_param[OptionsDefine.Region], profile)
|
359
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
360
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
361
|
+
model = models.DescribeAgentCruiseDialingCampaignRequest()
|
362
|
+
model.from_json_string(json.dumps(args))
|
363
|
+
start_time = time.time()
|
364
|
+
while True:
|
365
|
+
rsp = client.DescribeAgentCruiseDialingCampaign(model)
|
366
|
+
result = rsp.to_json_string()
|
367
|
+
try:
|
368
|
+
json_obj = json.loads(result)
|
369
|
+
except TypeError as e:
|
370
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
371
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
372
|
+
break
|
373
|
+
cur_time = time.time()
|
374
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
375
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
376
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
377
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
378
|
+
else:
|
379
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
380
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
381
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
382
|
+
|
383
|
+
|
228
384
|
def doDescribeTelRecordAsr(args, parsed_globals):
|
229
385
|
g_param = parse_global_arg(parsed_globals)
|
230
386
|
|
@@ -745,7 +901,7 @@ def doDeleteStaff(args, parsed_globals):
|
|
745
901
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
746
902
|
|
747
903
|
|
748
|
-
def
|
904
|
+
def doDescribeExtensions(args, parsed_globals):
|
749
905
|
g_param = parse_global_arg(parsed_globals)
|
750
906
|
|
751
907
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -774,11 +930,11 @@ def doModifyCompanyApply(args, parsed_globals):
|
|
774
930
|
client = mod.CccClient(cred, g_param[OptionsDefine.Region], profile)
|
775
931
|
client._sdkVersion += ("_CLI_" + __version__)
|
776
932
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
777
|
-
model = models.
|
933
|
+
model = models.DescribeExtensionsRequest()
|
778
934
|
model.from_json_string(json.dumps(args))
|
779
935
|
start_time = time.time()
|
780
936
|
while True:
|
781
|
-
rsp = client.
|
937
|
+
rsp = client.DescribeExtensions(model)
|
782
938
|
result = rsp.to_json_string()
|
783
939
|
try:
|
784
940
|
json_obj = json.loads(result)
|
@@ -1421,7 +1577,7 @@ def doResumePredictiveDialingCampaign(args, parsed_globals):
|
|
1421
1577
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1422
1578
|
|
1423
1579
|
|
1424
|
-
def
|
1580
|
+
def doTransferToManual(args, parsed_globals):
|
1425
1581
|
g_param = parse_global_arg(parsed_globals)
|
1426
1582
|
|
1427
1583
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -1450,11 +1606,11 @@ def doDescribeSkillGroupInfoList(args, parsed_globals):
|
|
1450
1606
|
client = mod.CccClient(cred, g_param[OptionsDefine.Region], profile)
|
1451
1607
|
client._sdkVersion += ("_CLI_" + __version__)
|
1452
1608
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
1453
|
-
model = models.
|
1609
|
+
model = models.TransferToManualRequest()
|
1454
1610
|
model.from_json_string(json.dumps(args))
|
1455
1611
|
start_time = time.time()
|
1456
1612
|
while True:
|
1457
|
-
rsp = client.
|
1613
|
+
rsp = client.TransferToManual(model)
|
1458
1614
|
result = rsp.to_json_string()
|
1459
1615
|
try:
|
1460
1616
|
json_obj = json.loads(result)
|
@@ -1473,7 +1629,7 @@ def doDescribeSkillGroupInfoList(args, parsed_globals):
|
|
1473
1629
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1474
1630
|
|
1475
1631
|
|
1476
|
-
def
|
1632
|
+
def doDescribeSkillGroupInfoList(args, parsed_globals):
|
1477
1633
|
g_param = parse_global_arg(parsed_globals)
|
1478
1634
|
|
1479
1635
|
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
@@ -1502,11 +1658,11 @@ def doUnbindNumberCallOutSkillGroup(args, parsed_globals):
|
|
1502
1658
|
client = mod.CccClient(cred, g_param[OptionsDefine.Region], profile)
|
1503
1659
|
client._sdkVersion += ("_CLI_" + __version__)
|
1504
1660
|
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
1505
|
-
model = models.
|
1661
|
+
model = models.DescribeSkillGroupInfoListRequest()
|
1506
1662
|
model.from_json_string(json.dumps(args))
|
1507
1663
|
start_time = time.time()
|
1508
1664
|
while True:
|
1509
|
-
rsp = client.
|
1665
|
+
rsp = client.DescribeSkillGroupInfoList(model)
|
1510
1666
|
result = rsp.to_json_string()
|
1511
1667
|
try:
|
1512
1668
|
json_obj = json.loads(result)
|
@@ -1785,6 +1941,58 @@ def doCreateCarrierPrivilegeNumberApplicant(args, parsed_globals):
|
|
1785
1941
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
1786
1942
|
|
1787
1943
|
|
1944
|
+
def doCreateAgentCruiseDialingCampaign(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.CccClient(cred, g_param[OptionsDefine.Region], profile)
|
1971
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
1972
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
1973
|
+
model = models.CreateAgentCruiseDialingCampaignRequest()
|
1974
|
+
model.from_json_string(json.dumps(args))
|
1975
|
+
start_time = time.time()
|
1976
|
+
while True:
|
1977
|
+
rsp = client.CreateAgentCruiseDialingCampaign(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
|
+
|
1788
1996
|
def doDescribeActiveCarrierPrivilegeNumber(args, parsed_globals):
|
1789
1997
|
g_param = parse_global_arg(parsed_globals)
|
1790
1998
|
|
@@ -3356,10 +3564,13 @@ MODELS_MAP = {
|
|
3356
3564
|
}
|
3357
3565
|
|
3358
3566
|
ACTION_MAP = {
|
3567
|
+
"ModifyCompanyApply": doModifyCompanyApply,
|
3568
|
+
"UnbindNumberCallOutSkillGroup": doUnbindNumberCallOutSkillGroup,
|
3359
3569
|
"ModifyStaff": doModifyStaff,
|
3360
|
-
"DescribeExtensions": doDescribeExtensions,
|
3361
3570
|
"DescribeAutoCalloutTasks": doDescribeAutoCalloutTasks,
|
3571
|
+
"AbortAgentCruiseDialingCampaign": doAbortAgentCruiseDialingCampaign,
|
3362
3572
|
"CreateAICall": doCreateAICall,
|
3573
|
+
"DescribeAgentCruiseDialingCampaign": doDescribeAgentCruiseDialingCampaign,
|
3363
3574
|
"DescribeTelRecordAsr": doDescribeTelRecordAsr,
|
3364
3575
|
"ModifyOwnNumberApply": doModifyOwnNumberApply,
|
3365
3576
|
"DescribePredictiveDialingCampaign": doDescribePredictiveDialingCampaign,
|
@@ -3370,7 +3581,7 @@ ACTION_MAP = {
|
|
3370
3581
|
"DescribeIMCdrs": doDescribeIMCdrs,
|
3371
3582
|
"CreatePredictiveDialingCampaign": doCreatePredictiveDialingCampaign,
|
3372
3583
|
"DeleteStaff": doDeleteStaff,
|
3373
|
-
"
|
3584
|
+
"DescribeExtensions": doDescribeExtensions,
|
3374
3585
|
"CreateExtension": doCreateExtension,
|
3375
3586
|
"ResetExtensionPassword": doResetExtensionPassword,
|
3376
3587
|
"CreateStaff": doCreateStaff,
|
@@ -3383,13 +3594,14 @@ ACTION_MAP = {
|
|
3383
3594
|
"DescribePredictiveDialingSessions": doDescribePredictiveDialingSessions,
|
3384
3595
|
"CreateCompanyApply": doCreateCompanyApply,
|
3385
3596
|
"ResumePredictiveDialingCampaign": doResumePredictiveDialingCampaign,
|
3597
|
+
"TransferToManual": doTransferToManual,
|
3386
3598
|
"DescribeSkillGroupInfoList": doDescribeSkillGroupInfoList,
|
3387
|
-
"UnbindNumberCallOutSkillGroup": doUnbindNumberCallOutSkillGroup,
|
3388
3599
|
"StopAutoCalloutTask": doStopAutoCalloutTask,
|
3389
3600
|
"DescribeIvrAudioList": doDescribeIvrAudioList,
|
3390
3601
|
"BindNumberCallOutSkillGroup": doBindNumberCallOutSkillGroup,
|
3391
3602
|
"UploadIvrAudio": doUploadIvrAudio,
|
3392
3603
|
"CreateCarrierPrivilegeNumberApplicant": doCreateCarrierPrivilegeNumberApplicant,
|
3604
|
+
"CreateAgentCruiseDialingCampaign": doCreateAgentCruiseDialingCampaign,
|
3393
3605
|
"DescribeActiveCarrierPrivilegeNumber": doDescribeActiveCarrierPrivilegeNumber,
|
3394
3606
|
"CreateOwnNumberApply": doCreateOwnNumberApply,
|
3395
3607
|
"DescribeCCCBuyInfoList": doDescribeCCCBuyInfoList,
|