tccli 3.0.1336.1__py2.py3-none-any.whl → 3.0.1338.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.
Files changed (53) hide show
  1. tccli/__init__.py +1 -1
  2. tccli/services/antiddos/v20200309/api.json +2 -2
  3. tccli/services/asr/v20190614/api.json +1 -1
  4. tccli/services/captcha/v20190722/api.json +10 -0
  5. tccli/services/cdb/v20170320/api.json +1 -1
  6. tccli/services/cdwdoris/v20211228/api.json +4 -4
  7. tccli/services/cfs/v20190719/api.json +6 -3
  8. tccli/services/cfw/v20190904/api.json +9 -0
  9. tccli/services/cls/v20201016/api.json +1 -1
  10. tccli/services/cme/v20191029/api.json +1 -1
  11. tccli/services/csip/v20221121/api.json +10 -0
  12. tccli/services/es/v20250101/api.json +71 -0
  13. tccli/services/ess/ess_client.py +106 -0
  14. tccli/services/ess/v20201111/api.json +179 -1
  15. tccli/services/ess/v20201111/examples.json +16 -0
  16. tccli/services/essbasic/essbasic_client.py +114 -8
  17. tccli/services/essbasic/v20210526/api.json +163 -3
  18. tccli/services/essbasic/v20210526/examples.json +16 -0
  19. tccli/services/gs/v20191118/api.json +11 -1
  20. tccli/services/gs/v20191118/examples.json +1 -1
  21. tccli/services/hunyuan/v20230901/api.json +3 -3
  22. tccli/services/lighthouse/lighthouse_client.py +53 -0
  23. tccli/services/lighthouse/v20200324/api.json +43 -0
  24. tccli/services/lighthouse/v20200324/examples.json +8 -0
  25. tccli/services/live/live_client.py +285 -20
  26. tccli/services/live/v20180801/api.json +549 -0
  27. tccli/services/live/v20180801/examples.json +40 -0
  28. tccli/services/lke/lke_client.py +110 -4
  29. tccli/services/lke/v20231130/api.json +141 -0
  30. tccli/services/lke/v20231130/examples.json +16 -0
  31. tccli/services/lkeap/v20240522/api.json +3 -3
  32. tccli/services/mps/v20190612/api.json +117 -1
  33. tccli/services/ocr/v20181119/examples.json +1 -1
  34. tccli/services/tdmq/v20200217/api.json +165 -25
  35. tccli/services/tdmq/v20200217/examples.json +1 -1
  36. tccli/services/teo/v20220901/api.json +1 -1
  37. tccli/services/tiia/tiia_client.py +73 -126
  38. tccli/services/tiia/v20190529/api.json +0 -112
  39. tccli/services/tiia/v20190529/examples.json +0 -14
  40. tccli/services/tione/tione_client.py +216 -4
  41. tccli/services/tione/v20211111/api.json +190 -0
  42. tccli/services/tione/v20211111/examples.json +32 -0
  43. tccli/services/trocket/trocket_client.py +161 -55
  44. tccli/services/trocket/v20230308/api.json +307 -1
  45. tccli/services/trocket/v20230308/examples.json +16 -0
  46. tccli/services/trtc/v20190722/api.json +2 -2
  47. tccli/services/tsf/v20180326/api.json +2 -2
  48. tccli/services/tsf/v20180326/examples.json +2 -2
  49. {tccli-3.0.1336.1.dist-info → tccli-3.0.1338.1.dist-info}/METADATA +2 -2
  50. {tccli-3.0.1336.1.dist-info → tccli-3.0.1338.1.dist-info}/RECORD +53 -53
  51. {tccli-3.0.1336.1.dist-info → tccli-3.0.1338.1.dist-info}/WHEEL +0 -0
  52. {tccli-3.0.1336.1.dist-info → tccli-3.0.1338.1.dist-info}/entry_points.txt +0 -0
  53. {tccli-3.0.1336.1.dist-info → tccli-3.0.1338.1.dist-info}/license_files/LICENSE +0 -0
@@ -745,7 +745,7 @@ def doDescribeProvinceIspPlayInfoList(args, parsed_globals):
745
745
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
746
746
 
747
747
 
748
- def doModifyLivePushAuthKey(args, parsed_globals):
748
+ def doModifyLivePlayDomain(args, parsed_globals):
749
749
  g_param = parse_global_arg(parsed_globals)
750
750
 
751
751
  if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
@@ -774,11 +774,11 @@ def doModifyLivePushAuthKey(args, parsed_globals):
774
774
  client = mod.LiveClient(cred, g_param[OptionsDefine.Region], profile)
775
775
  client._sdkVersion += ("_CLI_" + __version__)
776
776
  models = MODELS_MAP[g_param[OptionsDefine.Version]]
777
- model = models.ModifyLivePushAuthKeyRequest()
777
+ model = models.ModifyLivePlayDomainRequest()
778
778
  model.from_json_string(json.dumps(args))
779
779
  start_time = time.time()
780
780
  while True:
781
- rsp = client.ModifyLivePushAuthKey(model)
781
+ rsp = client.ModifyLivePlayDomain(model)
782
782
  result = rsp.to_json_string()
783
783
  try:
784
784
  json_obj = json.loads(result)
@@ -2253,7 +2253,7 @@ def doDeleteLiveWatermarkRule(args, parsed_globals):
2253
2253
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
2254
2254
 
2255
2255
 
2256
- def doDescribeDeliverBandwidthList(args, parsed_globals):
2256
+ def doSendLiveCloudEffect(args, parsed_globals):
2257
2257
  g_param = parse_global_arg(parsed_globals)
2258
2258
 
2259
2259
  if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
@@ -2282,11 +2282,11 @@ def doDescribeDeliverBandwidthList(args, parsed_globals):
2282
2282
  client = mod.LiveClient(cred, g_param[OptionsDefine.Region], profile)
2283
2283
  client._sdkVersion += ("_CLI_" + __version__)
2284
2284
  models = MODELS_MAP[g_param[OptionsDefine.Version]]
2285
- model = models.DescribeDeliverBandwidthListRequest()
2285
+ model = models.SendLiveCloudEffectRequest()
2286
2286
  model.from_json_string(json.dumps(args))
2287
2287
  start_time = time.time()
2288
2288
  while True:
2289
- rsp = client.DescribeDeliverBandwidthList(model)
2289
+ rsp = client.SendLiveCloudEffect(model)
2290
2290
  result = rsp.to_json_string()
2291
2291
  try:
2292
2292
  json_obj = json.loads(result)
@@ -2461,6 +2461,58 @@ def doCreateLiveSnapshotTemplate(args, parsed_globals):
2461
2461
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
2462
2462
 
2463
2463
 
2464
+ def doDescribeDeliverBandwidthList(args, parsed_globals):
2465
+ g_param = parse_global_arg(parsed_globals)
2466
+
2467
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
2468
+ cred = credential.CVMRoleCredential()
2469
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
2470
+ cred = credential.STSAssumeRoleCredential(
2471
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
2472
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
2473
+ )
2474
+ 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):
2475
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
2476
+ else:
2477
+ cred = credential.Credential(
2478
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
2479
+ )
2480
+ http_profile = HttpProfile(
2481
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
2482
+ reqMethod="POST",
2483
+ endpoint=g_param[OptionsDefine.Endpoint],
2484
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
2485
+ )
2486
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
2487
+ if g_param[OptionsDefine.Language]:
2488
+ profile.language = g_param[OptionsDefine.Language]
2489
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
2490
+ client = mod.LiveClient(cred, g_param[OptionsDefine.Region], profile)
2491
+ client._sdkVersion += ("_CLI_" + __version__)
2492
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
2493
+ model = models.DescribeDeliverBandwidthListRequest()
2494
+ model.from_json_string(json.dumps(args))
2495
+ start_time = time.time()
2496
+ while True:
2497
+ rsp = client.DescribeDeliverBandwidthList(model)
2498
+ result = rsp.to_json_string()
2499
+ try:
2500
+ json_obj = json.loads(result)
2501
+ except TypeError as e:
2502
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
2503
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
2504
+ break
2505
+ cur_time = time.time()
2506
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
2507
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
2508
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
2509
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
2510
+ else:
2511
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
2512
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
2513
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
2514
+
2515
+
2464
2516
  def doDescribeLiveStreamOnlineList(args, parsed_globals):
2465
2517
  g_param = parse_global_arg(parsed_globals)
2466
2518
 
@@ -3605,7 +3657,7 @@ def doDescribeStreamDayPlayInfoList(args, parsed_globals):
3605
3657
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
3606
3658
 
3607
3659
 
3608
- def doModifyLivePlayDomain(args, parsed_globals):
3660
+ def doDescribeLivePadStreamList(args, parsed_globals):
3609
3661
  g_param = parse_global_arg(parsed_globals)
3610
3662
 
3611
3663
  if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
@@ -3634,11 +3686,11 @@ def doModifyLivePlayDomain(args, parsed_globals):
3634
3686
  client = mod.LiveClient(cred, g_param[OptionsDefine.Region], profile)
3635
3687
  client._sdkVersion += ("_CLI_" + __version__)
3636
3688
  models = MODELS_MAP[g_param[OptionsDefine.Version]]
3637
- model = models.ModifyLivePlayDomainRequest()
3689
+ model = models.DescribeLivePadStreamListRequest()
3638
3690
  model.from_json_string(json.dumps(args))
3639
3691
  start_time = time.time()
3640
3692
  while True:
3641
- rsp = client.ModifyLivePlayDomain(model)
3693
+ rsp = client.DescribeLivePadStreamList(model)
3642
3694
  result = rsp.to_json_string()
3643
3695
  try:
3644
3696
  json_obj = json.loads(result)
@@ -5061,7 +5113,7 @@ def doDescribeStreamPlayInfoList(args, parsed_globals):
5061
5113
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
5062
5114
 
5063
5115
 
5064
- def doCreateCaster(args, parsed_globals):
5116
+ def doDescribeLiveCloudEffectList(args, parsed_globals):
5065
5117
  g_param = parse_global_arg(parsed_globals)
5066
5118
 
5067
5119
  if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
@@ -5090,11 +5142,11 @@ def doCreateCaster(args, parsed_globals):
5090
5142
  client = mod.LiveClient(cred, g_param[OptionsDefine.Region], profile)
5091
5143
  client._sdkVersion += ("_CLI_" + __version__)
5092
5144
  models = MODELS_MAP[g_param[OptionsDefine.Version]]
5093
- model = models.CreateCasterRequest()
5145
+ model = models.DescribeLiveCloudEffectListRequest()
5094
5146
  model.from_json_string(json.dumps(args))
5095
5147
  start_time = time.time()
5096
5148
  while True:
5097
- rsp = client.CreateCaster(model)
5149
+ rsp = client.DescribeLiveCloudEffectList(model)
5098
5150
  result = rsp.to_json_string()
5099
5151
  try:
5100
5152
  json_obj = json.loads(result)
@@ -7089,6 +7141,58 @@ def doDescribeLiveCallbackTemplate(args, parsed_globals):
7089
7141
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
7090
7142
 
7091
7143
 
7144
+ def doDescribeCasterUserStatus(args, parsed_globals):
7145
+ g_param = parse_global_arg(parsed_globals)
7146
+
7147
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
7148
+ cred = credential.CVMRoleCredential()
7149
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
7150
+ cred = credential.STSAssumeRoleCredential(
7151
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
7152
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
7153
+ )
7154
+ 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):
7155
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
7156
+ else:
7157
+ cred = credential.Credential(
7158
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
7159
+ )
7160
+ http_profile = HttpProfile(
7161
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
7162
+ reqMethod="POST",
7163
+ endpoint=g_param[OptionsDefine.Endpoint],
7164
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
7165
+ )
7166
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
7167
+ if g_param[OptionsDefine.Language]:
7168
+ profile.language = g_param[OptionsDefine.Language]
7169
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
7170
+ client = mod.LiveClient(cred, g_param[OptionsDefine.Region], profile)
7171
+ client._sdkVersion += ("_CLI_" + __version__)
7172
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
7173
+ model = models.DescribeCasterUserStatusRequest()
7174
+ model.from_json_string(json.dumps(args))
7175
+ start_time = time.time()
7176
+ while True:
7177
+ rsp = client.DescribeCasterUserStatus(model)
7178
+ result = rsp.to_json_string()
7179
+ try:
7180
+ json_obj = json.loads(result)
7181
+ except TypeError as e:
7182
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
7183
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
7184
+ break
7185
+ cur_time = time.time()
7186
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
7187
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
7188
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
7189
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
7190
+ else:
7191
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
7192
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
7193
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
7194
+
7195
+
7092
7196
  def doDescribeLivePackageInfo(args, parsed_globals):
7093
7197
  g_param = parse_global_arg(parsed_globals)
7094
7198
 
@@ -7609,6 +7713,58 @@ def doDescribeCallbackRecordsList(args, parsed_globals):
7609
7713
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
7610
7714
 
7611
7715
 
7716
+ def doStopLivePadStream(args, parsed_globals):
7717
+ g_param = parse_global_arg(parsed_globals)
7718
+
7719
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
7720
+ cred = credential.CVMRoleCredential()
7721
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
7722
+ cred = credential.STSAssumeRoleCredential(
7723
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
7724
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
7725
+ )
7726
+ 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):
7727
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
7728
+ else:
7729
+ cred = credential.Credential(
7730
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
7731
+ )
7732
+ http_profile = HttpProfile(
7733
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
7734
+ reqMethod="POST",
7735
+ endpoint=g_param[OptionsDefine.Endpoint],
7736
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
7737
+ )
7738
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
7739
+ if g_param[OptionsDefine.Language]:
7740
+ profile.language = g_param[OptionsDefine.Language]
7741
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
7742
+ client = mod.LiveClient(cred, g_param[OptionsDefine.Region], profile)
7743
+ client._sdkVersion += ("_CLI_" + __version__)
7744
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
7745
+ model = models.StopLivePadStreamRequest()
7746
+ model.from_json_string(json.dumps(args))
7747
+ start_time = time.time()
7748
+ while True:
7749
+ rsp = client.StopLivePadStream(model)
7750
+ result = rsp.to_json_string()
7751
+ try:
7752
+ json_obj = json.loads(result)
7753
+ except TypeError as e:
7754
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
7755
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
7756
+ break
7757
+ cur_time = time.time()
7758
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
7759
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
7760
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
7761
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
7762
+ else:
7763
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
7764
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
7765
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
7766
+
7767
+
7612
7768
  def doCreateLiveRecordRule(args, parsed_globals):
7613
7769
  g_param = parse_global_arg(parsed_globals)
7614
7770
 
@@ -8129,6 +8285,58 @@ def doCreatePullStreamConfig(args, parsed_globals):
8129
8285
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
8130
8286
 
8131
8287
 
8288
+ def doModifyLivePushAuthKey(args, parsed_globals):
8289
+ g_param = parse_global_arg(parsed_globals)
8290
+
8291
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
8292
+ cred = credential.CVMRoleCredential()
8293
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
8294
+ cred = credential.STSAssumeRoleCredential(
8295
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
8296
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
8297
+ )
8298
+ 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):
8299
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
8300
+ else:
8301
+ cred = credential.Credential(
8302
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
8303
+ )
8304
+ http_profile = HttpProfile(
8305
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
8306
+ reqMethod="POST",
8307
+ endpoint=g_param[OptionsDefine.Endpoint],
8308
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
8309
+ )
8310
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
8311
+ if g_param[OptionsDefine.Language]:
8312
+ profile.language = g_param[OptionsDefine.Language]
8313
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
8314
+ client = mod.LiveClient(cred, g_param[OptionsDefine.Region], profile)
8315
+ client._sdkVersion += ("_CLI_" + __version__)
8316
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
8317
+ model = models.ModifyLivePushAuthKeyRequest()
8318
+ model.from_json_string(json.dumps(args))
8319
+ start_time = time.time()
8320
+ while True:
8321
+ rsp = client.ModifyLivePushAuthKey(model)
8322
+ result = rsp.to_json_string()
8323
+ try:
8324
+ json_obj = json.loads(result)
8325
+ except TypeError as e:
8326
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
8327
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
8328
+ break
8329
+ cur_time = time.time()
8330
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
8331
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
8332
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
8333
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
8334
+ else:
8335
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
8336
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
8337
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
8338
+
8339
+
8132
8340
  def doDescribeLiveWatermarkRules(args, parsed_globals):
8133
8341
  g_param = parse_global_arg(parsed_globals)
8134
8342
 
@@ -9013,7 +9221,7 @@ def doModifyLiveStreamMonitor(args, parsed_globals):
9013
9221
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
9014
9222
 
9015
9223
 
9016
- def doDescribeCasterUserStatus(args, parsed_globals):
9224
+ def doCreateCaster(args, parsed_globals):
9017
9225
  g_param = parse_global_arg(parsed_globals)
9018
9226
 
9019
9227
  if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
@@ -9042,11 +9250,11 @@ def doDescribeCasterUserStatus(args, parsed_globals):
9042
9250
  client = mod.LiveClient(cred, g_param[OptionsDefine.Region], profile)
9043
9251
  client._sdkVersion += ("_CLI_" + __version__)
9044
9252
  models = MODELS_MAP[g_param[OptionsDefine.Version]]
9045
- model = models.DescribeCasterUserStatusRequest()
9253
+ model = models.CreateCasterRequest()
9046
9254
  model.from_json_string(json.dumps(args))
9047
9255
  start_time = time.time()
9048
9256
  while True:
9049
- rsp = client.DescribeCasterUserStatus(model)
9257
+ rsp = client.CreateCaster(model)
9050
9258
  result = rsp.to_json_string()
9051
9259
  try:
9052
9260
  json_obj = json.loads(result)
@@ -10157,6 +10365,58 @@ def doDeleteLiveSnapshotTemplate(args, parsed_globals):
10157
10365
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
10158
10366
 
10159
10367
 
10368
+ def doStartLivePadStream(args, parsed_globals):
10369
+ g_param = parse_global_arg(parsed_globals)
10370
+
10371
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
10372
+ cred = credential.CVMRoleCredential()
10373
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
10374
+ cred = credential.STSAssumeRoleCredential(
10375
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
10376
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
10377
+ )
10378
+ 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):
10379
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
10380
+ else:
10381
+ cred = credential.Credential(
10382
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
10383
+ )
10384
+ http_profile = HttpProfile(
10385
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
10386
+ reqMethod="POST",
10387
+ endpoint=g_param[OptionsDefine.Endpoint],
10388
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
10389
+ )
10390
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
10391
+ if g_param[OptionsDefine.Language]:
10392
+ profile.language = g_param[OptionsDefine.Language]
10393
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
10394
+ client = mod.LiveClient(cred, g_param[OptionsDefine.Region], profile)
10395
+ client._sdkVersion += ("_CLI_" + __version__)
10396
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
10397
+ model = models.StartLivePadStreamRequest()
10398
+ model.from_json_string(json.dumps(args))
10399
+ start_time = time.time()
10400
+ while True:
10401
+ rsp = client.StartLivePadStream(model)
10402
+ result = rsp.to_json_string()
10403
+ try:
10404
+ json_obj = json.loads(result)
10405
+ except TypeError as e:
10406
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
10407
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
10408
+ break
10409
+ cur_time = time.time()
10410
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
10411
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
10412
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
10413
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
10414
+ else:
10415
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
10416
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
10417
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
10418
+
10419
+
10160
10420
  CLIENT_MAP = {
10161
10421
  "v20180801": live_client_v20180801,
10162
10422
 
@@ -10182,7 +10442,7 @@ ACTION_MAP = {
10182
10442
  "DescribePullStreamConfigs": doDescribePullStreamConfigs,
10183
10443
  "DescribeHttpStatusInfoList": doDescribeHttpStatusInfoList,
10184
10444
  "DescribeProvinceIspPlayInfoList": doDescribeProvinceIspPlayInfoList,
10185
- "ModifyLivePushAuthKey": doModifyLivePushAuthKey,
10445
+ "ModifyLivePlayDomain": doModifyLivePlayDomain,
10186
10446
  "DescribeStreamPushInfoList": doDescribeStreamPushInfoList,
10187
10447
  "StartLiveStreamMonitor": doStartLiveStreamMonitor,
10188
10448
  "DescribeLiveSnapshotRules": doDescribeLiveSnapshotRules,
@@ -10211,10 +10471,11 @@ ACTION_MAP = {
10211
10471
  "DescribeCasterMarkWordInfos": doDescribeCasterMarkWordInfos,
10212
10472
  "DeleteCasterLayoutInfo": doDeleteCasterLayoutInfo,
10213
10473
  "DeleteLiveWatermarkRule": doDeleteLiveWatermarkRule,
10214
- "DescribeDeliverBandwidthList": doDescribeDeliverBandwidthList,
10474
+ "SendLiveCloudEffect": doSendLiveCloudEffect,
10215
10475
  "DeleteLiveCallbackRule": doDeleteLiveCallbackRule,
10216
10476
  "ModifyPullStreamConfig": doModifyPullStreamConfig,
10217
10477
  "CreateLiveSnapshotTemplate": doCreateLiveSnapshotTemplate,
10478
+ "DescribeDeliverBandwidthList": doDescribeDeliverBandwidthList,
10218
10479
  "DescribeLiveStreamOnlineList": doDescribeLiveStreamOnlineList,
10219
10480
  "EnableOptimalSwitching": doEnableOptimalSwitching,
10220
10481
  "DeleteLiveCallbackTemplate": doDeleteLiveCallbackTemplate,
@@ -10237,7 +10498,7 @@ ACTION_MAP = {
10237
10498
  "AddDelayLiveStream": doAddDelayLiveStream,
10238
10499
  "DescribeUploadStreamNums": doDescribeUploadStreamNums,
10239
10500
  "DescribeStreamDayPlayInfoList": doDescribeStreamDayPlayInfoList,
10240
- "ModifyLivePlayDomain": doModifyLivePlayDomain,
10501
+ "DescribeLivePadStreamList": doDescribeLivePadStreamList,
10241
10502
  "ModifyLiveTranscodeTemplate": doModifyLiveTranscodeTemplate,
10242
10503
  "DeleteLiveTranscodeRule": doDeleteLiveTranscodeRule,
10243
10504
  "DescribeLiveTranscodeTotalInfo": doDescribeLiveTranscodeTotalInfo,
@@ -10265,7 +10526,7 @@ ACTION_MAP = {
10265
10526
  "DeleteLiveTimeShiftTemplate": doDeleteLiveTimeShiftTemplate,
10266
10527
  "DescribeGroupProIspPlayInfoList": doDescribeGroupProIspPlayInfoList,
10267
10528
  "DescribeStreamPlayInfoList": doDescribeStreamPlayInfoList,
10268
- "CreateCaster": doCreateCaster,
10529
+ "DescribeLiveCloudEffectList": doDescribeLiveCloudEffectList,
10269
10530
  "DescribeCasterLayoutInfos": doDescribeCasterLayoutInfos,
10270
10531
  "DescribeLivePullStreamTaskStatus": doDescribeLivePullStreamTaskStatus,
10271
10532
  "DescribeLiveSnapshotTemplate": doDescribeLiveSnapshotTemplate,
@@ -10304,6 +10565,7 @@ ACTION_MAP = {
10304
10565
  "DescribeLivePadProcessorList": doDescribeLivePadProcessorList,
10305
10566
  "DescribePushBandwidthAndFluxList": doDescribePushBandwidthAndFluxList,
10306
10567
  "DescribeLiveCallbackTemplate": doDescribeLiveCallbackTemplate,
10568
+ "DescribeCasterUserStatus": doDescribeCasterUserStatus,
10307
10569
  "DescribeLivePackageInfo": doDescribeLivePackageInfo,
10308
10570
  "DescribeLiveTimeShiftWriteSizeInfoList": doDescribeLiveTimeShiftWriteSizeInfoList,
10309
10571
  "ForbidLiveStream": doForbidLiveStream,
@@ -10314,6 +10576,7 @@ ACTION_MAP = {
10314
10576
  "DescribeLiveDomainPlayInfoList": doDescribeLiveDomainPlayInfoList,
10315
10577
  "CreateLiveTimeShiftRule": doCreateLiveTimeShiftRule,
10316
10578
  "DescribeCallbackRecordsList": doDescribeCallbackRecordsList,
10579
+ "StopLivePadStream": doStopLivePadStream,
10317
10580
  "CreateLiveRecordRule": doCreateLiveRecordRule,
10318
10581
  "DescribeLiveWatermark": doDescribeLiveWatermark,
10319
10582
  "DescribeLiveTranscodeTemplates": doDescribeLiveTranscodeTemplates,
@@ -10324,6 +10587,7 @@ ACTION_MAP = {
10324
10587
  "DeleteLiveTimeShiftRule": doDeleteLiveTimeShiftRule,
10325
10588
  "RestartLivePullStreamTask": doRestartLivePullStreamTask,
10326
10589
  "CreatePullStreamConfig": doCreatePullStreamConfig,
10590
+ "ModifyLivePushAuthKey": doModifyLivePushAuthKey,
10327
10591
  "DescribeLiveWatermarkRules": doDescribeLiveWatermarkRules,
10328
10592
  "DescribeLivePadRules": doDescribeLivePadRules,
10329
10593
  "DeleteCasterInputInfo": doDeleteCasterInputInfo,
@@ -10341,7 +10605,7 @@ ACTION_MAP = {
10341
10605
  "DescribeCasterTransitionTypes": doDescribeCasterTransitionTypes,
10342
10606
  "DescribeCasterDisplayInfo": doDescribeCasterDisplayInfo,
10343
10607
  "ModifyLiveStreamMonitor": doModifyLiveStreamMonitor,
10344
- "DescribeCasterUserStatus": doDescribeCasterUserStatus,
10608
+ "CreateCaster": doCreateCaster,
10345
10609
  "DescribeLiveStreamState": doDescribeLiveStreamState,
10346
10610
  "ModifyLiveDomainReferer": doModifyLiveDomainReferer,
10347
10611
  "DeleteLiveRecordTemplate": doDeleteLiveRecordTemplate,
@@ -10363,6 +10627,7 @@ ACTION_MAP = {
10363
10627
  "DescribeTranscodeTaskNum": doDescribeTranscodeTaskNum,
10364
10628
  "DescribeLiveStreamPushInfoList": doDescribeLiveStreamPushInfoList,
10365
10629
  "DeleteLiveSnapshotTemplate": doDeleteLiveSnapshotTemplate,
10630
+ "StartLivePadStream": doStartLivePadStream,
10366
10631
 
10367
10632
  }
10368
10633