tccli 3.0.1393.1__py2.py3-none-any.whl → 3.0.1395.1__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- tccli/__init__.py +1 -1
- tccli/services/__init__.py +2 -1
- tccli/services/ai3d/v20250513/api.json +4 -4
- tccli/services/apm/apm_client.py +53 -0
- tccli/services/apm/v20210622/api.json +354 -0
- tccli/services/apm/v20210622/examples.json +8 -0
- tccli/services/billing/billing_client.py +326 -8
- tccli/services/billing/v20180709/api.json +2200 -255
- tccli/services/billing/v20180709/examples.json +48 -0
- tccli/services/cam/v20190116/api.json +1 -1
- tccli/services/ccc/ccc_client.py +125 -72
- tccli/services/ccc/v20200210/api.json +185 -10
- tccli/services/ccc/v20200210/examples.json +8 -0
- tccli/services/cfw/v20190904/api.json +121 -9
- tccli/services/ckafka/v20190819/api.json +20 -0
- tccli/services/ctem/v20231128/api.json +290 -0
- tccli/services/ctem/v20231128/examples.json +3 -3
- tccli/services/cvm/cvm_client.py +0 -212
- tccli/services/cvm/v20170312/api.json +80 -842
- tccli/services/cvm/v20170312/examples.json +24 -56
- tccli/services/emr/v20190103/api.json +36 -7
- tccli/services/ess/v20201111/api.json +7 -7
- tccli/services/ess/v20201111/examples.json +6 -6
- tccli/services/essbasic/v20210526/api.json +1 -1
- tccli/services/gs/gs_client.py +216 -4
- tccli/services/gs/v20191118/api.json +201 -0
- tccli/services/gs/v20191118/examples.json +32 -0
- tccli/services/iai/v20180301/api.json +115 -93
- tccli/services/iai/v20180301/examples.json +19 -19
- tccli/services/iotexplorer/iotexplorer_client.py +57 -4
- tccli/services/iotexplorer/v20190423/api.json +69 -0
- tccli/services/iotexplorer/v20190423/examples.json +8 -0
- tccli/services/lighthouse/v20200324/api.json +113 -9
- tccli/services/lighthouse/v20200324/examples.json +2 -2
- tccli/services/lke/v20231130/api.json +34 -1
- tccli/services/lkeap/v20240522/api.json +1 -1
- tccli/services/mna/v20210119/api.json +10 -1
- tccli/services/mna/v20210119/examples.json +1 -1
- tccli/services/ocr/v20181119/api.json +2 -2
- tccli/services/organization/v20210331/api.json +6 -6
- tccli/services/redis/v20180412/api.json +9 -9
- tccli/services/sqlserver/v20180328/api.json +15 -5
- tccli/services/sqlserver/v20180328/examples.json +1 -1
- tccli/services/trocket/v20230308/api.json +4 -4
- tccli/services/tsf/v20180326/api.json +2 -2
- tccli/services/vod/v20180717/api.json +1 -1
- tccli/services/vpc/v20170312/api.json +5 -5
- tccli/services/vtc/v20240223/api.json +1 -1
- tccli/services/waf/v20180125/api.json +8 -8
- tccli/services/waf/v20180125/examples.json +1 -1
- tccli/services/wedata/v20250806/api.json +13645 -0
- tccli/services/wedata/v20250806/examples.json +621 -0
- tccli/services/wedata/wedata_client.py +5031 -1157
- {tccli-3.0.1393.1.dist-info → tccli-3.0.1395.1.dist-info}/METADATA +2 -2
- {tccli-3.0.1393.1.dist-info → tccli-3.0.1395.1.dist-info}/RECORD +58 -56
- {tccli-3.0.1393.1.dist-info → tccli-3.0.1395.1.dist-info}/WHEEL +0 -0
- {tccli-3.0.1393.1.dist-info → tccli-3.0.1395.1.dist-info}/entry_points.txt +0 -0
- {tccli-3.0.1393.1.dist-info → tccli-3.0.1395.1.dist-info}/license_files/LICENSE +0 -0
@@ -6405,6 +6405,66 @@
|
|
6405
6405
|
"type": "int",
|
6406
6406
|
"value_allowed_null": false
|
6407
6407
|
},
|
6408
|
+
{
|
6409
|
+
"disabled": false,
|
6410
|
+
"document": "公共字段",
|
6411
|
+
"example": "无",
|
6412
|
+
"member": "DisplayToolCommon",
|
6413
|
+
"name": "DisplayToolCommon",
|
6414
|
+
"output_required": false,
|
6415
|
+
"type": "object",
|
6416
|
+
"value_allowed_null": false
|
6417
|
+
},
|
6418
|
+
{
|
6419
|
+
"disabled": false,
|
6420
|
+
"document": "事件名称",
|
6421
|
+
"example": "源码泄露",
|
6422
|
+
"member": "string",
|
6423
|
+
"name": "Name",
|
6424
|
+
"output_required": false,
|
6425
|
+
"type": "string",
|
6426
|
+
"value_allowed_null": false
|
6427
|
+
},
|
6428
|
+
{
|
6429
|
+
"disabled": false,
|
6430
|
+
"document": "事件描述",
|
6431
|
+
"example": "源码泄露",
|
6432
|
+
"member": "string",
|
6433
|
+
"name": "Description",
|
6434
|
+
"output_required": false,
|
6435
|
+
"type": "string",
|
6436
|
+
"value_allowed_null": false
|
6437
|
+
},
|
6438
|
+
{
|
6439
|
+
"disabled": false,
|
6440
|
+
"document": "数据源",
|
6441
|
+
"example": "http://github.com/xxx",
|
6442
|
+
"member": "string",
|
6443
|
+
"name": "Source",
|
6444
|
+
"output_required": false,
|
6445
|
+
"type": "string",
|
6446
|
+
"value_allowed_null": false
|
6447
|
+
},
|
6448
|
+
{
|
6449
|
+
"disabled": false,
|
6450
|
+
"document": "风险等级:1-低危 2-中危 3-高危 4-严重 5-误报",
|
6451
|
+
"example": "1",
|
6452
|
+
"member": "int64",
|
6453
|
+
"name": "RiskLevel",
|
6454
|
+
"output_required": false,
|
6455
|
+
"type": "int",
|
6456
|
+
"value_allowed_null": false
|
6457
|
+
},
|
6458
|
+
{
|
6459
|
+
"disabled": false,
|
6460
|
+
"document": "仓库名称",
|
6461
|
+
"example": "http://github.com/test.git",
|
6462
|
+
"member": "string",
|
6463
|
+
"name": "HubName",
|
6464
|
+
"output_required": false,
|
6465
|
+
"type": "string",
|
6466
|
+
"value_allowed_null": false
|
6467
|
+
},
|
6408
6468
|
{
|
6409
6469
|
"disabled": false,
|
6410
6470
|
"document": "链接",
|
@@ -6414,6 +6474,56 @@
|
|
6414
6474
|
"output_required": false,
|
6415
6475
|
"type": "string",
|
6416
6476
|
"value_allowed_null": false
|
6477
|
+
},
|
6478
|
+
{
|
6479
|
+
"disabled": false,
|
6480
|
+
"document": "截图",
|
6481
|
+
"example": "http://test.com/xx.png",
|
6482
|
+
"member": "string",
|
6483
|
+
"name": "Screenshot",
|
6484
|
+
"output_required": false,
|
6485
|
+
"type": "string",
|
6486
|
+
"value_allowed_null": false
|
6487
|
+
},
|
6488
|
+
{
|
6489
|
+
"disabled": false,
|
6490
|
+
"document": "建议",
|
6491
|
+
"example": "建议删除",
|
6492
|
+
"member": "string",
|
6493
|
+
"name": "Suggestion",
|
6494
|
+
"output_required": false,
|
6495
|
+
"type": "string",
|
6496
|
+
"value_allowed_null": false
|
6497
|
+
},
|
6498
|
+
{
|
6499
|
+
"disabled": false,
|
6500
|
+
"document": "关键词",
|
6501
|
+
"example": "AKID2534xxx",
|
6502
|
+
"member": "string",
|
6503
|
+
"name": "Keyword",
|
6504
|
+
"output_required": false,
|
6505
|
+
"type": "string",
|
6506
|
+
"value_allowed_null": false
|
6507
|
+
},
|
6508
|
+
{
|
6509
|
+
"disabled": false,
|
6510
|
+
"document": "处置状态:0-待处理 1-处理中 2-已处理",
|
6511
|
+
"example": "0",
|
6512
|
+
"member": "int64",
|
6513
|
+
"name": "HandlingStatus",
|
6514
|
+
"output_required": false,
|
6515
|
+
"type": "int",
|
6516
|
+
"value_allowed_null": false
|
6517
|
+
},
|
6518
|
+
{
|
6519
|
+
"disabled": false,
|
6520
|
+
"document": "备注",
|
6521
|
+
"example": "测试数据",
|
6522
|
+
"member": "string",
|
6523
|
+
"name": "Remark",
|
6524
|
+
"output_required": false,
|
6525
|
+
"type": "string",
|
6526
|
+
"value_allowed_null": false
|
6417
6527
|
}
|
6418
6528
|
],
|
6419
6529
|
"usage": "out"
|
@@ -6431,6 +6541,56 @@
|
|
6431
6541
|
"type": "int",
|
6432
6542
|
"value_allowed_null": false
|
6433
6543
|
},
|
6544
|
+
{
|
6545
|
+
"disabled": false,
|
6546
|
+
"document": "公共字段",
|
6547
|
+
"example": "无",
|
6548
|
+
"member": "DisplayToolCommon",
|
6549
|
+
"name": "DisplayToolCommon",
|
6550
|
+
"output_required": false,
|
6551
|
+
"type": "object",
|
6552
|
+
"value_allowed_null": false
|
6553
|
+
},
|
6554
|
+
{
|
6555
|
+
"disabled": false,
|
6556
|
+
"document": "事件名称",
|
6557
|
+
"example": "数据泄露",
|
6558
|
+
"member": "string",
|
6559
|
+
"name": "Name",
|
6560
|
+
"output_required": false,
|
6561
|
+
"type": "string",
|
6562
|
+
"value_allowed_null": false
|
6563
|
+
},
|
6564
|
+
{
|
6565
|
+
"disabled": false,
|
6566
|
+
"document": "事件描述",
|
6567
|
+
"example": "数据泄露",
|
6568
|
+
"member": "string",
|
6569
|
+
"name": "Description",
|
6570
|
+
"output_required": false,
|
6571
|
+
"type": "string",
|
6572
|
+
"value_allowed_null": false
|
6573
|
+
},
|
6574
|
+
{
|
6575
|
+
"disabled": false,
|
6576
|
+
"document": "数据源",
|
6577
|
+
"example": "http://test.com/xx",
|
6578
|
+
"member": "string",
|
6579
|
+
"name": "Source",
|
6580
|
+
"output_required": false,
|
6581
|
+
"type": "string",
|
6582
|
+
"value_allowed_null": false
|
6583
|
+
},
|
6584
|
+
{
|
6585
|
+
"disabled": false,
|
6586
|
+
"document": "风险等级:1-低危 2-中危 3-高危 4-严重 5-误报",
|
6587
|
+
"example": "1",
|
6588
|
+
"member": "int64",
|
6589
|
+
"name": "RiskLevel",
|
6590
|
+
"output_required": false,
|
6591
|
+
"type": "int",
|
6592
|
+
"value_allowed_null": false
|
6593
|
+
},
|
6434
6594
|
{
|
6435
6595
|
"disabled": false,
|
6436
6596
|
"document": "链接",
|
@@ -6440,6 +6600,56 @@
|
|
6440
6600
|
"output_required": false,
|
6441
6601
|
"type": "string",
|
6442
6602
|
"value_allowed_null": false
|
6603
|
+
},
|
6604
|
+
{
|
6605
|
+
"disabled": false,
|
6606
|
+
"document": "截图",
|
6607
|
+
"example": "http://test.com/xx.png",
|
6608
|
+
"member": "string",
|
6609
|
+
"name": "Screenshot",
|
6610
|
+
"output_required": false,
|
6611
|
+
"type": "string",
|
6612
|
+
"value_allowed_null": false
|
6613
|
+
},
|
6614
|
+
{
|
6615
|
+
"disabled": false,
|
6616
|
+
"document": "建议",
|
6617
|
+
"example": "建议删除",
|
6618
|
+
"member": "string",
|
6619
|
+
"name": "Suggestion",
|
6620
|
+
"output_required": false,
|
6621
|
+
"type": "string",
|
6622
|
+
"value_allowed_null": false
|
6623
|
+
},
|
6624
|
+
{
|
6625
|
+
"disabled": false,
|
6626
|
+
"document": "关键词",
|
6627
|
+
"example": "AKID4513xxx",
|
6628
|
+
"member": "string",
|
6629
|
+
"name": "Keyword",
|
6630
|
+
"output_required": false,
|
6631
|
+
"type": "string",
|
6632
|
+
"value_allowed_null": false
|
6633
|
+
},
|
6634
|
+
{
|
6635
|
+
"disabled": false,
|
6636
|
+
"document": "处置状态:0-待处理 1-处理中 2-已处理",
|
6637
|
+
"example": "0",
|
6638
|
+
"member": "int64",
|
6639
|
+
"name": "HandlingStatus",
|
6640
|
+
"output_required": false,
|
6641
|
+
"type": "int",
|
6642
|
+
"value_allowed_null": false
|
6643
|
+
},
|
6644
|
+
{
|
6645
|
+
"disabled": false,
|
6646
|
+
"document": "备注",
|
6647
|
+
"example": "测试数据",
|
6648
|
+
"member": "string",
|
6649
|
+
"name": "Remark",
|
6650
|
+
"output_required": false,
|
6651
|
+
"type": "string",
|
6652
|
+
"value_allowed_null": false
|
6443
6653
|
}
|
6444
6654
|
],
|
6445
6655
|
"usage": "out"
|
@@ -6457,6 +6667,16 @@
|
|
6457
6667
|
"type": "int",
|
6458
6668
|
"value_allowed_null": false
|
6459
6669
|
},
|
6670
|
+
{
|
6671
|
+
"disabled": false,
|
6672
|
+
"document": "公共字段",
|
6673
|
+
"example": "无",
|
6674
|
+
"member": "DisplayToolCommon",
|
6675
|
+
"name": "DisplayToolCommon",
|
6676
|
+
"output_required": false,
|
6677
|
+
"type": "object",
|
6678
|
+
"value_allowed_null": false
|
6679
|
+
},
|
6460
6680
|
{
|
6461
6681
|
"disabled": false,
|
6462
6682
|
"document": "邮箱",
|
@@ -6466,6 +6686,76 @@
|
|
6466
6686
|
"output_required": false,
|
6467
6687
|
"type": "string",
|
6468
6688
|
"value_allowed_null": false
|
6689
|
+
},
|
6690
|
+
{
|
6691
|
+
"disabled": false,
|
6692
|
+
"document": "用户名",
|
6693
|
+
"example": "qqtest",
|
6694
|
+
"member": "string",
|
6695
|
+
"name": "Username",
|
6696
|
+
"output_required": false,
|
6697
|
+
"type": "string",
|
6698
|
+
"value_allowed_null": false
|
6699
|
+
},
|
6700
|
+
{
|
6701
|
+
"disabled": false,
|
6702
|
+
"document": "数据源",
|
6703
|
+
"example": "http://test.com/xx",
|
6704
|
+
"member": "string",
|
6705
|
+
"name": "Source",
|
6706
|
+
"output_required": false,
|
6707
|
+
"type": "string",
|
6708
|
+
"value_allowed_null": false
|
6709
|
+
},
|
6710
|
+
{
|
6711
|
+
"disabled": false,
|
6712
|
+
"document": "风险等级:1-低危 2-中危 3-高危 4-严重 5-误报",
|
6713
|
+
"example": "1",
|
6714
|
+
"member": "int64",
|
6715
|
+
"name": "RiskLevel",
|
6716
|
+
"output_required": false,
|
6717
|
+
"type": "int",
|
6718
|
+
"value_allowed_null": false
|
6719
|
+
},
|
6720
|
+
{
|
6721
|
+
"disabled": false,
|
6722
|
+
"document": "建议",
|
6723
|
+
"example": "建议删除",
|
6724
|
+
"member": "string",
|
6725
|
+
"name": "Suggestion",
|
6726
|
+
"output_required": false,
|
6727
|
+
"type": "string",
|
6728
|
+
"value_allowed_null": false
|
6729
|
+
},
|
6730
|
+
{
|
6731
|
+
"disabled": false,
|
6732
|
+
"document": "关键词",
|
6733
|
+
"example": "test@qq.com",
|
6734
|
+
"member": "string",
|
6735
|
+
"name": "Keyword",
|
6736
|
+
"output_required": false,
|
6737
|
+
"type": "string",
|
6738
|
+
"value_allowed_null": false
|
6739
|
+
},
|
6740
|
+
{
|
6741
|
+
"disabled": false,
|
6742
|
+
"document": "处置状态:0-待处理 1-处理中 2-已处理",
|
6743
|
+
"example": "0",
|
6744
|
+
"member": "int64",
|
6745
|
+
"name": "HandlingStatus",
|
6746
|
+
"output_required": false,
|
6747
|
+
"type": "int",
|
6748
|
+
"value_allowed_null": false
|
6749
|
+
},
|
6750
|
+
{
|
6751
|
+
"disabled": false,
|
6752
|
+
"document": "备注",
|
6753
|
+
"example": "测试数据",
|
6754
|
+
"member": "string",
|
6755
|
+
"name": "Remark",
|
6756
|
+
"output_required": false,
|
6757
|
+
"type": "string",
|
6758
|
+
"value_allowed_null": false
|
6469
6759
|
}
|
6470
6760
|
],
|
6471
6761
|
"usage": "out"
|
@@ -140,7 +140,7 @@
|
|
140
140
|
{
|
141
141
|
"document": "",
|
142
142
|
"input": "POST / HTTP/1.1\nHost: ctem.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: DescribeLeakageCodes\n<公共请求参数>\n\n{\n \"CreateAtEnd\": \"2023-02-01 12:00:00\",\n \"CreateAtStart\": \"2023-01-01 12:00:00\",\n \"CustomerId\": 1,\n \"EnterpriseUidList\": [\n \"string\"\n ],\n \"Filters\": [\n {\n \"Name\": \"string\",\n \"Values\": [\n \"string\"\n ]\n }\n ],\n \"Format\": \"json\",\n \"Ignored\": false,\n \"IsNew\": false,\n \"Limit\": 10,\n \"Offset\": 0,\n \"UpdateAtEnd\": \"2023-02-01 12:00:00\",\n \"UpdateAtStart\": \"2023-01-01 12:00:00\"\n}",
|
143
|
-
"output": "{\n \"Response\": {\n \"List\": [\n {\n \"Id\": 0,\n \"Url\": \"string\"\n }\n ],\n \"Total\": 0,\n \"RequestId\": \"3c140219-cfe9-470e-b241-907877d6fb03\"\n }\n}",
|
143
|
+
"output": "{\n \"Response\": {\n \"List\": [\n {\n \"Description\": \"string\",\n \"HandlingStatus\": 0,\n \"HubName\": \"string\",\n \"Id\": 0,\n \"Keyword\": \"string\",\n \"Name\": \"string\",\n \"Remark\": \"string\",\n \"RiskLevel\": 0,\n \"Screenshot\": \"string\",\n \"Source\": \"string\",\n \"Suggestion\": \"string\",\n \"Url\": \"string\"\n }\n ],\n \"Total\": 0,\n \"RequestId\": \"3c140219-cfe9-470e-b241-907877d6fb03\"\n }\n}",
|
144
144
|
"title": "获取代码泄露数据"
|
145
145
|
}
|
146
146
|
],
|
@@ -148,7 +148,7 @@
|
|
148
148
|
{
|
149
149
|
"document": "",
|
150
150
|
"input": "POST / HTTP/1.1\nHost: ctem.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: DescribeLeakageDatas\n<公共请求参数>\n\n{\n \"CreateAtEnd\": \"2023-02-01 12:00:00\",\n \"CreateAtStart\": \"2023-01-01 12:00:00\",\n \"CustomerId\": 1,\n \"EnterpriseUidList\": [\n \"string\"\n ],\n \"Filters\": [\n {\n \"Name\": \"string\",\n \"Values\": [\n \"string\"\n ]\n }\n ],\n \"Format\": \"json\",\n \"Ignored\": false,\n \"IsNew\": false,\n \"Limit\": 10,\n \"Offset\": 0,\n \"UpdateAtEnd\": \"2023-02-01 12:00:00\",\n \"UpdateAtStart\": \"2023-01-01 12:00:00\"\n}",
|
151
|
-
"output": "{\n \"Response\": {\n \"List\": [\n {\n \"Id\": 0,\n \"Url\": \"string\"\n }\n ],\n \"Total\": 0,\n \"RequestId\": \"3c140219-cfe9-470e-b241-907877d6fb03\"\n }\n}",
|
151
|
+
"output": "{\n \"Response\": {\n \"List\": [\n {\n \"Description\": \"string\",\n \"HandlingStatus\": 0,\n \"Id\": 0,\n \"Keyword\": \"string\",\n \"Name\": \"string\",\n \"Remark\": \"string\",\n \"RiskLevel\": 0,\n \"Screenshot\": \"string\",\n \"Source\": \"string\",\n \"Suggestion\": \"string\",\n \"Url\": \"string\"\n }\n ],\n \"Total\": 0,\n \"RequestId\": \"3c140219-cfe9-470e-b241-907877d6fb03\"\n }\n}",
|
152
152
|
"title": "获取数据泄露事件"
|
153
153
|
}
|
154
154
|
],
|
@@ -156,7 +156,7 @@
|
|
156
156
|
{
|
157
157
|
"document": "",
|
158
158
|
"input": "POST / HTTP/1.1\nHost: ctem.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: DescribeLeakageEmails\n<公共请求参数>\n\n{\n \"CreateAtEnd\": \"2023-02-01 12:00:00\",\n \"CreateAtStart\": \"2023-01-01 12:00:00\",\n \"CustomerId\": 1,\n \"EnterpriseUidList\": [\n \"string\"\n ],\n \"Filters\": [\n {\n \"Name\": \"string\",\n \"Values\": [\n \"string\"\n ]\n }\n ],\n \"Format\": \"json\",\n \"Ignored\": false,\n \"IsNew\": false,\n \"Limit\": 10,\n \"Offset\": 0,\n \"UpdateAtEnd\": \"2023-02-01 12:00:00\",\n \"UpdateAtStart\": \"2023-01-01 12:00:00\"\n}",
|
159
|
-
"output": "{\n \"Response\": {\n \"List\": [\n {\n \"Id\": 0,\n \"Email\": \"string\"\n }\n ],\n \"Total\": 0,\n \"RequestId\": \"3c140219-cfe9-470e-b241-907877d6fb03\"\n }\n}",
|
159
|
+
"output": "{\n \"Response\": {\n \"List\": [\n {\n \"Username\": \"string\",\n \"HandlingStatus\": 0,\n \"Id\": 0,\n \"Keyword\": \"string\",\n \"Email\": \"string\",\n \"Remark\": \"string\",\n \"RiskLevel\": 0,\n \"Source\": \"string\",\n \"Suggestion\": \"string\"\n }\n ],\n \"Total\": 0,\n \"RequestId\": \"3c140219-cfe9-470e-b241-907877d6fb03\"\n }\n}",
|
160
160
|
"title": "获取邮箱泄露数据"
|
161
161
|
}
|
162
162
|
],
|
tccli/services/cvm/cvm_client.py
CHANGED
@@ -693,58 +693,6 @@ def doResetInstancesType(args, parsed_globals):
|
|
693
693
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
694
694
|
|
695
695
|
|
696
|
-
def doDescribeReservedInstancesConfigInfos(args, parsed_globals):
|
697
|
-
g_param = parse_global_arg(parsed_globals)
|
698
|
-
|
699
|
-
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
700
|
-
cred = credential.CVMRoleCredential()
|
701
|
-
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
702
|
-
cred = credential.STSAssumeRoleCredential(
|
703
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
704
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
705
|
-
)
|
706
|
-
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):
|
707
|
-
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
708
|
-
else:
|
709
|
-
cred = credential.Credential(
|
710
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
711
|
-
)
|
712
|
-
http_profile = HttpProfile(
|
713
|
-
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
714
|
-
reqMethod="POST",
|
715
|
-
endpoint=g_param[OptionsDefine.Endpoint],
|
716
|
-
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
717
|
-
)
|
718
|
-
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
719
|
-
if g_param[OptionsDefine.Language]:
|
720
|
-
profile.language = g_param[OptionsDefine.Language]
|
721
|
-
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
722
|
-
client = mod.CvmClient(cred, g_param[OptionsDefine.Region], profile)
|
723
|
-
client._sdkVersion += ("_CLI_" + __version__)
|
724
|
-
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
725
|
-
model = models.DescribeReservedInstancesConfigInfosRequest()
|
726
|
-
model.from_json_string(json.dumps(args))
|
727
|
-
start_time = time.time()
|
728
|
-
while True:
|
729
|
-
rsp = client.DescribeReservedInstancesConfigInfos(model)
|
730
|
-
result = rsp.to_json_string()
|
731
|
-
try:
|
732
|
-
json_obj = json.loads(result)
|
733
|
-
except TypeError as e:
|
734
|
-
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
735
|
-
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
736
|
-
break
|
737
|
-
cur_time = time.time()
|
738
|
-
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
739
|
-
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
740
|
-
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
741
|
-
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
742
|
-
else:
|
743
|
-
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
744
|
-
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
745
|
-
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
746
|
-
|
747
|
-
|
748
696
|
def doDescribeInstanceVncUrl(args, parsed_globals):
|
749
697
|
g_param = parse_global_arg(parsed_globals)
|
750
698
|
|
@@ -797,58 +745,6 @@ def doDescribeInstanceVncUrl(args, parsed_globals):
|
|
797
745
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
798
746
|
|
799
747
|
|
800
|
-
def doInquirePricePurchaseReservedInstancesOffering(args, parsed_globals):
|
801
|
-
g_param = parse_global_arg(parsed_globals)
|
802
|
-
|
803
|
-
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
804
|
-
cred = credential.CVMRoleCredential()
|
805
|
-
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
806
|
-
cred = credential.STSAssumeRoleCredential(
|
807
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
808
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
809
|
-
)
|
810
|
-
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):
|
811
|
-
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
812
|
-
else:
|
813
|
-
cred = credential.Credential(
|
814
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
815
|
-
)
|
816
|
-
http_profile = HttpProfile(
|
817
|
-
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
818
|
-
reqMethod="POST",
|
819
|
-
endpoint=g_param[OptionsDefine.Endpoint],
|
820
|
-
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
821
|
-
)
|
822
|
-
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
823
|
-
if g_param[OptionsDefine.Language]:
|
824
|
-
profile.language = g_param[OptionsDefine.Language]
|
825
|
-
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
826
|
-
client = mod.CvmClient(cred, g_param[OptionsDefine.Region], profile)
|
827
|
-
client._sdkVersion += ("_CLI_" + __version__)
|
828
|
-
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
829
|
-
model = models.InquirePricePurchaseReservedInstancesOfferingRequest()
|
830
|
-
model.from_json_string(json.dumps(args))
|
831
|
-
start_time = time.time()
|
832
|
-
while True:
|
833
|
-
rsp = client.InquirePricePurchaseReservedInstancesOffering(model)
|
834
|
-
result = rsp.to_json_string()
|
835
|
-
try:
|
836
|
-
json_obj = json.loads(result)
|
837
|
-
except TypeError as e:
|
838
|
-
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
839
|
-
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
840
|
-
break
|
841
|
-
cur_time = time.time()
|
842
|
-
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
843
|
-
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
844
|
-
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
845
|
-
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
846
|
-
else:
|
847
|
-
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
848
|
-
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
849
|
-
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
850
|
-
|
851
|
-
|
852
748
|
def doSyncImages(args, parsed_globals):
|
853
749
|
g_param = parse_global_arg(parsed_globals)
|
854
750
|
|
@@ -2877,58 +2773,6 @@ def doInquiryPriceResetInstance(args, parsed_globals):
|
|
2877
2773
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
2878
2774
|
|
2879
2775
|
|
2880
|
-
def doPurchaseReservedInstancesOffering(args, parsed_globals):
|
2881
|
-
g_param = parse_global_arg(parsed_globals)
|
2882
|
-
|
2883
|
-
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
2884
|
-
cred = credential.CVMRoleCredential()
|
2885
|
-
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
2886
|
-
cred = credential.STSAssumeRoleCredential(
|
2887
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
2888
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
2889
|
-
)
|
2890
|
-
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):
|
2891
|
-
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
2892
|
-
else:
|
2893
|
-
cred = credential.Credential(
|
2894
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
2895
|
-
)
|
2896
|
-
http_profile = HttpProfile(
|
2897
|
-
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
2898
|
-
reqMethod="POST",
|
2899
|
-
endpoint=g_param[OptionsDefine.Endpoint],
|
2900
|
-
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
2901
|
-
)
|
2902
|
-
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
2903
|
-
if g_param[OptionsDefine.Language]:
|
2904
|
-
profile.language = g_param[OptionsDefine.Language]
|
2905
|
-
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
2906
|
-
client = mod.CvmClient(cred, g_param[OptionsDefine.Region], profile)
|
2907
|
-
client._sdkVersion += ("_CLI_" + __version__)
|
2908
|
-
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
2909
|
-
model = models.PurchaseReservedInstancesOfferingRequest()
|
2910
|
-
model.from_json_string(json.dumps(args))
|
2911
|
-
start_time = time.time()
|
2912
|
-
while True:
|
2913
|
-
rsp = client.PurchaseReservedInstancesOffering(model)
|
2914
|
-
result = rsp.to_json_string()
|
2915
|
-
try:
|
2916
|
-
json_obj = json.loads(result)
|
2917
|
-
except TypeError as e:
|
2918
|
-
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
2919
|
-
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
2920
|
-
break
|
2921
|
-
cur_time = time.time()
|
2922
|
-
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
2923
|
-
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
2924
|
-
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
2925
|
-
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
2926
|
-
else:
|
2927
|
-
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
2928
|
-
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
2929
|
-
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
2930
|
-
|
2931
|
-
|
2932
2776
|
def doModifyInstancesRenewFlag(args, parsed_globals):
|
2933
2777
|
g_param = parse_global_arg(parsed_globals)
|
2934
2778
|
|
@@ -3605,58 +3449,6 @@ def doDescribeKeyPairs(args, parsed_globals):
|
|
3605
3449
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
3606
3450
|
|
3607
3451
|
|
3608
|
-
def doDescribeReservedInstancesOfferings(args, parsed_globals):
|
3609
|
-
g_param = parse_global_arg(parsed_globals)
|
3610
|
-
|
3611
|
-
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
3612
|
-
cred = credential.CVMRoleCredential()
|
3613
|
-
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
3614
|
-
cred = credential.STSAssumeRoleCredential(
|
3615
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
3616
|
-
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
3617
|
-
)
|
3618
|
-
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):
|
3619
|
-
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
3620
|
-
else:
|
3621
|
-
cred = credential.Credential(
|
3622
|
-
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
3623
|
-
)
|
3624
|
-
http_profile = HttpProfile(
|
3625
|
-
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
3626
|
-
reqMethod="POST",
|
3627
|
-
endpoint=g_param[OptionsDefine.Endpoint],
|
3628
|
-
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
3629
|
-
)
|
3630
|
-
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
3631
|
-
if g_param[OptionsDefine.Language]:
|
3632
|
-
profile.language = g_param[OptionsDefine.Language]
|
3633
|
-
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
3634
|
-
client = mod.CvmClient(cred, g_param[OptionsDefine.Region], profile)
|
3635
|
-
client._sdkVersion += ("_CLI_" + __version__)
|
3636
|
-
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
3637
|
-
model = models.DescribeReservedInstancesOfferingsRequest()
|
3638
|
-
model.from_json_string(json.dumps(args))
|
3639
|
-
start_time = time.time()
|
3640
|
-
while True:
|
3641
|
-
rsp = client.DescribeReservedInstancesOfferings(model)
|
3642
|
-
result = rsp.to_json_string()
|
3643
|
-
try:
|
3644
|
-
json_obj = json.loads(result)
|
3645
|
-
except TypeError as e:
|
3646
|
-
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
3647
|
-
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
3648
|
-
break
|
3649
|
-
cur_time = time.time()
|
3650
|
-
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
3651
|
-
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
3652
|
-
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
3653
|
-
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
3654
|
-
else:
|
3655
|
-
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
3656
|
-
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
3657
|
-
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
3658
|
-
|
3659
|
-
|
3660
3452
|
def doInquiryPriceModifyInstancesChargeType(args, parsed_globals):
|
3661
3453
|
g_param = parse_global_arg(parsed_globals)
|
3662
3454
|
|
@@ -5345,9 +5137,7 @@ ACTION_MAP = {
|
|
5345
5137
|
"CreateImage": doCreateImage,
|
5346
5138
|
"ConfigureChcAssistVpc": doConfigureChcAssistVpc,
|
5347
5139
|
"ResetInstancesType": doResetInstancesType,
|
5348
|
-
"DescribeReservedInstancesConfigInfos": doDescribeReservedInstancesConfigInfos,
|
5349
5140
|
"DescribeInstanceVncUrl": doDescribeInstanceVncUrl,
|
5350
|
-
"InquirePricePurchaseReservedInstancesOffering": doInquirePricePurchaseReservedInstancesOffering,
|
5351
5141
|
"SyncImages": doSyncImages,
|
5352
5142
|
"ImportImage": doImportImage,
|
5353
5143
|
"DescribeZoneInstanceConfigInfos": doDescribeZoneInstanceConfigInfos,
|
@@ -5387,7 +5177,6 @@ ACTION_MAP = {
|
|
5387
5177
|
"DescribeInstancesActionTimer": doDescribeInstancesActionTimer,
|
5388
5178
|
"InquiryPriceResizeInstanceDisks": doInquiryPriceResizeInstanceDisks,
|
5389
5179
|
"InquiryPriceResetInstance": doInquiryPriceResetInstance,
|
5390
|
-
"PurchaseReservedInstancesOffering": doPurchaseReservedInstancesOffering,
|
5391
5180
|
"ModifyInstancesRenewFlag": doModifyInstancesRenewFlag,
|
5392
5181
|
"ResetInstance": doResetInstance,
|
5393
5182
|
"StartInstances": doStartInstances,
|
@@ -5401,7 +5190,6 @@ ACTION_MAP = {
|
|
5401
5190
|
"DescribeInstanceFamilyConfigs": doDescribeInstanceFamilyConfigs,
|
5402
5191
|
"ModifyInstancesProject": doModifyInstancesProject,
|
5403
5192
|
"DescribeKeyPairs": doDescribeKeyPairs,
|
5404
|
-
"DescribeReservedInstancesOfferings": doDescribeReservedInstancesOfferings,
|
5405
5193
|
"InquiryPriceModifyInstancesChargeType": doInquiryPriceModifyInstancesChargeType,
|
5406
5194
|
"DescribeInternetChargeTypeConfigs": doDescribeInternetChargeTypeConfigs,
|
5407
5195
|
"RebootInstances": doRebootInstances,
|