tccli 3.0.1129.1__py2.py3-none-any.whl → 3.0.1130.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 (34) hide show
  1. tccli/__init__.py +1 -1
  2. tccli/services/asr/v20190614/api.json +1 -1
  3. tccli/services/ciam/v20220331/api.json +92 -104
  4. tccli/services/cls/v20201016/api.json +5 -5
  5. tccli/services/ess/v20201111/api.json +5 -5
  6. tccli/services/essbasic/v20210526/api.json +10 -1
  7. tccli/services/essbasic/v20210526/examples.json +1 -1
  8. tccli/services/redis/redis_client.py +220 -8
  9. tccli/services/redis/v20180412/api.json +220 -0
  10. tccli/services/redis/v20180412/examples.json +32 -0
  11. tccli/services/ssl/v20191205/api.json +63 -38
  12. tccli/services/ssl/v20191205/examples.json +1 -1
  13. tccli/services/tcm/v20210413/api.json +75 -22
  14. tccli/services/tcm/v20210413/examples.json +1 -1
  15. tccli/services/tcr/v20190924/api.json +8 -8
  16. tccli/services/tcr/v20190924/examples.json +1 -1
  17. tccli/services/tdmq/v20200217/api.json +23 -10
  18. tccli/services/tdmq/v20200217/examples.json +3 -3
  19. tccli/services/tke/v20180525/api.json +31 -25
  20. tccli/services/tke/v20180525/examples.json +9 -9
  21. tccli/services/trtc/v20190722/api.json +2 -2
  22. tccli/services/tse/v20201207/api.json +103 -0
  23. tccli/services/tts/v20190823/api.json +1 -1
  24. tccli/services/waf/v20180125/api.json +109 -0
  25. tccli/services/waf/v20180125/examples.json +14 -0
  26. tccli/services/waf/waf_client.py +61 -8
  27. tccli/services/wedata/v20210820/api.json +71 -0
  28. tccli/services/wedata/v20210820/examples.json +8 -0
  29. tccli/services/wedata/wedata_client.py +53 -0
  30. {tccli-3.0.1129.1.dist-info → tccli-3.0.1130.1.dist-info}/METADATA +2 -2
  31. {tccli-3.0.1129.1.dist-info → tccli-3.0.1130.1.dist-info}/RECORD +34 -34
  32. {tccli-3.0.1129.1.dist-info → tccli-3.0.1130.1.dist-info}/WHEEL +0 -0
  33. {tccli-3.0.1129.1.dist-info → tccli-3.0.1130.1.dist-info}/entry_points.txt +0 -0
  34. {tccli-3.0.1129.1.dist-info → tccli-3.0.1130.1.dist-info}/license_files/LICENSE +0 -0
@@ -442,7 +442,7 @@
442
442
  "status": "online"
443
443
  },
444
444
  "DescribePartitions": {
445
- "document": "本接口用于获取主题分区列表。",
445
+ "document": "该接口已废弃,如需获取分区数量,请使用DescribeTopics接口。",
446
446
  "input": "DescribePartitionsRequest",
447
447
  "name": "获取分区列表",
448
448
  "output": "DescribePartitionsResponse",
@@ -484,7 +484,7 @@
484
484
  "status": "online"
485
485
  },
486
486
  "MergePartition": {
487
- "document": "本接口用于合并一个读写态的主题分区,合并时指定一个主题分区 ID,日志服务会自动合并范围右相邻的分区。",
487
+ "document": "该接口已废弃,如需修改分区数量,请使用ModifyTopic接口。",
488
488
  "input": "MergePartitionRequest",
489
489
  "name": "合并分区",
490
490
  "output": "MergePartitionResponse",
@@ -666,7 +666,7 @@
666
666
  "status": "online"
667
667
  },
668
668
  "SplitPartition": {
669
- "document": "本接口用于分裂主题分区",
669
+ "document": "该接口已废弃,如需修改分区数量,请使用ModifyTopic接口。",
670
670
  "input": "SplitPartitionRequest",
671
671
  "name": "分裂主题分区",
672
672
  "output": "SplitPartitionResponse",
@@ -7368,7 +7368,7 @@
7368
7368
  "example": "无",
7369
7369
  "member": "PartitionInfo",
7370
7370
  "name": "Partitions",
7371
- "required": true,
7371
+ "output_required": true,
7372
7372
  "type": "list",
7373
7373
  "value_allowed_null": false
7374
7374
  },
@@ -13402,7 +13402,7 @@
13402
13402
  "example": "无",
13403
13403
  "member": "PartitionInfo",
13404
13404
  "name": "Partitions",
13405
- "required": true,
13405
+ "output_required": true,
13406
13406
  "type": "list",
13407
13407
  "value_allowed_null": false
13408
13408
  },
@@ -190,7 +190,7 @@
190
190
  "status": "online"
191
191
  },
192
192
  "CreateMultiFlowSignQRCode": {
193
- "document": "此接口(CreateMultiFlowSignQRCode)用于创建一码多签签署码。\n\n**适用场景**:\n签署人可通过扫描二维码补充签署信息进行实名签署。常用于提前不知道签署人的身份信息场景,例如:劳务工招工、大批量员工入职等场景。\n\n**注意**:\n1. 本接口适用于**发起方没有填写控件的 B2C或者单C模板**, 若是B2C模板,还要满足以下任意一个条件\n - 模板中配置的签署顺序是无序\n - B端企业的签署方式是静默签署\n - B端企业是非首位签署\n2. 通过一码多签签署码发起的合同,合同涉及到的回调消息可参考文档[合同发起及签署相关回调\n]( https://qian.tencent.com/developers/company/callback_types_contracts_sign)\n3. 用户通过一码多签签署码发起合同时,因企业额度不足导致失败 会触发签署二维码相关回调,具体参考文档[签署二维码相关回调](https://qian.tencent.com/developers/company/callback_types_commons#%E7%AD%BE%E7%BD%B2%E4%BA%8C%E7%BB%B4%E7%A0%81%E7%9B%B8%E5%85%B3%E5%9B%9E%E8%B0%83)\n\n签署码的样式如下图:\n![image](https://qcloudimg.tencent-cloud.cn/raw/27317cf5aacb094fb1dc6f94179a5148.png )",
193
+ "document": "此接口(CreateMultiFlowSignQRCode)用于创建一码多签签署码。\n\n**适用场景**:\n签署人可通过扫描二维码补充签署信息进行实名签署。常用于提前不知道签署人的身份信息场景,例如:劳务工招工、大批量员工入职等场景。\n\n**注意**:\n1. 本接口适用于**发起方没有填写控件的 B2C或者单C模板**, 若是B2C模板,还要满足以下任意一个条件\n - 模板中配置的签署顺序是无序\n - B端企业的签署方式是静默签署\n - B端企业是非首位签署\n2. 通过一码多签签署码发起的合同,合同涉及到的回调消息可参考文档[合同发起及签署相关回调\n]( https://qian.tencent.com/developers/company/callback_types_contracts_sign)\n3. 用户通过一码多签签署码发起合同时,因企业额度不足导致失败 会触发签署二维码相关回调,具体参考文档[签署二维码相关回调](https://qian.tencent.com/developers/company/callback_types_commons#%E7%AD%BE%E7%BD%B2%E4%BA%8C%E7%BB%B4%E7%A0%81%E7%9B%B8%E5%85%B3%E5%9B%9E%E8%B0%83)\n\n签署码的样式如下图:\n\n![image](https://qcloudimg.tencent-cloud.cn/raw/27317cf5aacb094fb1dc6f94179a5148.png )",
194
194
  "input": "CreateMultiFlowSignQRCodeRequest",
195
195
  "name": "创建一码多签签署码",
196
196
  "output": "CreateMultiFlowSignQRCodeResponse",
@@ -2463,7 +2463,7 @@
2463
2463
  },
2464
2464
  {
2465
2465
  "disabled": false,
2466
- "document": "执行本接口操作的员工信息。\n注: `在调用此接口时,请确保指定的员工已获得所需的接口调用权限,并具备接口传入的相应资源的数据权限。",
2466
+ "document": "执行本接口操作的员工信息。\n注: `在调用此接口时,请确保指定的员工已获得所需的接口调用权限,并具备接口传入的相应资源的数据权限。`",
2467
2467
  "example": "无",
2468
2468
  "member": "UserInfo",
2469
2469
  "name": "Operator",
@@ -5672,7 +5672,7 @@
5672
5672
  },
5673
5673
  {
5674
5674
  "disabled": false,
5675
- "document": "要跳转到的页面类型 \n\n<ul><li> **0** : 腾讯电子签小程序个人首页 (默认)</li>\n<li> **1** : 腾讯电子签小程序流程合同的详情页 (即合同签署页面)</li>\n<li> **2** : 腾讯电子签小程序合同列表页</li><li> **3** : 腾讯电子签小程序合同封面页\n注:`生成动态签署人补充链接时,必须指定为封面页`</li></ul>",
5675
+ "document": "要跳转到的页面类型 \n\n<ul><li> **0** : 腾讯电子签小程序个人首页 (默认) <a href=\"https://qcloudimg.tencent-cloud.cn/raw/a2667ea84ec993cc060321afe3191d65.jpg\" target=\"_blank\" >点击查看示例页面</a></li>\n<li> **1** : 腾讯电子签小程序流程合同的详情页 (即合同签署页面)<a href=\"https://qcloudimg.tencent-cloud.cn/raw/446a679f09b1b7f40eb84e67face8acc.jpg\" target=\"_blank\" >点击查看示例页面</a></li>\n<li> **2** : 腾讯电子签小程序合同列表页 <a href=\"https://qcloudimg.tencent-cloud.cn/raw/c7b80e44c1d68ae3270a6fc4939c7214.jpg\" target=\"_blank\" >点击查看示例页面</a> </li>\n<li> **3** : 腾讯电子签小程序合同封面页 (注:`生成动态签署人补充链接时,必须指定为封面页`)<a href=\"https://qcloudimg.tencent-cloud.cn/raw/0d22cc587be4bf084877c151350c3bf7.jpg\" target=\"_blank\" >点击查看示例页面</a></li></ul>",
5676
5676
  "example": "1",
5677
5677
  "member": "uint64",
5678
5678
  "name": "PathType",
@@ -5999,7 +5999,7 @@
5999
5999
  },
6000
6000
  {
6001
6001
  "disabled": false,
6002
- "document": "企业税号\n注: `1.印章类型SealType是INVOICE类型时,此参数才会生效`\n`2.印章类型SealType是INVOICE类型,且该字段没有传入值或传入空时,会取该企业对应的统一社会信用代码作为默认的企业税号`",
6002
+ "document": "企业税号\n注:\n<ul>\n<li>1.印章类型SealType是INVOICE类型时,此参数才会生效</li>\n<li>2.印章类型SealType是INVOICE类型,且该字段没有传入值或传入空时,会取该企业对应的统一社会信用代码作为默认的企业税号(<font color=\"red\">如果是通过授权书授权方式认证的企业,此参数必传不能为空</font>)</li>\n</ul>",
6003
6003
  "example": "无",
6004
6004
  "member": "string",
6005
6005
  "name": "TaxIdentifyCode",
@@ -10431,7 +10431,7 @@
10431
10431
  },
10432
10432
  {
10433
10433
  "disabled": false,
10434
- "document": "执行本接口操作的员工信息。\n注: `在调用此接口时,请确保指定的员工已获得所需的接口调用权限,并具备接口传入的相应资源的数据权限。",
10434
+ "document": "执行本接口操作的员工信息。\n注: `在调用此接口时,请确保指定的员工已获得所需的接口调用权限,并具备接口传入的相应资源的数据权限。`",
10435
10435
  "example": "无",
10436
10436
  "member": "UserInfo",
10437
10437
  "name": "Operator",
@@ -6501,6 +6501,15 @@
6501
6501
  "name": "PlatformAppAuthorization",
6502
6502
  "required": false,
6503
6503
  "type": "bool"
6504
+ },
6505
+ {
6506
+ "disabled": false,
6507
+ "document": "指定印章类型,指定后只能选择该类型的印章进行授权\n支持以下印章类型:\n- OFFICIAL : 企业公章\n- CONTRACT : 合同专用章\n- FINANCE : 财务专用章\n- PERSONNEL : 人事专用章",
6508
+ "example": "无",
6509
+ "member": "string",
6510
+ "name": "SealTypes",
6511
+ "required": false,
6512
+ "type": "list"
6504
6513
  }
6505
6514
  ],
6506
6515
  "type": "object"
@@ -6633,7 +6642,7 @@
6633
6642
  },
6634
6643
  {
6635
6644
  "disabled": false,
6636
- "document": "企业税号\n注: `1.印章类型SealType是INVOICE类型时,此参数才会生效`\n`2.印章类型SealType是INVOICE类型,且该字段没有传入值或传入空时,会取该企业对应的统一社会信用代码作为默认的企业税号`",
6645
+ "document": "企业税号\n\n注:\n<ul>\n<li>1.印章类型SealType是INVOICE类型时,此参数才会生效</li>\n<li>2.印章类型SealType是INVOICE类型,且该字段没有传入值或传入空时,会取该企业对应的统一社会信用代码作为默认的企业税号(<font color=\"red\">如果是通过授权书授权方式认证的企业,此参数必传不能为空</font>)</li>\n</ul>",
6637
6646
  "example": "无",
6638
6647
  "member": "string",
6639
6648
  "name": "TaxIdentifyCode",
@@ -795,7 +795,7 @@
795
795
  },
796
796
  {
797
797
  "document": "",
798
- "input": "POST / HTTP/1.1\nHost: essbasic.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: CreatePartnerAutoSignAuthUrl\n<公共请求参数>\n\n{\n \"Agent\": {\n \"AppId\": \"yDSxxxxxxxxxOnHtH51\",\n \"ProxyOrganizationOpenId\": \"org_open_id\",\n \"ProxyOperator\": {\n \"OpenId\": \"user_open_id\"\n }\n },\n \"AuthorizedOrganizationId\": \"org_open_id_another\",\n \"AuthorizedOrganizationName\": \"典子谦子客企业\"\n}",
798
+ "input": "POST / HTTP/1.1\nHost: essbasic.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: CreatePartnerAutoSignAuthUrl\n<公共请求参数>\n\n{\n \"Agent\": {\n \"AppId\": \"yDSxxxxxxxxxOnHtH51\",\n \"ProxyOrganizationOpenId\": \"org_open_id\",\n \"ProxyOperator\": {\n \"OpenId\": \"user_open_id\"\n }\n },\n \"AuthorizedOrganizationId\": \"org_open_id_another\",\n \"AuthorizedOrganizationName\": \"典子谦子客企业\",\n \"SealTypes\": [\n \"OFFICIAL\"\n ]\n}",
799
799
  "output": "{\n \"Response\": {\n \"ExpireTime\": 1702982931,\n \"MiniAppPath\": \"/pages/guide/index?shortKey=yDSxxxxxxxxxOnHtH51\",\n \"RequestId\": \"s1702378131281988373\",\n \"Url\": \"https://test.essurl.cn/WxxxxxwH\"\n }\n}",
800
800
  "title": "创建他方自动签授权链接"
801
801
  }
@@ -225,7 +225,7 @@ def doDeleteReplicationInstance(args, parsed_globals):
225
225
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
226
226
 
227
227
 
228
- def doCleanUpInstance(args, parsed_globals):
228
+ def doDescribeGlobalReplicationArea(args, parsed_globals):
229
229
  g_param = parse_global_arg(parsed_globals)
230
230
 
231
231
  if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
@@ -254,11 +254,11 @@ def doCleanUpInstance(args, parsed_globals):
254
254
  client = mod.RedisClient(cred, g_param[OptionsDefine.Region], profile)
255
255
  client._sdkVersion += ("_CLI_" + __version__)
256
256
  models = MODELS_MAP[g_param[OptionsDefine.Version]]
257
- model = models.CleanUpInstanceRequest()
257
+ model = models.DescribeGlobalReplicationAreaRequest()
258
258
  model.from_json_string(json.dumps(args))
259
259
  start_time = time.time()
260
260
  while True:
261
- rsp = client.CleanUpInstance(model)
261
+ rsp = client.DescribeGlobalReplicationArea(model)
262
262
  result = rsp.to_json_string()
263
263
  try:
264
264
  json_obj = json.loads(result)
@@ -901,6 +901,58 @@ def doUpgradeVersionToMultiAvailabilityZones(args, parsed_globals):
901
901
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
902
902
 
903
903
 
904
+ def doCleanUpInstance(args, parsed_globals):
905
+ g_param = parse_global_arg(parsed_globals)
906
+
907
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
908
+ cred = credential.CVMRoleCredential()
909
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
910
+ cred = credential.STSAssumeRoleCredential(
911
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
912
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
913
+ )
914
+ 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):
915
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
916
+ else:
917
+ cred = credential.Credential(
918
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
919
+ )
920
+ http_profile = HttpProfile(
921
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
922
+ reqMethod="POST",
923
+ endpoint=g_param[OptionsDefine.Endpoint],
924
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
925
+ )
926
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
927
+ if g_param[OptionsDefine.Language]:
928
+ profile.language = g_param[OptionsDefine.Language]
929
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
930
+ client = mod.RedisClient(cred, g_param[OptionsDefine.Region], profile)
931
+ client._sdkVersion += ("_CLI_" + __version__)
932
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
933
+ model = models.CleanUpInstanceRequest()
934
+ model.from_json_string(json.dumps(args))
935
+ start_time = time.time()
936
+ while True:
937
+ rsp = client.CleanUpInstance(model)
938
+ result = rsp.to_json_string()
939
+ try:
940
+ json_obj = json.loads(result)
941
+ except TypeError as e:
942
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
943
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
944
+ break
945
+ cur_time = time.time()
946
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
947
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
948
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
949
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
950
+ else:
951
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
952
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
953
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
954
+
955
+
904
956
  def doModifyInstanceParams(args, parsed_globals):
905
957
  g_param = parse_global_arg(parsed_globals)
906
958
 
@@ -2253,6 +2305,58 @@ def doInquiryPriceCreateInstance(args, parsed_globals):
2253
2305
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
2254
2306
 
2255
2307
 
2308
+ def doModifyReplicationGroup(args, parsed_globals):
2309
+ g_param = parse_global_arg(parsed_globals)
2310
+
2311
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
2312
+ cred = credential.CVMRoleCredential()
2313
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
2314
+ cred = credential.STSAssumeRoleCredential(
2315
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
2316
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
2317
+ )
2318
+ 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):
2319
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
2320
+ else:
2321
+ cred = credential.Credential(
2322
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
2323
+ )
2324
+ http_profile = HttpProfile(
2325
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
2326
+ reqMethod="POST",
2327
+ endpoint=g_param[OptionsDefine.Endpoint],
2328
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
2329
+ )
2330
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
2331
+ if g_param[OptionsDefine.Language]:
2332
+ profile.language = g_param[OptionsDefine.Language]
2333
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
2334
+ client = mod.RedisClient(cred, g_param[OptionsDefine.Region], profile)
2335
+ client._sdkVersion += ("_CLI_" + __version__)
2336
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
2337
+ model = models.ModifyReplicationGroupRequest()
2338
+ model.from_json_string(json.dumps(args))
2339
+ start_time = time.time()
2340
+ while True:
2341
+ rsp = client.ModifyReplicationGroup(model)
2342
+ result = rsp.to_json_string()
2343
+ try:
2344
+ json_obj = json.loads(result)
2345
+ except TypeError as e:
2346
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
2347
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
2348
+ break
2349
+ cur_time = time.time()
2350
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
2351
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
2352
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
2353
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
2354
+ else:
2355
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
2356
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
2357
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
2358
+
2359
+
2256
2360
  def doDescribeInstanceSupportFeature(args, parsed_globals):
2257
2361
  g_param = parse_global_arg(parsed_globals)
2258
2362
 
@@ -2565,6 +2669,58 @@ def doManualBackupInstance(args, parsed_globals):
2565
2669
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
2566
2670
 
2567
2671
 
2672
+ def doDescribeInstanceSpecBandwidth(args, parsed_globals):
2673
+ g_param = parse_global_arg(parsed_globals)
2674
+
2675
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
2676
+ cred = credential.CVMRoleCredential()
2677
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
2678
+ cred = credential.STSAssumeRoleCredential(
2679
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
2680
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
2681
+ )
2682
+ 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):
2683
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
2684
+ else:
2685
+ cred = credential.Credential(
2686
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
2687
+ )
2688
+ http_profile = HttpProfile(
2689
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
2690
+ reqMethod="POST",
2691
+ endpoint=g_param[OptionsDefine.Endpoint],
2692
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
2693
+ )
2694
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
2695
+ if g_param[OptionsDefine.Language]:
2696
+ profile.language = g_param[OptionsDefine.Language]
2697
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
2698
+ client = mod.RedisClient(cred, g_param[OptionsDefine.Region], profile)
2699
+ client._sdkVersion += ("_CLI_" + __version__)
2700
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
2701
+ model = models.DescribeInstanceSpecBandwidthRequest()
2702
+ model.from_json_string(json.dumps(args))
2703
+ start_time = time.time()
2704
+ while True:
2705
+ rsp = client.DescribeInstanceSpecBandwidth(model)
2706
+ result = rsp.to_json_string()
2707
+ try:
2708
+ json_obj = json.loads(result)
2709
+ except TypeError as e:
2710
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
2711
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
2712
+ break
2713
+ cur_time = time.time()
2714
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
2715
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
2716
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
2717
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
2718
+ else:
2719
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
2720
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
2721
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
2722
+
2723
+
2568
2724
  def doSwitchProxy(args, parsed_globals):
2569
2725
  g_param = parse_global_arg(parsed_globals)
2570
2726
 
@@ -4489,7 +4645,7 @@ def doDescribeBandwidthRange(args, parsed_globals):
4489
4645
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
4490
4646
 
4491
4647
 
4492
- def doDescribeInstanceDealDetail(args, parsed_globals):
4648
+ def doDescribeReplicationGroupInstance(args, parsed_globals):
4493
4649
  g_param = parse_global_arg(parsed_globals)
4494
4650
 
4495
4651
  if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
@@ -4518,11 +4674,11 @@ def doDescribeInstanceDealDetail(args, parsed_globals):
4518
4674
  client = mod.RedisClient(cred, g_param[OptionsDefine.Region], profile)
4519
4675
  client._sdkVersion += ("_CLI_" + __version__)
4520
4676
  models = MODELS_MAP[g_param[OptionsDefine.Version]]
4521
- model = models.DescribeInstanceDealDetailRequest()
4677
+ model = models.DescribeReplicationGroupInstanceRequest()
4522
4678
  model.from_json_string(json.dumps(args))
4523
4679
  start_time = time.time()
4524
4680
  while True:
4525
- rsp = client.DescribeInstanceDealDetail(model)
4681
+ rsp = client.DescribeReplicationGroupInstance(model)
4526
4682
  result = rsp.to_json_string()
4527
4683
  try:
4528
4684
  json_obj = json.loads(result)
@@ -4645,6 +4801,58 @@ def doModifyInstanceAvailabilityZones(args, parsed_globals):
4645
4801
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
4646
4802
 
4647
4803
 
4804
+ def doDescribeInstanceDealDetail(args, parsed_globals):
4805
+ g_param = parse_global_arg(parsed_globals)
4806
+
4807
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
4808
+ cred = credential.CVMRoleCredential()
4809
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
4810
+ cred = credential.STSAssumeRoleCredential(
4811
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
4812
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
4813
+ )
4814
+ 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):
4815
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
4816
+ else:
4817
+ cred = credential.Credential(
4818
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
4819
+ )
4820
+ http_profile = HttpProfile(
4821
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
4822
+ reqMethod="POST",
4823
+ endpoint=g_param[OptionsDefine.Endpoint],
4824
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
4825
+ )
4826
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
4827
+ if g_param[OptionsDefine.Language]:
4828
+ profile.language = g_param[OptionsDefine.Language]
4829
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
4830
+ client = mod.RedisClient(cred, g_param[OptionsDefine.Region], profile)
4831
+ client._sdkVersion += ("_CLI_" + __version__)
4832
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
4833
+ model = models.DescribeInstanceDealDetailRequest()
4834
+ model.from_json_string(json.dumps(args))
4835
+ start_time = time.time()
4836
+ while True:
4837
+ rsp = client.DescribeInstanceDealDetail(model)
4838
+ result = rsp.to_json_string()
4839
+ try:
4840
+ json_obj = json.loads(result)
4841
+ except TypeError as e:
4842
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
4843
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
4844
+ break
4845
+ cur_time = time.time()
4846
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
4847
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
4848
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
4849
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
4850
+ else:
4851
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
4852
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
4853
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
4854
+
4855
+
4648
4856
  def doModifyDBInstanceSecurityGroups(args, parsed_globals):
4649
4857
  g_param = parse_global_arg(parsed_globals)
4650
4858
 
@@ -5128,7 +5336,7 @@ ACTION_MAP = {
5128
5336
  "DescribeInstanceMonitorBigKeySizeDist": doDescribeInstanceMonitorBigKeySizeDist,
5129
5337
  "DescribeTaskList": doDescribeTaskList,
5130
5338
  "DeleteReplicationInstance": doDeleteReplicationInstance,
5131
- "CleanUpInstance": doCleanUpInstance,
5339
+ "DescribeGlobalReplicationArea": doDescribeGlobalReplicationArea,
5132
5340
  "DescribeInstanceAccount": doDescribeInstanceAccount,
5133
5341
  "SwitchAccessNewInstance": doSwitchAccessNewInstance,
5134
5342
  "ChangeReplicaToMaster": doChangeReplicaToMaster,
@@ -5141,6 +5349,7 @@ ACTION_MAP = {
5141
5349
  "DescribeInstanceSecurityGroup": doDescribeInstanceSecurityGroup,
5142
5350
  "DescribeBackupDetail": doDescribeBackupDetail,
5143
5351
  "UpgradeVersionToMultiAvailabilityZones": doUpgradeVersionToMultiAvailabilityZones,
5352
+ "CleanUpInstance": doCleanUpInstance,
5144
5353
  "ModifyInstanceParams": doModifyInstanceParams,
5145
5354
  "ClearInstance": doClearInstance,
5146
5355
  "AllocateWanAddress": doAllocateWanAddress,
@@ -5167,12 +5376,14 @@ ACTION_MAP = {
5167
5376
  "DescribeTendisSlowLog": doDescribeTendisSlowLog,
5168
5377
  "ModifyParamTemplate": doModifyParamTemplate,
5169
5378
  "InquiryPriceCreateInstance": doInquiryPriceCreateInstance,
5379
+ "ModifyReplicationGroup": doModifyReplicationGroup,
5170
5380
  "DescribeInstanceSupportFeature": doDescribeInstanceSupportFeature,
5171
5381
  "DescribeInstanceParams": doDescribeInstanceParams,
5172
5382
  "DescribeInstanceMonitorBigKeyTypeDist": doDescribeInstanceMonitorBigKeyTypeDist,
5173
5383
  "ReleaseWanAddress": doReleaseWanAddress,
5174
5384
  "ModifyConnectionConfig": doModifyConnectionConfig,
5175
5385
  "ManualBackupInstance": doManualBackupInstance,
5386
+ "DescribeInstanceSpecBandwidth": doDescribeInstanceSpecBandwidth,
5176
5387
  "SwitchProxy": doSwitchProxy,
5177
5388
  "RestoreInstance": doRestoreInstance,
5178
5389
  "DescribeInstanceParamRecords": doDescribeInstanceParamRecords,
@@ -5210,9 +5421,10 @@ ACTION_MAP = {
5210
5421
  "OpenSSL": doOpenSSL,
5211
5422
  "DescribeAutoBackupConfig": doDescribeAutoBackupConfig,
5212
5423
  "DescribeBandwidthRange": doDescribeBandwidthRange,
5213
- "DescribeInstanceDealDetail": doDescribeInstanceDealDetail,
5424
+ "DescribeReplicationGroupInstance": doDescribeReplicationGroupInstance,
5214
5425
  "DescribeProxySlowLog": doDescribeProxySlowLog,
5215
5426
  "ModifyInstanceAvailabilityZones": doModifyInstanceAvailabilityZones,
5427
+ "DescribeInstanceDealDetail": doDescribeInstanceDealDetail,
5216
5428
  "ModifyDBInstanceSecurityGroups": doModifyDBInstanceSecurityGroups,
5217
5429
  "ChangeMasterInstance": doChangeMasterInstance,
5218
5430
  "UpgradeInstance": doUpgradeInstance,