tccli 3.0.1097.1__py2.py3-none-any.whl → 3.0.1099.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 (64) hide show
  1. tccli/__init__.py +1 -1
  2. tccli/examples/apm/v20210622/DescribeGeneralApmApplicationConfig.md +103 -0
  3. tccli/examples/apm/v20210622/DescribeTagValues.md +27 -0
  4. tccli/examples/apm/v20210622/ModifyGeneralApmApplicationConfig.md +29 -0
  5. tccli/examples/cfw/v20190904/DescribeIPStatusList.md +4 -4
  6. tccli/examples/cls/v20201016/OpenKafkaConsumer.md +1 -1
  7. tccli/examples/cynosdb/v20190107/DescribeChangedParamsAfterUpgrade.md +31 -0
  8. tccli/examples/ess/v20201111/CreateBatchSignUrl.md +28 -0
  9. tccli/examples/essbasic/v20210526/ChannelCreateBatchSignUrl.md +28 -0
  10. tccli/examples/faceid/v20180301/GetFaceIdResult.md +3 -1
  11. tccli/examples/hunyuan/v20230901/ChatCompletions.md +43 -0
  12. tccli/examples/ims/v20200713/ImageModeration.md +4 -1
  13. tccli/examples/iotexplorer/v20190423/DescribeDeviceFirmwares.md +33 -0
  14. tccli/examples/teo/v20220901/DescribeRealtimeLogDeliveryTasks.md +42 -21
  15. tccli/services/aiart/v20221229/api.json +1 -1
  16. tccli/services/apm/apm_client.py +159 -0
  17. tccli/services/apm/v20210622/api.json +456 -0
  18. tccli/services/apm/v20210622/examples.json +24 -0
  19. tccli/services/ccc/v20200210/api.json +1 -1
  20. tccli/services/cfs/v20190719/api.json +27 -27
  21. tccli/services/cfw/v20190904/api.json +5 -5
  22. tccli/services/cfw/v20190904/examples.json +1 -1
  23. tccli/services/cloudstudio/v20230508/api.json +14 -5
  24. tccli/services/cls/v20201016/api.json +68 -44
  25. tccli/services/cls/v20201016/examples.json +1 -1
  26. tccli/services/cynosdb/cynosdb_client.py +53 -0
  27. tccli/services/cynosdb/v20190107/api.json +122 -2
  28. tccli/services/cynosdb/v20190107/examples.json +8 -0
  29. tccli/services/dcdb/v20180411/api.json +2 -2
  30. tccli/services/ess/v20201111/api.json +51 -3
  31. tccli/services/ess/v20201111/examples.json +6 -0
  32. tccli/services/essbasic/v20210526/api.json +50 -2
  33. tccli/services/essbasic/v20210526/examples.json +6 -0
  34. tccli/services/faceid/v20180301/api.json +21 -1
  35. tccli/services/faceid/v20180301/examples.json +1 -1
  36. tccli/services/hunyuan/hunyuan_client.py +53 -0
  37. tccli/services/hunyuan/v20230901/api.json +161 -22
  38. tccli/services/hunyuan/v20230901/examples.json +8 -0
  39. tccli/services/ims/v20200713/api.json +13 -0
  40. tccli/services/ims/v20200713/examples.json +1 -1
  41. tccli/services/ims/v20201229/api.json +55 -55
  42. tccli/services/iotexplorer/iotexplorer_client.py +53 -0
  43. tccli/services/iotexplorer/v20190423/api.json +89 -0
  44. tccli/services/iotexplorer/v20190423/examples.json +8 -0
  45. tccli/services/iss/v20230517/api.json +36 -0
  46. tccli/services/lcic/v20220817/api.json +1 -1
  47. tccli/services/lke/lke_client.py +8 -114
  48. tccli/services/lke/v20231130/api.json +2 -166
  49. tccli/services/lke/v20231130/examples.json +0 -16
  50. tccli/services/mariadb/v20170312/api.json +2 -2
  51. tccli/services/monitor/v20180724/api.json +1 -1
  52. tccli/services/mps/v20190612/api.json +46 -1
  53. tccli/services/rum/v20210622/api.json +2 -2
  54. tccli/services/tdid/v20210519/api.json +2 -2
  55. tccli/services/teo/v20220901/api.json +142 -31
  56. tccli/services/teo/v20220901/examples.json +2 -2
  57. tccli/services/tione/v20211111/api.json +28 -0
  58. tccli/services/tmt/v20180321/api.json +1 -1
  59. tccli/services/waf/v20180125/api.json +2 -2
  60. {tccli-3.0.1097.1.dist-info → tccli-3.0.1099.1.dist-info}/METADATA +2 -2
  61. {tccli-3.0.1097.1.dist-info → tccli-3.0.1099.1.dist-info}/RECORD +64 -58
  62. {tccli-3.0.1097.1.dist-info → tccli-3.0.1099.1.dist-info}/WHEEL +0 -0
  63. {tccli-3.0.1097.1.dist-info → tccli-3.0.1099.1.dist-info}/entry_points.txt +0 -0
  64. {tccli-3.0.1097.1.dist-info → tccli-3.0.1099.1.dist-info}/license_files/LICENSE +0 -0
@@ -69,6 +69,58 @@ def doModifyApmInstance(args, parsed_globals):
69
69
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
70
70
 
71
71
 
72
+ def doDescribeTagValues(args, parsed_globals):
73
+ g_param = parse_global_arg(parsed_globals)
74
+
75
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
76
+ cred = credential.CVMRoleCredential()
77
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
78
+ cred = credential.STSAssumeRoleCredential(
79
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
80
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
81
+ )
82
+ 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):
83
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
84
+ else:
85
+ cred = credential.Credential(
86
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
87
+ )
88
+ http_profile = HttpProfile(
89
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
90
+ reqMethod="POST",
91
+ endpoint=g_param[OptionsDefine.Endpoint],
92
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
93
+ )
94
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
95
+ if g_param[OptionsDefine.Language]:
96
+ profile.language = g_param[OptionsDefine.Language]
97
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
98
+ client = mod.ApmClient(cred, g_param[OptionsDefine.Region], profile)
99
+ client._sdkVersion += ("_CLI_" + __version__)
100
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
101
+ model = models.DescribeTagValuesRequest()
102
+ model.from_json_string(json.dumps(args))
103
+ start_time = time.time()
104
+ while True:
105
+ rsp = client.DescribeTagValues(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
+
72
124
  def doDescribeGeneralSpanList(args, parsed_globals):
73
125
  g_param = parse_global_arg(parsed_globals)
74
126
 
@@ -225,6 +277,110 @@ def doDescribeApmAgent(args, parsed_globals):
225
277
  FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
226
278
 
227
279
 
280
+ def doDescribeGeneralApmApplicationConfig(args, parsed_globals):
281
+ g_param = parse_global_arg(parsed_globals)
282
+
283
+ if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
284
+ cred = credential.CVMRoleCredential()
285
+ elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
286
+ cred = credential.STSAssumeRoleCredential(
287
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
288
+ g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
289
+ )
290
+ 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):
291
+ cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
292
+ else:
293
+ cred = credential.Credential(
294
+ g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
295
+ )
296
+ http_profile = HttpProfile(
297
+ reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
298
+ reqMethod="POST",
299
+ endpoint=g_param[OptionsDefine.Endpoint],
300
+ proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
301
+ )
302
+ profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
303
+ if g_param[OptionsDefine.Language]:
304
+ profile.language = g_param[OptionsDefine.Language]
305
+ mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
306
+ client = mod.ApmClient(cred, g_param[OptionsDefine.Region], profile)
307
+ client._sdkVersion += ("_CLI_" + __version__)
308
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
309
+ model = models.DescribeGeneralApmApplicationConfigRequest()
310
+ model.from_json_string(json.dumps(args))
311
+ start_time = time.time()
312
+ while True:
313
+ rsp = client.DescribeGeneralApmApplicationConfig(model)
314
+ result = rsp.to_json_string()
315
+ try:
316
+ json_obj = json.loads(result)
317
+ except TypeError as e:
318
+ json_obj = json.loads(result.decode('utf-8')) # python3.3
319
+ if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
320
+ break
321
+ cur_time = time.time()
322
+ if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
323
+ raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
324
+ (g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
325
+ search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
326
+ else:
327
+ print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
328
+ time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
329
+ FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
330
+
331
+
332
+ def doModifyGeneralApmApplicationConfig(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.ApmClient(cred, g_param[OptionsDefine.Region], profile)
359
+ client._sdkVersion += ("_CLI_" + __version__)
360
+ models = MODELS_MAP[g_param[OptionsDefine.Version]]
361
+ model = models.ModifyGeneralApmApplicationConfigRequest()
362
+ model.from_json_string(json.dumps(args))
363
+ start_time = time.time()
364
+ while True:
365
+ rsp = client.ModifyGeneralApmApplicationConfig(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 doDescribeGeneralMetricData(args, parsed_globals):
229
385
  g_param = parse_global_arg(parsed_globals)
230
386
 
@@ -497,9 +653,12 @@ MODELS_MAP = {
497
653
 
498
654
  ACTION_MAP = {
499
655
  "ModifyApmInstance": doModifyApmInstance,
656
+ "DescribeTagValues": doDescribeTagValues,
500
657
  "DescribeGeneralSpanList": doDescribeGeneralSpanList,
501
658
  "DescribeApmInstances": doDescribeApmInstances,
502
659
  "DescribeApmAgent": doDescribeApmAgent,
660
+ "DescribeGeneralApmApplicationConfig": doDescribeGeneralApmApplicationConfig,
661
+ "ModifyGeneralApmApplicationConfig": doModifyGeneralApmApplicationConfig,
503
662
  "DescribeGeneralMetricData": doDescribeGeneralMetricData,
504
663
  "DescribeMetricRecords": doDescribeMetricRecords,
505
664
  "TerminateApmInstance": doTerminateApmInstance,