tencentcloud-sdk-nodejs-intl-en 3.0.365 → 3.0.366
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.
- package/package.json +1 -1
- package/tencentcloud/as/v20180419/as_client.js +64 -9
- package/tencentcloud/as/v20180419/models.js +1566 -1093
- package/tencentcloud/ckafka/v20190819/ckafka_client.js +16 -2
- package/tencentcloud/ckafka/v20190819/models.js +197 -81
- package/tencentcloud/common/sdk_version.js +1 -1
- package/tencentcloud/kms/v20190118/kms_client.js +3 -3
- package/tencentcloud/kms/v20190118/models.js +41 -11
- package/tencentcloud/vpc/v20170312/models.js +165 -17
- package/tencentcloud/vpc/v20170312/vpc_client.js +8 -8
|
@@ -84,12 +84,14 @@ const UserResponse = models.UserResponse;
|
|
|
84
84
|
const DescribeGroupInfoRequest = models.DescribeGroupInfoRequest;
|
|
85
85
|
const DescribeGroupInfoResponse = models.DescribeGroupInfoResponse;
|
|
86
86
|
const ModifyTopicAttributesResponse = models.ModifyTopicAttributesResponse;
|
|
87
|
+
const BatchContent = models.BatchContent;
|
|
87
88
|
const DeleteRouteTriggerTimeResponse = models.DeleteRouteTriggerTimeResponse;
|
|
88
89
|
const DescribeUserResponse = models.DescribeUserResponse;
|
|
89
90
|
const AppIdResponse = models.AppIdResponse;
|
|
90
91
|
const DescribeTopicRequest = models.DescribeTopicRequest;
|
|
91
92
|
const CreatePartitionRequest = models.CreatePartitionRequest;
|
|
92
93
|
const Group = models.Group;
|
|
94
|
+
const GroupInfoResponse = models.GroupInfoResponse;
|
|
93
95
|
const DescribeAppInfoResponse = models.DescribeAppInfoResponse;
|
|
94
96
|
const AclResponse = models.AclResponse;
|
|
95
97
|
const ZoneResponse = models.ZoneResponse;
|
|
@@ -119,7 +121,8 @@ const DescribeInstancesDetailRequest = models.DescribeInstancesDetailRequest;
|
|
|
119
121
|
const ModifyPasswordResponse = models.ModifyPasswordResponse;
|
|
120
122
|
const DescribeRouteRequest = models.DescribeRouteRequest;
|
|
121
123
|
const TopicInSyncReplicaResult = models.TopicInSyncReplicaResult;
|
|
122
|
-
const
|
|
124
|
+
const SendMessageResponse = models.SendMessageResponse;
|
|
125
|
+
const DescribeCkafkaZoneResponse = models.DescribeCkafkaZoneResponse;
|
|
123
126
|
const BatchModifyGroupOffsetsRequest = models.BatchModifyGroupOffsetsRequest;
|
|
124
127
|
const TopicAttributesResponse = models.TopicAttributesResponse;
|
|
125
128
|
const InstanceResponse = models.InstanceResponse;
|
|
@@ -127,10 +130,10 @@ const DescribeGroup = models.DescribeGroup;
|
|
|
127
130
|
const TopicPartitionDO = models.TopicPartitionDO;
|
|
128
131
|
const CreateTopicResp = models.CreateTopicResp;
|
|
129
132
|
const BatchModifyTopicInfo = models.BatchModifyTopicInfo;
|
|
130
|
-
const DescribeCkafkaZoneResponse = models.DescribeCkafkaZoneResponse;
|
|
131
133
|
const DescribeRouteResponse = models.DescribeRouteResponse;
|
|
132
134
|
const DescribeTopicDetailRequest = models.DescribeTopicDetailRequest;
|
|
133
135
|
const DescribeGroupOffsetsResponse = models.DescribeGroupOffsetsResponse;
|
|
136
|
+
const SendMessageRequest = models.SendMessageRequest;
|
|
134
137
|
const ConsumerRecord = models.ConsumerRecord;
|
|
135
138
|
const ModifyGroupOffsetsRequest = models.ModifyGroupOffsetsRequest;
|
|
136
139
|
const BatchModifyTopicAttributesRequest = models.BatchModifyTopicAttributesRequest;
|
|
@@ -216,6 +219,17 @@ class CkafkaClient extends AbstractClient {
|
|
|
216
219
|
this.request("BatchModifyTopicAttributes", req, resp, cb);
|
|
217
220
|
}
|
|
218
221
|
|
|
222
|
+
/**
|
|
223
|
+
* This API is used to send messages through the HTTP access layer.
|
|
224
|
+
* @param {SendMessageRequest} req
|
|
225
|
+
* @param {function(string, SendMessageResponse):void} cb
|
|
226
|
+
* @public
|
|
227
|
+
*/
|
|
228
|
+
SendMessage(req, cb) {
|
|
229
|
+
let resp = new SendMessageResponse();
|
|
230
|
+
this.request("SendMessage", req, resp, cb);
|
|
231
|
+
}
|
|
232
|
+
|
|
219
233
|
/**
|
|
220
234
|
* This API is used to modify topic attributes.
|
|
221
235
|
* @param {ModifyTopicAttributesRequest} req
|
|
@@ -3411,6 +3411,41 @@ class ModifyTopicAttributesResponse extends AbstractModel {
|
|
|
3411
3411
|
}
|
|
3412
3412
|
}
|
|
3413
3413
|
|
|
3414
|
+
/**
|
|
3415
|
+
* Message content that can be sent in batches
|
|
3416
|
+
* @class
|
|
3417
|
+
*/
|
|
3418
|
+
class BatchContent extends AbstractModel {
|
|
3419
|
+
constructor(){
|
|
3420
|
+
super();
|
|
3421
|
+
|
|
3422
|
+
/**
|
|
3423
|
+
* Message body that is sent.
|
|
3424
|
+
* @type {string || null}
|
|
3425
|
+
*/
|
|
3426
|
+
this.Body = null;
|
|
3427
|
+
|
|
3428
|
+
/**
|
|
3429
|
+
* Message sending key name.
|
|
3430
|
+
* @type {string || null}
|
|
3431
|
+
*/
|
|
3432
|
+
this.Key = null;
|
|
3433
|
+
|
|
3434
|
+
}
|
|
3435
|
+
|
|
3436
|
+
/**
|
|
3437
|
+
* @private
|
|
3438
|
+
*/
|
|
3439
|
+
deserialize(params) {
|
|
3440
|
+
if (!params) {
|
|
3441
|
+
return;
|
|
3442
|
+
}
|
|
3443
|
+
this.Body = 'Body' in params ? params.Body : null;
|
|
3444
|
+
this.Key = 'Key' in params ? params.Key : null;
|
|
3445
|
+
|
|
3446
|
+
}
|
|
3447
|
+
}
|
|
3448
|
+
|
|
3414
3449
|
/**
|
|
3415
3450
|
* DeleteRouteTriggerTime response structure.
|
|
3416
3451
|
* @class
|
|
@@ -3641,6 +3676,82 @@ class Group extends AbstractModel {
|
|
|
3641
3676
|
}
|
|
3642
3677
|
}
|
|
3643
3678
|
|
|
3679
|
+
/**
|
|
3680
|
+
* `GroupInfo` response data entity
|
|
3681
|
+
* @class
|
|
3682
|
+
*/
|
|
3683
|
+
class GroupInfoResponse extends AbstractModel {
|
|
3684
|
+
constructor(){
|
|
3685
|
+
super();
|
|
3686
|
+
|
|
3687
|
+
/**
|
|
3688
|
+
* Error code. 0: success
|
|
3689
|
+
* @type {string || null}
|
|
3690
|
+
*/
|
|
3691
|
+
this.ErrorCode = null;
|
|
3692
|
+
|
|
3693
|
+
/**
|
|
3694
|
+
* Group status description (common valid values: Empty, Stable, Dead):
|
|
3695
|
+
Dead: the consumer group does not exist
|
|
3696
|
+
Empty: there are currently no consumer subscriptions in the consumer group
|
|
3697
|
+
PreparingRebalance: the consumer group is currently in `rebalance` state
|
|
3698
|
+
CompletingRebalance: the consumer group is currently in `rebalance` state
|
|
3699
|
+
Stable: each consumer in the consumer group has joined and is in stable state
|
|
3700
|
+
* @type {string || null}
|
|
3701
|
+
*/
|
|
3702
|
+
this.State = null;
|
|
3703
|
+
|
|
3704
|
+
/**
|
|
3705
|
+
* The type of protocol selected by the consumer group, which is `consumer` for common consumers. However, some systems use their own protocols; for example, the protocol used by kafka-connect is `connect`. Only with the standard `consumer` protocol can this API get to know the specific assigning method and parse the specific partition assignment
|
|
3706
|
+
* @type {string || null}
|
|
3707
|
+
*/
|
|
3708
|
+
this.ProtocolType = null;
|
|
3709
|
+
|
|
3710
|
+
/**
|
|
3711
|
+
* Consumer partition assignment algorithm, such as `range` (which is the default value for the Kafka consumer SDK), `roundrobin`, and `sticky`
|
|
3712
|
+
* @type {string || null}
|
|
3713
|
+
*/
|
|
3714
|
+
this.Protocol = null;
|
|
3715
|
+
|
|
3716
|
+
/**
|
|
3717
|
+
* This array contains information only if `state` is `Stable` and `protocol_type` is `consumer`
|
|
3718
|
+
* @type {Array.<GroupInfoMember> || null}
|
|
3719
|
+
*/
|
|
3720
|
+
this.Members = null;
|
|
3721
|
+
|
|
3722
|
+
/**
|
|
3723
|
+
* Kafka consumer group
|
|
3724
|
+
* @type {string || null}
|
|
3725
|
+
*/
|
|
3726
|
+
this.Group = null;
|
|
3727
|
+
|
|
3728
|
+
}
|
|
3729
|
+
|
|
3730
|
+
/**
|
|
3731
|
+
* @private
|
|
3732
|
+
*/
|
|
3733
|
+
deserialize(params) {
|
|
3734
|
+
if (!params) {
|
|
3735
|
+
return;
|
|
3736
|
+
}
|
|
3737
|
+
this.ErrorCode = 'ErrorCode' in params ? params.ErrorCode : null;
|
|
3738
|
+
this.State = 'State' in params ? params.State : null;
|
|
3739
|
+
this.ProtocolType = 'ProtocolType' in params ? params.ProtocolType : null;
|
|
3740
|
+
this.Protocol = 'Protocol' in params ? params.Protocol : null;
|
|
3741
|
+
|
|
3742
|
+
if (params.Members) {
|
|
3743
|
+
this.Members = new Array();
|
|
3744
|
+
for (let z in params.Members) {
|
|
3745
|
+
let obj = new GroupInfoMember();
|
|
3746
|
+
obj.deserialize(params.Members[z]);
|
|
3747
|
+
this.Members.push(obj);
|
|
3748
|
+
}
|
|
3749
|
+
}
|
|
3750
|
+
this.Group = 'Group' in params ? params.Group : null;
|
|
3751
|
+
|
|
3752
|
+
}
|
|
3753
|
+
}
|
|
3754
|
+
|
|
3644
3755
|
/**
|
|
3645
3756
|
* DescribeAppInfo response structure.
|
|
3646
3757
|
* @class
|
|
@@ -5421,53 +5532,59 @@ class TopicInSyncReplicaResult extends AbstractModel {
|
|
|
5421
5532
|
}
|
|
5422
5533
|
|
|
5423
5534
|
/**
|
|
5424
|
-
*
|
|
5535
|
+
* SendMessage response structure.
|
|
5425
5536
|
* @class
|
|
5426
5537
|
*/
|
|
5427
|
-
class
|
|
5538
|
+
class SendMessageResponse extends AbstractModel {
|
|
5428
5539
|
constructor(){
|
|
5429
5540
|
super();
|
|
5430
5541
|
|
|
5431
5542
|
/**
|
|
5432
|
-
*
|
|
5433
|
-
* @type {string || null}
|
|
5543
|
+
* Message ID list.
|
|
5544
|
+
* @type {Array.<string> || null}
|
|
5434
5545
|
*/
|
|
5435
|
-
this.
|
|
5546
|
+
this.MessageId = null;
|
|
5436
5547
|
|
|
5437
5548
|
/**
|
|
5438
|
-
*
|
|
5439
|
-
Dead: the consumer group does not exist
|
|
5440
|
-
Empty: there are currently no consumer subscriptions in the consumer group
|
|
5441
|
-
PreparingRebalance: the consumer group is currently in `rebalance` state
|
|
5442
|
-
CompletingRebalance: the consumer group is currently in `rebalance` state
|
|
5443
|
-
Stable: each consumer in the consumer group has joined and is in stable state
|
|
5549
|
+
* The unique request ID, which is returned for each request. RequestId is required for locating a problem.
|
|
5444
5550
|
* @type {string || null}
|
|
5445
5551
|
*/
|
|
5446
|
-
this.
|
|
5552
|
+
this.RequestId = null;
|
|
5447
5553
|
|
|
5448
|
-
|
|
5449
|
-
* The type of protocol selected by the consumer group, which is `consumer` for common consumers. However, some systems use their own protocols; for example, the protocol used by kafka-connect is `connect`. Only with the standard `consumer` protocol can this API get to know the specific assigning method and parse the specific partition assignment
|
|
5450
|
-
* @type {string || null}
|
|
5451
|
-
*/
|
|
5452
|
-
this.ProtocolType = null;
|
|
5554
|
+
}
|
|
5453
5555
|
|
|
5454
|
-
|
|
5455
|
-
|
|
5456
|
-
|
|
5457
|
-
|
|
5458
|
-
|
|
5556
|
+
/**
|
|
5557
|
+
* @private
|
|
5558
|
+
*/
|
|
5559
|
+
deserialize(params) {
|
|
5560
|
+
if (!params) {
|
|
5561
|
+
return;
|
|
5562
|
+
}
|
|
5563
|
+
this.MessageId = 'MessageId' in params ? params.MessageId : null;
|
|
5564
|
+
this.RequestId = 'RequestId' in params ? params.RequestId : null;
|
|
5565
|
+
|
|
5566
|
+
}
|
|
5567
|
+
}
|
|
5568
|
+
|
|
5569
|
+
/**
|
|
5570
|
+
* DescribeCkafkaZone response structure.
|
|
5571
|
+
* @class
|
|
5572
|
+
*/
|
|
5573
|
+
class DescribeCkafkaZoneResponse extends AbstractModel {
|
|
5574
|
+
constructor(){
|
|
5575
|
+
super();
|
|
5459
5576
|
|
|
5460
5577
|
/**
|
|
5461
|
-
*
|
|
5462
|
-
* @type {
|
|
5578
|
+
* Returned results for the query
|
|
5579
|
+
* @type {ZoneResponse || null}
|
|
5463
5580
|
*/
|
|
5464
|
-
this.
|
|
5581
|
+
this.Result = null;
|
|
5465
5582
|
|
|
5466
5583
|
/**
|
|
5467
|
-
*
|
|
5584
|
+
* The unique request ID, which is returned for each request. RequestId is required for locating a problem.
|
|
5468
5585
|
* @type {string || null}
|
|
5469
5586
|
*/
|
|
5470
|
-
this.
|
|
5587
|
+
this.RequestId = null;
|
|
5471
5588
|
|
|
5472
5589
|
}
|
|
5473
5590
|
|
|
@@ -5478,20 +5595,13 @@ Stable: each consumer in the consumer group has joined and is in stable state
|
|
|
5478
5595
|
if (!params) {
|
|
5479
5596
|
return;
|
|
5480
5597
|
}
|
|
5481
|
-
this.ErrorCode = 'ErrorCode' in params ? params.ErrorCode : null;
|
|
5482
|
-
this.State = 'State' in params ? params.State : null;
|
|
5483
|
-
this.ProtocolType = 'ProtocolType' in params ? params.ProtocolType : null;
|
|
5484
|
-
this.Protocol = 'Protocol' in params ? params.Protocol : null;
|
|
5485
5598
|
|
|
5486
|
-
if (params.
|
|
5487
|
-
|
|
5488
|
-
|
|
5489
|
-
|
|
5490
|
-
obj.deserialize(params.Members[z]);
|
|
5491
|
-
this.Members.push(obj);
|
|
5492
|
-
}
|
|
5599
|
+
if (params.Result) {
|
|
5600
|
+
let obj = new ZoneResponse();
|
|
5601
|
+
obj.deserialize(params.Result)
|
|
5602
|
+
this.Result = obj;
|
|
5493
5603
|
}
|
|
5494
|
-
this.
|
|
5604
|
+
this.RequestId = 'RequestId' in params ? params.RequestId : null;
|
|
5495
5605
|
|
|
5496
5606
|
}
|
|
5497
5607
|
}
|
|
@@ -5923,46 +6033,6 @@ class BatchModifyTopicInfo extends AbstractModel {
|
|
|
5923
6033
|
}
|
|
5924
6034
|
}
|
|
5925
6035
|
|
|
5926
|
-
/**
|
|
5927
|
-
* DescribeCkafkaZone response structure.
|
|
5928
|
-
* @class
|
|
5929
|
-
*/
|
|
5930
|
-
class DescribeCkafkaZoneResponse extends AbstractModel {
|
|
5931
|
-
constructor(){
|
|
5932
|
-
super();
|
|
5933
|
-
|
|
5934
|
-
/**
|
|
5935
|
-
* Returned results for the query
|
|
5936
|
-
* @type {ZoneResponse || null}
|
|
5937
|
-
*/
|
|
5938
|
-
this.Result = null;
|
|
5939
|
-
|
|
5940
|
-
/**
|
|
5941
|
-
* The unique request ID, which is returned for each request. RequestId is required for locating a problem.
|
|
5942
|
-
* @type {string || null}
|
|
5943
|
-
*/
|
|
5944
|
-
this.RequestId = null;
|
|
5945
|
-
|
|
5946
|
-
}
|
|
5947
|
-
|
|
5948
|
-
/**
|
|
5949
|
-
* @private
|
|
5950
|
-
*/
|
|
5951
|
-
deserialize(params) {
|
|
5952
|
-
if (!params) {
|
|
5953
|
-
return;
|
|
5954
|
-
}
|
|
5955
|
-
|
|
5956
|
-
if (params.Result) {
|
|
5957
|
-
let obj = new ZoneResponse();
|
|
5958
|
-
obj.deserialize(params.Result)
|
|
5959
|
-
this.Result = obj;
|
|
5960
|
-
}
|
|
5961
|
-
this.RequestId = 'RequestId' in params ? params.RequestId : null;
|
|
5962
|
-
|
|
5963
|
-
}
|
|
5964
|
-
}
|
|
5965
|
-
|
|
5966
6036
|
/**
|
|
5967
6037
|
* DescribeRoute response structure.
|
|
5968
6038
|
* @class
|
|
@@ -6099,6 +6169,49 @@ class DescribeGroupOffsetsResponse extends AbstractModel {
|
|
|
6099
6169
|
}
|
|
6100
6170
|
}
|
|
6101
6171
|
|
|
6172
|
+
/**
|
|
6173
|
+
* SendMessage request structure.
|
|
6174
|
+
* @class
|
|
6175
|
+
*/
|
|
6176
|
+
class SendMessageRequest extends AbstractModel {
|
|
6177
|
+
constructor(){
|
|
6178
|
+
super();
|
|
6179
|
+
|
|
6180
|
+
/**
|
|
6181
|
+
* Datahub access ID.
|
|
6182
|
+
* @type {string || null}
|
|
6183
|
+
*/
|
|
6184
|
+
this.DataHubId = null;
|
|
6185
|
+
|
|
6186
|
+
/**
|
|
6187
|
+
* Message content that is sent.
|
|
6188
|
+
* @type {Array.<BatchContent> || null}
|
|
6189
|
+
*/
|
|
6190
|
+
this.Message = null;
|
|
6191
|
+
|
|
6192
|
+
}
|
|
6193
|
+
|
|
6194
|
+
/**
|
|
6195
|
+
* @private
|
|
6196
|
+
*/
|
|
6197
|
+
deserialize(params) {
|
|
6198
|
+
if (!params) {
|
|
6199
|
+
return;
|
|
6200
|
+
}
|
|
6201
|
+
this.DataHubId = 'DataHubId' in params ? params.DataHubId : null;
|
|
6202
|
+
|
|
6203
|
+
if (params.Message) {
|
|
6204
|
+
this.Message = new Array();
|
|
6205
|
+
for (let z in params.Message) {
|
|
6206
|
+
let obj = new BatchContent();
|
|
6207
|
+
obj.deserialize(params.Message[z]);
|
|
6208
|
+
this.Message.push(obj);
|
|
6209
|
+
}
|
|
6210
|
+
}
|
|
6211
|
+
|
|
6212
|
+
}
|
|
6213
|
+
}
|
|
6214
|
+
|
|
6102
6215
|
/**
|
|
6103
6216
|
* Message record
|
|
6104
6217
|
* @class
|
|
@@ -7393,12 +7506,14 @@ module.exports = {
|
|
|
7393
7506
|
DescribeGroupInfoRequest: DescribeGroupInfoRequest,
|
|
7394
7507
|
DescribeGroupInfoResponse: DescribeGroupInfoResponse,
|
|
7395
7508
|
ModifyTopicAttributesResponse: ModifyTopicAttributesResponse,
|
|
7509
|
+
BatchContent: BatchContent,
|
|
7396
7510
|
DeleteRouteTriggerTimeResponse: DeleteRouteTriggerTimeResponse,
|
|
7397
7511
|
DescribeUserResponse: DescribeUserResponse,
|
|
7398
7512
|
AppIdResponse: AppIdResponse,
|
|
7399
7513
|
DescribeTopicRequest: DescribeTopicRequest,
|
|
7400
7514
|
CreatePartitionRequest: CreatePartitionRequest,
|
|
7401
7515
|
Group: Group,
|
|
7516
|
+
GroupInfoResponse: GroupInfoResponse,
|
|
7402
7517
|
DescribeAppInfoResponse: DescribeAppInfoResponse,
|
|
7403
7518
|
AclResponse: AclResponse,
|
|
7404
7519
|
ZoneResponse: ZoneResponse,
|
|
@@ -7428,7 +7543,8 @@ module.exports = {
|
|
|
7428
7543
|
ModifyPasswordResponse: ModifyPasswordResponse,
|
|
7429
7544
|
DescribeRouteRequest: DescribeRouteRequest,
|
|
7430
7545
|
TopicInSyncReplicaResult: TopicInSyncReplicaResult,
|
|
7431
|
-
|
|
7546
|
+
SendMessageResponse: SendMessageResponse,
|
|
7547
|
+
DescribeCkafkaZoneResponse: DescribeCkafkaZoneResponse,
|
|
7432
7548
|
BatchModifyGroupOffsetsRequest: BatchModifyGroupOffsetsRequest,
|
|
7433
7549
|
TopicAttributesResponse: TopicAttributesResponse,
|
|
7434
7550
|
InstanceResponse: InstanceResponse,
|
|
@@ -7436,10 +7552,10 @@ module.exports = {
|
|
|
7436
7552
|
TopicPartitionDO: TopicPartitionDO,
|
|
7437
7553
|
CreateTopicResp: CreateTopicResp,
|
|
7438
7554
|
BatchModifyTopicInfo: BatchModifyTopicInfo,
|
|
7439
|
-
DescribeCkafkaZoneResponse: DescribeCkafkaZoneResponse,
|
|
7440
7555
|
DescribeRouteResponse: DescribeRouteResponse,
|
|
7441
7556
|
DescribeTopicDetailRequest: DescribeTopicDetailRequest,
|
|
7442
7557
|
DescribeGroupOffsetsResponse: DescribeGroupOffsetsResponse,
|
|
7558
|
+
SendMessageRequest: SendMessageRequest,
|
|
7443
7559
|
ConsumerRecord: ConsumerRecord,
|
|
7444
7560
|
ModifyGroupOffsetsRequest: ModifyGroupOffsetsRequest,
|
|
7445
7561
|
BatchModifyTopicAttributesRequest: BatchModifyTopicAttributesRequest,
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const sdkVersion = "3.0.
|
|
1
|
+
const sdkVersion = "3.0.366";
|
|
2
2
|
module.exports = sdkVersion
|
|
@@ -190,7 +190,7 @@ Key material can only be imported into CMKs in `Enabled` and `PendingImport` sta
|
|
|
190
190
|
}
|
|
191
191
|
|
|
192
192
|
/**
|
|
193
|
-
* This API is used to get the
|
|
193
|
+
* This API is used to get the public key of an asymmetric KMS key (which must be enabled). With the public key, you can encrypt messages and verify signatures.
|
|
194
194
|
* @param {GetPublicKeyRequest} req
|
|
195
195
|
* @param {function(string, GetPublicKeyResponse):void} cb
|
|
196
196
|
* @public
|
|
@@ -246,7 +246,7 @@ Key material can only be imported into CMKs in `Enabled` and `PendingImport` sta
|
|
|
246
246
|
|
|
247
247
|
/**
|
|
248
248
|
* This API is used to generate a signature with an asymmetric key.
|
|
249
|
-
Note
|
|
249
|
+
Note that only when KeyUsage is `ASYMMETRIC_SIGN_VERIFY_${ALGORITHM}` (e.g., `ASYMMETRIC_SIGN_VERIFY_SM2` and `ASYMMETRIC_SIGN_VERIFY_ECC`), the key can be used for signing.
|
|
250
250
|
* @param {SignByAsymmetricKeyRequest} req
|
|
251
251
|
* @param {function(string, SignByAsymmetricKeyResponse):void} cb
|
|
252
252
|
* @public
|
|
@@ -653,7 +653,7 @@ Note: only the keys with `KeyUsage= ASYMMETRIC_SIGN_VERIFY_SM2` can be used for
|
|
|
653
653
|
}
|
|
654
654
|
|
|
655
655
|
/**
|
|
656
|
-
* This API is used to
|
|
656
|
+
* This API is used to return all regions support KMS service.
|
|
657
657
|
* @param {GetRegionsRequest} req
|
|
658
658
|
* @param {function(string, GetRegionsResponse):void} cb
|
|
659
659
|
* @public
|
|
@@ -221,7 +221,7 @@ class CreateKeyRequest extends AbstractModel {
|
|
|
221
221
|
this.Description = null;
|
|
222
222
|
|
|
223
223
|
/**
|
|
224
|
-
*
|
|
224
|
+
* Defines the purpose of the key. The valid values are as follows: `ENCRYPT_DECRYPT` (default): creates a symmetric encryption/decryption key; `ASYMMETRIC_DECRYPT_RSA_2048`: creates an asymmetric encryption/decryption 2048-bit RSA key; `ASYMMETRIC_DECRYPT_SM2`: creates an asymmetric encryption/decryption SM2 key; `ASYMMETRIC_SIGN_VERIFY_SM2`: creates an asymmetric SM2 key for signature verification; `ASYMMETRIC_SIGN_VERIFY_ECC`: creates an asymmetric 2048-bit RSA key for signature verification; `ASYMMETRIC_SIGN_VERIFY_ECDSA384`: creates an asymmetric ECDSA384 key for signature verification. You can get a full list of supported key purposes and algorithms using the ListAlgorithms API.
|
|
225
225
|
* @type {string || null}
|
|
226
226
|
*/
|
|
227
227
|
this.KeyUsage = null;
|
|
@@ -362,13 +362,13 @@ class VerifyByAsymmetricKeyRequest extends AbstractModel {
|
|
|
362
362
|
this.SignatureValue = null;
|
|
363
363
|
|
|
364
364
|
/**
|
|
365
|
-
*
|
|
365
|
+
* Full message or message abstract. Before Base64 encoding, an original message can contain up to 4,096 bytes while a message abstract must be 32 bytes.
|
|
366
366
|
* @type {string || null}
|
|
367
367
|
*/
|
|
368
368
|
this.Message = null;
|
|
369
369
|
|
|
370
370
|
/**
|
|
371
|
-
* Signature algorithm.
|
|
371
|
+
* Signature algorithm. The valid values include `SM2DSA`, `ECC_P256_R1`, `RSA_PSS_SHA_256`, and `RSA_PKCS1_SHA_256`, etc. You can get a full list of supported algorithms using the ListAlgorithms API.
|
|
372
372
|
* @type {string || null}
|
|
373
373
|
*/
|
|
374
374
|
this.Algorithm = null;
|
|
@@ -979,6 +979,18 @@ class GenerateDataKeyRequest extends AbstractModel {
|
|
|
979
979
|
*/
|
|
980
980
|
this.EncryptionContext = null;
|
|
981
981
|
|
|
982
|
+
/**
|
|
983
|
+
* PEM-encoded public key (2048-bit RSA/SM2 key), which can be used to encrypt the `Plaintext` returned. If this field is left empty, the `Plaintext` will not be encrypted.
|
|
984
|
+
* @type {string || null}
|
|
985
|
+
*/
|
|
986
|
+
this.EncryptionPublicKey = null;
|
|
987
|
+
|
|
988
|
+
/**
|
|
989
|
+
* Asymmetric encryption algorithm. Valid values: `SM2(C1C3C2)`, `RSAES_PKCS1_V1_5`, `RSAES_OAEP_SHA_1`, and `RSAES_OAEP_SHA_256`. This field is used with `EncryptionPublicKey` for encryption. If it is left empty, a SM2 public key will be used by default.
|
|
990
|
+
* @type {string || null}
|
|
991
|
+
*/
|
|
992
|
+
this.EncryptionAlgorithm = null;
|
|
993
|
+
|
|
982
994
|
}
|
|
983
995
|
|
|
984
996
|
/**
|
|
@@ -992,6 +1004,8 @@ class GenerateDataKeyRequest extends AbstractModel {
|
|
|
992
1004
|
this.KeySpec = 'KeySpec' in params ? params.KeySpec : null;
|
|
993
1005
|
this.NumberOfBytes = 'NumberOfBytes' in params ? params.NumberOfBytes : null;
|
|
994
1006
|
this.EncryptionContext = 'EncryptionContext' in params ? params.EncryptionContext : null;
|
|
1007
|
+
this.EncryptionPublicKey = 'EncryptionPublicKey' in params ? params.EncryptionPublicKey : null;
|
|
1008
|
+
this.EncryptionAlgorithm = 'EncryptionAlgorithm' in params ? params.EncryptionAlgorithm : null;
|
|
995
1009
|
|
|
996
1010
|
}
|
|
997
1011
|
}
|
|
@@ -1243,7 +1257,7 @@ class VerifyByAsymmetricKeyResponse extends AbstractModel {
|
|
|
1243
1257
|
super();
|
|
1244
1258
|
|
|
1245
1259
|
/**
|
|
1246
|
-
* Whether the signature is valid.
|
|
1260
|
+
* Whether the signature is valid. `true`: the signature is valid; `false`: the signature is invalid.
|
|
1247
1261
|
* @type {boolean || null}
|
|
1248
1262
|
*/
|
|
1249
1263
|
this.SignatureValid = null;
|
|
@@ -1368,7 +1382,8 @@ class DecryptResponse extends AbstractModel {
|
|
|
1368
1382
|
this.KeyId = null;
|
|
1369
1383
|
|
|
1370
1384
|
/**
|
|
1371
|
-
*
|
|
1385
|
+
* If `EncryptionPublicKey` is left empty, a Base64-encoded ciphertext will be returned. To get the plaintext, you need to decode the ciphertext first.
|
|
1386
|
+
If `EncryptionPublicKey` is specified, this field will return the Base64-encoded ciphertext encrypted with the specified public key. To get the plaintext, you need to decode the ciphertext and upload the corresponding private key.
|
|
1372
1387
|
* @type {string || null}
|
|
1373
1388
|
*/
|
|
1374
1389
|
this.Plaintext = null;
|
|
@@ -1932,7 +1947,7 @@ class ListKeyDetailRequest extends AbstractModel {
|
|
|
1932
1947
|
this.Origin = null;
|
|
1933
1948
|
|
|
1934
1949
|
/**
|
|
1935
|
-
*
|
|
1950
|
+
* Filters by the `KeyUsage` field value. Valid values: `ALL` (all CMKs), `ENCRYPT_DECRYPT` (used when this field is left empty), `ASYMMETRIC_DECRYPT_RSA_2048`, `ASYMMETRIC_DECRYPT_SM2`, `ASYMMETRIC_SIGN_VERIFY_SM2`, `ASYMMETRIC_SIGN_VERIFY_RSA_2048`, and `ASYMMETRIC_SIGN_VERIFY_ECC`.
|
|
1936
1951
|
* @type {string || null}
|
|
1937
1952
|
*/
|
|
1938
1953
|
this.KeyUsage = null;
|
|
@@ -2087,7 +2102,8 @@ class GenerateDataKeyResponse extends AbstractModel {
|
|
|
2087
2102
|
this.KeyId = null;
|
|
2088
2103
|
|
|
2089
2104
|
/**
|
|
2090
|
-
*
|
|
2105
|
+
* If `EncryptionPublicKey` is left empty, a Base64-encoded ciphertext will be returned. To get the plaintext, you need to decode the ciphertext first.
|
|
2106
|
+
If `EncryptionPublicKey` is specified, this field will return the Base64-encoded ciphertext encrypted with the specified public key. To get the plaintext, you need to decode the ciphertext and upload the corresponding private key.
|
|
2091
2107
|
* @type {string || null}
|
|
2092
2108
|
*/
|
|
2093
2109
|
this.Plaintext = null;
|
|
@@ -2453,7 +2469,7 @@ class EncryptResponse extends AbstractModel {
|
|
|
2453
2469
|
super();
|
|
2454
2470
|
|
|
2455
2471
|
/**
|
|
2456
|
-
* Base64-encoded encrypted ciphertext
|
|
2472
|
+
* Base64-encoded ciphertext, which is the encrypted information of the ciphertext and key. To get the plaintext, you need to pass in this field to the Decrypt API.
|
|
2457
2473
|
* @type {string || null}
|
|
2458
2474
|
*/
|
|
2459
2475
|
this.CiphertextBlob = null;
|
|
@@ -2928,7 +2944,7 @@ class KeyMetadata extends AbstractModel {
|
|
|
2928
2944
|
this.KeyState = null;
|
|
2929
2945
|
|
|
2930
2946
|
/**
|
|
2931
|
-
* CMK purpose. Valid values: `ENCRYPT_DECRYPT`, `ASYMMETRIC_DECRYPT_RSA_2048`, `ASYMMETRIC_DECRYPT_SM2`, and `
|
|
2947
|
+
* CMK purpose. Valid values: `ENCRYPT_DECRYPT`, `ASYMMETRIC_DECRYPT_RSA_2048`, `ASYMMETRIC_DECRYPT_SM2`, `ASYMMETRIC_SIGN_VERIFY_SM2`, `ASYMMETRIC_SIGN_VERIFY_RSA_2048`, and `ASYMMETRIC_SIGN_VERIFY_ECC`.
|
|
2932
2948
|
* @type {string || null}
|
|
2933
2949
|
*/
|
|
2934
2950
|
this.KeyUsage = null;
|
|
@@ -3065,6 +3081,18 @@ class DecryptRequest extends AbstractModel {
|
|
|
3065
3081
|
*/
|
|
3066
3082
|
this.EncryptionContext = null;
|
|
3067
3083
|
|
|
3084
|
+
/**
|
|
3085
|
+
* PEM-encoded public key (2048-bit RSA/SM2 key), which can be used to encrypt the `Plaintext` returned. If this field is left empty, the `Plaintext` will not be encrypted.
|
|
3086
|
+
* @type {string || null}
|
|
3087
|
+
*/
|
|
3088
|
+
this.EncryptionPublicKey = null;
|
|
3089
|
+
|
|
3090
|
+
/**
|
|
3091
|
+
* Asymmetric encryption algorithm. Valid values: `SM2(C1C3C2)`, `RSAES_PKCS1_V1_5`, `RSAES_OAEP_SHA_1`, and `RSAES_OAEP_SHA_256`. This field is used in combination with `EncryptionPublicKey` for encryption. If it is left empty, a SM2 public key will be used by default.
|
|
3092
|
+
* @type {string || null}
|
|
3093
|
+
*/
|
|
3094
|
+
this.EncryptionAlgorithm = null;
|
|
3095
|
+
|
|
3068
3096
|
}
|
|
3069
3097
|
|
|
3070
3098
|
/**
|
|
@@ -3076,6 +3104,8 @@ class DecryptRequest extends AbstractModel {
|
|
|
3076
3104
|
}
|
|
3077
3105
|
this.CiphertextBlob = 'CiphertextBlob' in params ? params.CiphertextBlob : null;
|
|
3078
3106
|
this.EncryptionContext = 'EncryptionContext' in params ? params.EncryptionContext : null;
|
|
3107
|
+
this.EncryptionPublicKey = 'EncryptionPublicKey' in params ? params.EncryptionPublicKey : null;
|
|
3108
|
+
this.EncryptionAlgorithm = 'EncryptionAlgorithm' in params ? params.EncryptionAlgorithm : null;
|
|
3079
3109
|
|
|
3080
3110
|
}
|
|
3081
3111
|
}
|
|
@@ -3448,13 +3478,13 @@ class SignByAsymmetricKeyRequest extends AbstractModel {
|
|
|
3448
3478
|
super();
|
|
3449
3479
|
|
|
3450
3480
|
/**
|
|
3451
|
-
* Signature algorithm.
|
|
3481
|
+
* Signature algorithm. The valid values include `SM2DSA`, `ECC_P256_R1`, `RSA_PSS_SHA_256`, and `RSA_PKCS1_SHA_256`, etc. You can get a full list of supported algorithms using the ListAlgorithms API.
|
|
3452
3482
|
* @type {string || null}
|
|
3453
3483
|
*/
|
|
3454
3484
|
this.Algorithm = null;
|
|
3455
3485
|
|
|
3456
3486
|
/**
|
|
3457
|
-
*
|
|
3487
|
+
* Full message or message abstract. Before Base64 encoding, an original message can contain up to 4,096 bytes while a message abstract must be 32 bytes.
|
|
3458
3488
|
* @type {string || null}
|
|
3459
3489
|
*/
|
|
3460
3490
|
this.Message = null;
|