tccli 3.0.1088.1__py2.py3-none-any.whl → 3.0.1090.1__py2.py3-none-any.whl

Sign up to get free protection for your applications and to get access to all the features.
Files changed (30) hide show
  1. tccli/__init__.py +1 -1
  2. tccli/examples/ccc/v20200210/DescribeIvrAudioList.md +32 -0
  3. tccli/examples/ccc/v20200210/UploadIvrAudio.md +22 -0
  4. tccli/examples/csip/v20221121/DescribeAssetViewVulRiskList.md +455 -0
  5. tccli/examples/mongodb/v20190725/FlashBackDBInstance.md +29 -0
  6. tccli/examples/ssl/v20191205/DeployCertificateInstance.md +3 -3
  7. tccli/services/bri/v20190328/api.json +2 -2
  8. tccli/services/ccc/ccc_client.py +110 -4
  9. tccli/services/ccc/v20200210/api.json +248 -0
  10. tccli/services/ccc/v20200210/examples.json +16 -0
  11. tccli/services/csip/csip_client.py +53 -0
  12. tccli/services/csip/v20221121/api.json +518 -0
  13. tccli/services/csip/v20221121/examples.json +8 -0
  14. tccli/services/cvm/v20170312/api.json +1 -1
  15. tccli/services/ess/v20201111/api.json +18 -0
  16. tccli/services/essbasic/v20210526/api.json +18 -0
  17. tccli/services/lcic/v20220817/api.json +5 -5
  18. tccli/services/lighthouse/v20200324/api.json +1 -1
  19. tccli/services/live/v20180801/api.json +33 -0
  20. tccli/services/mongodb/mongodb_client.py +67 -14
  21. tccli/services/mongodb/v20190725/api.json +161 -0
  22. tccli/services/mongodb/v20190725/examples.json +8 -0
  23. tccli/services/ssl/v20191205/api.json +11 -2
  24. tccli/services/ssl/v20191205/examples.json +2 -2
  25. tccli/services/vpc/v20170312/api.json +10 -0
  26. {tccli-3.0.1088.1.dist-info → tccli-3.0.1090.1.dist-info}/METADATA +2 -2
  27. {tccli-3.0.1088.1.dist-info → tccli-3.0.1090.1.dist-info}/RECORD +30 -26
  28. {tccli-3.0.1088.1.dist-info → tccli-3.0.1090.1.dist-info}/WHEEL +0 -0
  29. {tccli-3.0.1088.1.dist-info → tccli-3.0.1090.1.dist-info}/entry_points.txt +0 -0
  30. {tccli-3.0.1088.1.dist-info → tccli-3.0.1090.1.dist-info}/license_files/LICENSE +0 -0
@@ -589,6 +589,58 @@ def doDescribeIMCdrs(args, parsed_globals):
589
589
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
590
590
 
591
591
 
592
+ def doCreatePredictiveDialingCampaign(args, parsed_globals):
593
+ g_param = parse_global_arg(parsed_globals)
594
+
595
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
596
+ cred = credential.CVMRoleCredential()
597
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
598
+ cred = credential.STSAssumeRoleCredential(
599
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
600
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
601
+ )
602
+ 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):
603
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
604
+ else:
605
+ cred = credential.Credential(
606
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
607
+ )
608
+ http_profile = HttpProfile(
609
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
610
+ reqMethod="POST",
611
+ endpoint=g_param[OptionsDefine.Endpoint],
612
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
613
+ )
614
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
615
+ if g_param[OptionsDefine.Language]:
616
+ profile.language = g_param[OptionsDefine.Language]
617
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
618
+ client = mod.CccClient(cred, g_param[OptionsDefine.Region], profile)
619
+ client._sdkVersion += ("_CLI_" + __version__)
620
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
621
+ model = models.CreatePredictiveDialingCampaignRequest()
622
+ model.from_json_string(json.dumps(args))
623
+ start_time = time.time()
624
+ while True:
625
+ rsp = client.CreatePredictiveDialingCampaign(model)
626
+ result = rsp.to_json_string()
627
+ try:
628
+ json_obj = json.loads(result)
629
+ except TypeError as e:
630
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
631
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
632
+ break
633
+ cur_time = time.time()
634
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
635
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
636
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
637
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
638
+ else:
639
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
640
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
641
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
642
+
643
+
592
644
  def doDeleteStaff(args, parsed_globals):
593
645
  g_param = parse_global_arg(parsed_globals)
594
646
 
@@ -1369,7 +1421,7 @@ def doStopAutoCalloutTask(args, parsed_globals):
1369
1421
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
1370
1422
 
1371
1423
 
1372
- def doCreatePredictiveDialingCampaign(args, parsed_globals):
1424
+ def doDescribeIvrAudioList(args, parsed_globals):
1373
1425
  g_param = parse_global_arg(parsed_globals)
1374
1426
 
1375
1427
  if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
@@ -1398,11 +1450,11 @@ def doCreatePredictiveDialingCampaign(args, parsed_globals):
1398
1450
  client = mod.CccClient(cred, g_param[OptionsDefine.Region], profile)
1399
1451
  client._sdkVersion += ("_CLI_" + __version__)
1400
1452
  models = MODELS_MAP[g_param[OptionsDefine.Version]]
1401
- model = models.CreatePredictiveDialingCampaignRequest()
1453
+ model = models.DescribeIvrAudioListRequest()
1402
1454
  model.from_json_string(json.dumps(args))
1403
1455
  start_time = time.time()
1404
1456
  while True:
1405
- rsp = client.CreatePredictiveDialingCampaign(model)
1457
+ rsp = client.DescribeIvrAudioList(model)
1406
1458
  result = rsp.to_json_string()
1407
1459
  try:
1408
1460
  json_obj = json.loads(result)
@@ -1473,6 +1525,58 @@ def doCreateCarrierPrivilegeNumberApplicant(args, parsed_globals):
1473
1525
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
1474
1526
 
1475
1527
 
1528
+ def doUploadIvrAudio(args, parsed_globals):
1529
+ g_param = parse_global_arg(parsed_globals)
1530
+
1531
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
1532
+ cred = credential.CVMRoleCredential()
1533
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1534
+ cred = credential.STSAssumeRoleCredential(
1535
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1536
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1537
+ )
1538
+ 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):
1539
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
1540
+ else:
1541
+ cred = credential.Credential(
1542
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
1543
+ )
1544
+ http_profile = HttpProfile(
1545
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
1546
+ reqMethod="POST",
1547
+ endpoint=g_param[OptionsDefine.Endpoint],
1548
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
1549
+ )
1550
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
1551
+ if g_param[OptionsDefine.Language]:
1552
+ profile.language = g_param[OptionsDefine.Language]
1553
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
1554
+ client = mod.CccClient(cred, g_param[OptionsDefine.Region], profile)
1555
+ client._sdkVersion += ("_CLI_" + __version__)
1556
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
1557
+ model = models.UploadIvrAudioRequest()
1558
+ model.from_json_string(json.dumps(args))
1559
+ start_time = time.time()
1560
+ while True:
1561
+ rsp = client.UploadIvrAudio(model)
1562
+ result = rsp.to_json_string()
1563
+ try:
1564
+ json_obj = json.loads(result)
1565
+ except TypeError as e:
1566
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
1567
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
1568
+ break
1569
+ cur_time = time.time()
1570
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
1571
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
1572
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
1573
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
1574
+ else:
1575
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
1576
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
1577
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
1578
+
1579
+
1476
1580
  def doDescribeActiveCarrierPrivilegeNumber(args, parsed_globals):
1477
1581
  g_param = parse_global_arg(parsed_globals)
1478
1582
 
@@ -2847,6 +2951,7 @@ ACTION_MAP = {
2847
2951
  "BindStaffSkillGroupList": doBindStaffSkillGroupList,
2848
2952
  "BindNumberCallOutSkillGroup": doBindNumberCallOutSkillGroup,
2849
2953
  "DescribeIMCdrs": doDescribeIMCdrs,
2954
+ "CreatePredictiveDialingCampaign": doCreatePredictiveDialingCampaign,
2850
2955
  "DeleteStaff": doDeleteStaff,
2851
2956
  "ModifyStaff": doModifyStaff,
2852
2957
  "CreateExtension": doCreateExtension,
@@ -2862,8 +2967,9 @@ ACTION_MAP = {
2862
2967
  "ResumePredictiveDialingCampaign": doResumePredictiveDialingCampaign,
2863
2968
  "DescribeSkillGroupInfoList": doDescribeSkillGroupInfoList,
2864
2969
  "StopAutoCalloutTask": doStopAutoCalloutTask,
2865
- "CreatePredictiveDialingCampaign": doCreatePredictiveDialingCampaign,
2970
+ "DescribeIvrAudioList": doDescribeIvrAudioList,
2866
2971
  "CreateCarrierPrivilegeNumberApplicant": doCreateCarrierPrivilegeNumberApplicant,
2972
+ "UploadIvrAudio": doUploadIvrAudio,
2867
2973
  "DescribeActiveCarrierPrivilegeNumber": doDescribeActiveCarrierPrivilegeNumber,
2868
2974
  "DescribeChatMessages": doDescribeChatMessages,
2869
2975
  "DescribeCCCBuyInfoList": doDescribeCCCBuyInfoList,
@@ -203,6 +203,13 @@
203
203
  "output": "DescribeIMCdrsResponse",
204
204
  "status": "online"
205
205
  },
206
+ "DescribeIvrAudioList": {
207
+ "document": "查询IVR音频文件列表信息",
208
+ "input": "DescribeIvrAudioListRequest",
209
+ "name": "查询IVR音频文件列表",
210
+ "output": "DescribeIvrAudioListResponse",
211
+ "status": "online"
212
+ },
206
213
  "DescribeNumbers": {
207
214
  "document": "查询号码列表",
208
215
  "input": "DescribeNumbersRequest",
@@ -377,6 +384,13 @@
377
384
  "name": "更新预测式外呼任务",
378
385
  "output": "UpdatePredictiveDialingCampaignResponse",
379
386
  "status": "online"
387
+ },
388
+ "UploadIvrAudio": {
389
+ "document": "上传IVR中使用的音频文件,每日上传文件限制50个。(参数中音频文件Url建议使用腾讯云Cos存储的临时链接)",
390
+ "input": "UploadIvrAudioRequest",
391
+ "name": "上传IVR音频文件",
392
+ "output": "UploadIvrAudioResponse",
393
+ "status": "online"
380
394
  }
381
395
  },
382
396
  "metadata": {
@@ -468,6 +482,52 @@
468
482
  ],
469
483
  "usage": "out"
470
484
  },
485
+ "AudioFileInfo": {
486
+ "document": "音频文件审核信息",
487
+ "members": [
488
+ {
489
+ "disabled": false,
490
+ "document": "文件ID\n注意:此字段可能返回 null,表示取不到有效值。",
491
+ "example": "1",
492
+ "member": "uint64",
493
+ "name": "FileId",
494
+ "output_required": false,
495
+ "type": "int",
496
+ "value_allowed_null": true
497
+ },
498
+ {
499
+ "disabled": false,
500
+ "document": "文件别名\n注意:此字段可能返回 null,表示取不到有效值。",
501
+ "example": "欢迎",
502
+ "member": "string",
503
+ "name": "CustomFileName",
504
+ "output_required": false,
505
+ "type": "string",
506
+ "value_allowed_null": true
507
+ },
508
+ {
509
+ "disabled": false,
510
+ "document": "文件名\n注意:此字段可能返回 null,表示取不到有效值。",
511
+ "example": "xxx.mp3",
512
+ "member": "string",
513
+ "name": "AudioFileName",
514
+ "output_required": false,
515
+ "type": "string",
516
+ "value_allowed_null": true
517
+ },
518
+ {
519
+ "disabled": false,
520
+ "document": "审核状态,0-未审核,1-审核通过,2-审核拒绝\n注意:此字段可能返回 null,表示取不到有效值。",
521
+ "example": "1",
522
+ "member": "int64",
523
+ "name": "Status",
524
+ "output_required": false,
525
+ "type": "int",
526
+ "value_allowed_null": true
527
+ }
528
+ ],
529
+ "usage": "out"
530
+ },
471
531
  "AutoCalloutTaskCalleeInfo": {
472
532
  "document": "外呼任务被叫信息",
473
533
  "members": [
@@ -3283,6 +3343,98 @@
3283
3343
  ],
3284
3344
  "type": "object"
3285
3345
  },
3346
+ "DescribeIvrAudioListRequest": {
3347
+ "document": "DescribeIvrAudioList请求参数结构体",
3348
+ "members": [
3349
+ {
3350
+ "disabled": false,
3351
+ "document": "应用 ID(必填),可以查看 https://console.cloud.tencent.com/ccc",
3352
+ "example": "1600000001",
3353
+ "member": "int64",
3354
+ "name": "SdkAppId",
3355
+ "required": true,
3356
+ "type": "int"
3357
+ },
3358
+ {
3359
+ "disabled": false,
3360
+ "document": "分页尺寸,上限 50",
3361
+ "example": "10",
3362
+ "member": "uint64",
3363
+ "name": "PageSize",
3364
+ "required": true,
3365
+ "type": "int"
3366
+ },
3367
+ {
3368
+ "disabled": false,
3369
+ "document": "分页页码,从 0 开始",
3370
+ "example": "0",
3371
+ "member": "uint64",
3372
+ "name": "PageNumber",
3373
+ "required": true,
3374
+ "type": "int"
3375
+ },
3376
+ {
3377
+ "disabled": false,
3378
+ "document": "文件别名",
3379
+ "example": "欢迎",
3380
+ "member": "string",
3381
+ "name": "CustomFileName",
3382
+ "required": false,
3383
+ "type": "list"
3384
+ },
3385
+ {
3386
+ "disabled": false,
3387
+ "document": "文件名",
3388
+ "example": "aaa.mp3",
3389
+ "member": "string",
3390
+ "name": "AudioFileName",
3391
+ "required": false,
3392
+ "type": "list"
3393
+ },
3394
+ {
3395
+ "disabled": false,
3396
+ "document": "文件ID",
3397
+ "example": "12",
3398
+ "member": "uint64",
3399
+ "name": "FileId",
3400
+ "required": false,
3401
+ "type": "list"
3402
+ }
3403
+ ],
3404
+ "type": "object"
3405
+ },
3406
+ "DescribeIvrAudioListResponse": {
3407
+ "document": "DescribeIvrAudioList返回参数结构体",
3408
+ "members": [
3409
+ {
3410
+ "disabled": false,
3411
+ "document": "总数",
3412
+ "example": "0",
3413
+ "member": "int64",
3414
+ "name": "TotalCount",
3415
+ "output_required": true,
3416
+ "type": "int",
3417
+ "value_allowed_null": false
3418
+ },
3419
+ {
3420
+ "disabled": false,
3421
+ "document": "文件信息",
3422
+ "example": "无",
3423
+ "member": "AudioFileInfo",
3424
+ "name": "FileInfo",
3425
+ "output_required": false,
3426
+ "type": "list",
3427
+ "value_allowed_null": false
3428
+ },
3429
+ {
3430
+ "document": "唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。",
3431
+ "member": "string",
3432
+ "name": "RequestId",
3433
+ "type": "string"
3434
+ }
3435
+ ],
3436
+ "type": "object"
3437
+ },
3286
3438
  "DescribeNumbersRequest": {
3287
3439
  "document": "DescribeNumbers请求参数结构体",
3288
3440
  "members": [
@@ -7223,6 +7375,102 @@
7223
7375
  ],
7224
7376
  "type": "object"
7225
7377
  },
7378
+ "UploadAudioInfo": {
7379
+ "document": "上传音频文件信息",
7380
+ "members": [
7381
+ {
7382
+ "disabled": false,
7383
+ "document": "文件别名(可重复)",
7384
+ "example": "呼入使用",
7385
+ "member": "string",
7386
+ "name": "CustomFileName",
7387
+ "required": true,
7388
+ "type": "string"
7389
+ },
7390
+ {
7391
+ "disabled": false,
7392
+ "document": "音频文件链接。(支持mp3和wav格式,文件不超过5MB)",
7393
+ "example": "http://xxx.com/aa.mp3",
7394
+ "member": "string",
7395
+ "name": "AudioUrl",
7396
+ "required": true,
7397
+ "type": "string"
7398
+ }
7399
+ ],
7400
+ "usage": "in"
7401
+ },
7402
+ "UploadIvrAudioFailedInfo": {
7403
+ "document": "上传音频文件失败信息",
7404
+ "members": [
7405
+ {
7406
+ "disabled": false,
7407
+ "document": "文件名\n注意:此字段可能返回 null,表示取不到有效值。",
7408
+ "example": "xxx.mp3",
7409
+ "member": "string",
7410
+ "name": "FileName",
7411
+ "output_required": false,
7412
+ "type": "string",
7413
+ "value_allowed_null": true
7414
+ },
7415
+ {
7416
+ "disabled": false,
7417
+ "document": "失败原因\n注意:此字段可能返回 null,表示取不到有效值。",
7418
+ "example": "文件内容重复",
7419
+ "member": "string",
7420
+ "name": "FailedMsg",
7421
+ "output_required": false,
7422
+ "type": "string",
7423
+ "value_allowed_null": true
7424
+ }
7425
+ ],
7426
+ "usage": "out"
7427
+ },
7428
+ "UploadIvrAudioRequest": {
7429
+ "document": "UploadIvrAudio请求参数结构体",
7430
+ "members": [
7431
+ {
7432
+ "disabled": false,
7433
+ "document": "应用 ID(必填),可以查看 https://console.cloud.tencent.com/ccc",
7434
+ "example": "1600000001",
7435
+ "member": "int64",
7436
+ "name": "SdkAppId",
7437
+ "required": true,
7438
+ "type": "int"
7439
+ },
7440
+ {
7441
+ "disabled": false,
7442
+ "document": "音频文件列表",
7443
+ "example": "无",
7444
+ "member": "UploadAudioInfo",
7445
+ "name": "AudioList",
7446
+ "required": true,
7447
+ "type": "list"
7448
+ }
7449
+ ],
7450
+ "type": "object"
7451
+ },
7452
+ "UploadIvrAudioResponse": {
7453
+ "document": "UploadIvrAudio返回参数结构体",
7454
+ "members": [
7455
+ {
7456
+ "disabled": false,
7457
+ "document": "上传失败的文件列表\n注意:此字段可能返回 null,表示取不到有效值。",
7458
+ "example": "无",
7459
+ "member": "UploadIvrAudioFailedInfo",
7460
+ "name": "FailedFileList",
7461
+ "output_required": false,
7462
+ "type": "list",
7463
+ "value_allowed_null": true
7464
+ },
7465
+ {
7466
+ "document": "唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。",
7467
+ "member": "string",
7468
+ "name": "RequestId",
7469
+ "type": "string"
7470
+ }
7471
+ ],
7472
+ "type": "object"
7473
+ },
7226
7474
  "Variable": {
7227
7475
  "document": "变量",
7228
7476
  "members": [
@@ -232,6 +232,14 @@
232
232
  "title": "查询在线客服记录示例"
233
233
  }
234
234
  ],
235
+ "DescribeIvrAudioList": [
236
+ {
237
+ "document": "",
238
+ "input": "POST / HTTP/1.1\nHost: ccc.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: DescribeIvrAudioList\n<公共请求参数>\n\n{\n \"SdkAppId\": 160000000,\n \"CustomFileName\": [\n \"abc\"\n ],\n \"AudioFileName\": [],\n \"FileId\": [],\n \"PageSize\": 1,\n \"PageNumber\": 0\n}",
239
+ "output": "{\n \"Response\": {\n \"TotalCount\": 1,\n \"FileInfo\": [\n {\n \"FileId\": 1,\n \"CustomFileName\": \"abc\",\n \"AudioFileName\": \"a.mp3\",\n \"Status\": 0\n }\n ],\n \"RequestId\": \"abc\"\n }\n}",
240
+ "title": "查询IVR音频文件列表示例"
241
+ }
242
+ ],
235
243
  "DescribeNumbers": [
236
244
  {
237
245
  "document": "查询号码列表",
@@ -431,6 +439,14 @@
431
439
  "output": "{\n \"Response\": {\n \"RequestId\": \"3c140219-cfe9-470e-b241-907877d6fb03\"\n }\n}",
432
440
  "title": "更新预测式外呼任务示例"
433
441
  }
442
+ ],
443
+ "UploadIvrAudio": [
444
+ {
445
+ "document": "",
446
+ "input": "POST / HTTP/1.1\nHost: ccc.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: UploadIvrAudio\n<公共请求参数>\n\n{\n \"SdkAppId\": 0,\n \"AudioList\": [\n {\n \"CustomFileName\": \"abc\",\n \"AudioUrl\": \"http://xxxx.com/a.mp3\"\n }\n ]\n}",
447
+ "output": "{\n \"Response\": {\n \"RequestId\": \"abc\"\n }\n}",
448
+ "title": "上传IVR音频文件"
449
+ }
434
450
  ]
435
451
  },
436
452
  "version": "1.0"
@@ -1005,6 +1005,58 @@ def doModifyRiskCenterScanTask(args, parsed_globals):
1005
1005
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
1006
1006
 
1007
1007
 
1008
+ def doDescribeAssetViewVulRiskList(args, parsed_globals):
1009
+ g_param = parse_global_arg(parsed_globals)
1010
+
1011
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
1012
+ cred = credential.CVMRoleCredential()
1013
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
1014
+ cred = credential.STSAssumeRoleCredential(
1015
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
1016
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
1017
+ )
1018
+ 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):
1019
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
1020
+ else:
1021
+ cred = credential.Credential(
1022
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
1023
+ )
1024
+ http_profile = HttpProfile(
1025
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
1026
+ reqMethod="POST",
1027
+ endpoint=g_param[OptionsDefine.Endpoint],
1028
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
1029
+ )
1030
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
1031
+ if g_param[OptionsDefine.Language]:
1032
+ profile.language = g_param[OptionsDefine.Language]
1033
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
1034
+ client = mod.CsipClient(cred, g_param[OptionsDefine.Region], profile)
1035
+ client._sdkVersion += ("_CLI_" + __version__)
1036
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
1037
+ model = models.DescribeAssetViewVulRiskListRequest()
1038
+ model.from_json_string(json.dumps(args))
1039
+ start_time = time.time()
1040
+ while True:
1041
+ rsp = client.DescribeAssetViewVulRiskList(model)
1042
+ result = rsp.to_json_string()
1043
+ try:
1044
+ json_obj = json.loads(result)
1045
+ except TypeError as e:
1046
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
1047
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
1048
+ break
1049
+ cur_time = time.time()
1050
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
1051
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
1052
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
1053
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
1054
+ else:
1055
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
1056
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
1057
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
1058
+
1059
+
1008
1060
  def doDescribeRiskCenterWebsiteRiskList(args, parsed_globals):
1009
1061
  g_param = parse_global_arg(parsed_globals)
1010
1062
 
@@ -1971,6 +2023,7 @@ ACTION_MAP = {
1971
2023
  "DescribeRiskCenterServerRiskList": doDescribeRiskCenterServerRiskList,
1972
2024
  "DescribeCVMAssets": doDescribeCVMAssets,
1973
2025
  "ModifyRiskCenterScanTask": doModifyRiskCenterScanTask,
2026
+ "DescribeAssetViewVulRiskList": doDescribeAssetViewVulRiskList,
1974
2027
  "DescribeRiskCenterWebsiteRiskList": doDescribeRiskCenterWebsiteRiskList,
1975
2028
  "StopRiskCenterTask": doStopRiskCenterTask,
1976
2029
  "CreateRiskCenterScanTask": doCreateRiskCenterScanTask,