tencentcloud-sdk-nodejs-mqtt 4.1.6 → 4.1.7

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tencentcloud-sdk-nodejs-mqtt",
3
- "version": "4.1.6",
3
+ "version": "4.1.7",
4
4
  "description": "腾讯云 API NODEJS SDK",
5
5
  "main": "./tencentcloud/index.js",
6
6
  "module": "./es/index.js",
@@ -198,7 +198,7 @@ export declare class Client extends TencentCloudCommon.AbstractClient {
198
198
  */
199
199
  ActivateCaCertificate(req: ActivateCaCertificateRequest, cb?: (error: string, rep: ActivateCaCertificateResponse) => void): Promise<ActivateCaCertificateResponse>;
200
200
  /**
201
- * 查询消息列表,如查询死信,请设置ConsumerGroup参数
201
+ * 根据一级Topic查询消息列表
202
202
  */
203
203
  DescribeMessageList(req: DescribeMessageListRequest, cb?: (error: string, rep: DescribeMessageListResponse) => void): Promise<DescribeMessageListResponse>;
204
204
  /**
@@ -218,7 +218,7 @@ export declare class Client extends TencentCloudCommon.AbstractClient {
218
218
  */
219
219
  CreateAuthorizationPolicy(req: CreateAuthorizationPolicyRequest, cb?: (error: string, rep: CreateAuthorizationPolicyResponse) => void): Promise<CreateAuthorizationPolicyResponse>;
220
220
  /**
221
- * 修改实例属性
221
+ * 修改实例属性,只有运行中的集群可以调用该接口进行变更配置。
222
222
  */
223
223
  ModifyInstance(req: ModifyInstanceRequest, cb?: (error: string, rep: ModifyInstanceResponse) => void): Promise<ModifyInstanceResponse>;
224
224
  /**
@@ -310,7 +310,7 @@ class Client extends TencentCloudCommon.AbstractClient {
310
310
  return this.request("ActivateCaCertificate", req, cb);
311
311
  }
312
312
  /**
313
- * 查询消息列表,如查询死信,请设置ConsumerGroup参数
313
+ * 根据一级Topic查询消息列表
314
314
  */
315
315
  async DescribeMessageList(req, cb) {
316
316
  return this.request("DescribeMessageList", req, cb);
@@ -340,7 +340,7 @@ class Client extends TencentCloudCommon.AbstractClient {
340
340
  return this.request("CreateAuthorizationPolicy", req, cb);
341
341
  }
342
342
  /**
343
- * 修改实例属性
343
+ * 修改实例属性,只有运行中的集群可以调用该接口进行变更配置。
344
344
  */
345
345
  async ModifyInstance(req, cb) {
346
346
  return this.request("ModifyInstance", req, cb);
@@ -163,31 +163,31 @@ export interface ApplyRegistrationCodeRequest {
163
163
  */
164
164
  export interface DescribeMessageListRequest {
165
165
  /**
166
- * 实例ID
166
+ * 腾讯云MQTT实例ID,从 [DescribeInstanceList](https://cloud.tencent.com/document/api/1778/111029)接口或控制台获得。
167
167
  */
168
168
  InstanceId: string;
169
169
  /**
170
- * 主题
170
+ * 要查询的一级Topic,可从 [查询MQTT主题列表](https://cloud.tencent.com/document/product/1778/111082) 获取。
171
171
  */
172
172
  Topic: string;
173
173
  /**
174
- * 开始时间
174
+ * 开始时间,毫秒级时间戳 。
175
175
  */
176
176
  StartTime: number;
177
177
  /**
178
- * 结束时间
178
+ * 结束时间,毫秒级时间戳 。
179
179
  */
180
180
  EndTime: number;
181
181
  /**
182
- * 请求任务id
182
+ * 请求任务id,用于相同查询参数下查询加速,第一次查询时无需传递,第一次查询会根据本次查询参数生成查询任务ID,保留查询条件,查询下一页消息时可传递第一次查询返回的任务ID。
183
183
  */
184
184
  TaskRequestId: string;
185
185
  /**
186
- * 查询起始位置
186
+ * 查询起始位置,默认0
187
187
  */
188
188
  Offset?: number;
189
189
  /**
190
- * 查询结果限制数量
190
+ * 查询结果限制数量,默认20,最大50
191
191
  */
192
192
  Limit?: number;
193
193
  }
@@ -560,19 +560,20 @@ export interface DeleteInstanceRequest {
560
560
  */
561
561
  export interface ModifyInstanceRequest {
562
562
  /**
563
- * 实例ID
563
+ * 腾讯云MQTT实例ID,从 [DescribeInstanceList](https://cloud.tencent.com/document/api/1778/111029)接口或控制台获得。
564
564
  */
565
565
  InstanceId: string;
566
566
  /**
567
- * 要修改实例名称
567
+ * 要修改实例名称,不能为空, 3-64个字符,只能包含数字、字母、“-”和“_”。
568
568
  */
569
569
  Name?: string;
570
570
  /**
571
- * 要修改的备注信息
571
+ * 要修改的备注信息,最多64个字符。
572
572
  */
573
573
  Remark?: string;
574
574
  /**
575
- * 要变更的配置规格
575
+ * 需要变更的配置规格
576
+ 基础版和增强版集群不能升配到铂金版规格,铂金版集群不能降配至基础版和增强版规格。
576
577
  */
577
578
  SkuCode?: string;
578
579
  /**
@@ -585,6 +586,10 @@ export interface ModifyInstanceRequest {
585
586
  * 自动注册证书是否自动激活
586
587
  */
587
588
  AutomaticActivation?: boolean;
589
+ /**
590
+ * 授权策略开关
591
+ */
592
+ AuthorizationPolicy?: boolean;
588
593
  }
589
594
  /**
590
595
  * RegisterDeviceCertificate返回参数结构体
@@ -607,16 +612,35 @@ export interface MQTTAuthenticatorItem {
607
612
  */
608
613
  Type?: string;
609
614
  /**
610
- * HTTP认证器
615
+ * JWT认证器字段说明
616
+ from(认证字段)
617
+ password:从password字段获取认证字段
618
+ username:从username字段获取认证字段
619
+ secret(签名方式)
620
+ hmac-based:hmac-based签名方式
621
+ public-key:public-key签名方式
622
+ secret(密钥),hmac-based需要配置密钥
623
+ public-key(公钥),public-key签名方式需要配置
624
+ 样例:{"from":"password","secret":"secret282698","algorithm":"hmac-based"}
625
+
626
+ JWKS认证器字段说明
627
+ endpoint(接入点):公钥获取服务器接入地址
628
+ refreshInterval(认证内容):公钥集合刷新周期
629
+ from(认证字段)
630
+ password:从password字段获取认证字段
631
+ username:从username字段获取认证字段
632
+ text:公钥集合
633
+ 样例:{"endpoint":"127.0.0.1","refreshInterval":60,"from":"password"}
634
+
635
+ HTTP认证器
611
636
  headers(请求头):标准请求头和自定义请求头
612
637
  endpoint(接入点):认证服务器接入点
613
638
  method(http请求方法):POST/GET
614
639
  readTimeout(读超时时间):读取认证服务器数据超时时间,单位秒
615
640
  connectTimeout(连接超时时间):连接认证服务器超时时间,单位秒
616
641
  body(请求体):http请求体
617
- concurrency(并发数):最大并发请求数
642
+ concurrency(并发数):最大并发请求数量
618
643
  样例:{"headers":[{"key":"Content-type","value":"application/json"},{"key":"username","value":"${Username}"}],"endpoint":"https://127.0.0.1:443","method":"POST","readTimeout":10,"connectTimeout":10,"body":[{"key":"client-id","value":"${ClientId}"}],"concurrency":8}
619
-
620
644
  参考 [认证管理概述](https://cloud.tencent.com/document/product/1778/114813)
621
645
  */
622
646
  Config?: string;
@@ -877,7 +901,7 @@ export interface MQTTMessageItem {
877
901
  */
878
902
  ProducerAddr?: string;
879
903
  /**
880
- * 消息发送时间
904
+ * 消息发送时间,格式 日期时间:YYYY-MM-DD hh:mm:ss
881
905
  */
882
906
  ProduceTime?: string;
883
907
  /**
@@ -894,6 +918,9 @@ export interface MQTTMessageItem {
894
918
  SubTopic?: string;
895
919
  /**
896
920
  * 消息质量等级
921
+ 0:至多一次
922
+ 1:至少一次
923
+ 2:精确一次
897
924
  */
898
925
  Qos?: string;
899
926
  }
@@ -929,55 +956,66 @@ export interface CreateUserResponse {
929
956
  */
930
957
  export interface CreateAuthorizationPolicyRequest {
931
958
  /**
932
- * 实例ID
959
+ * 腾讯云MQTT实例ID,从 [DescribeInstanceList](https://cloud.tencent.com/document/api/1778/111029)接口或控制台获得。
933
960
  */
934
961
  InstanceId: string;
935
962
  /**
936
- * 策略名称
963
+ * 策略名称,不能为空,3-64个字符,支持中文、字母、数字、“-”及“_”。
937
964
  */
938
965
  PolicyName: string;
939
966
  /**
940
- * 策略版本
967
+ * 策略版本,默认为1,当前仅支持1
941
968
  */
942
969
  PolicyVersion: number;
943
970
  /**
944
- * 策略优先级,越小越优先
971
+ * 策略优先级,越小越优先,不能重复
945
972
  */
946
973
  Priority: number;
947
974
  /**
948
- * allow、deny
975
+ * 决策:
976
+ allow 允许
977
+ deny 拒绝
949
978
  */
950
979
  Effect: string;
951
980
  /**
952
- * connect、pub、sub
981
+ * 操作
982
+ connect:连接
983
+ pub:发布
984
+ sub:订阅
953
985
  */
954
986
  Actions: string;
955
987
  /**
956
- * 1,匹配保留消息;2,匹配非保留消息,3.匹配所有消息
988
+ * 条件-保留消息
989
+ 1,匹配保留消息;
990
+ 2,匹配非保留消息,
991
+ 3.匹配保留和非保留消息
957
992
  */
958
993
  Retain: number;
959
994
  /**
960
- * 0、1、2
995
+ * 条件:服务质量
996
+ 0:最多一次
997
+ 1:最少一次
998
+ 2:精确一次
961
999
  */
962
1000
  Qos: string;
963
1001
  /**
964
- * 资源
1002
+ * 资源,需要匹配的订阅
965
1003
  */
966
1004
  Resources?: string;
967
1005
  /**
968
- * 用户名
1006
+ * 条件-用户名
969
1007
  */
970
1008
  Username?: string;
971
1009
  /**
972
- * 客户端
1010
+ * 条件:客户端ID,支持正则
973
1011
  */
974
1012
  ClientId?: string;
975
1013
  /**
976
- * IP地址
1014
+ * 条件:客户端IP地址,支持IP或者CIDR
977
1015
  */
978
1016
  Ip?: string;
979
1017
  /**
980
- * 备注信息
1018
+ * 备注信息,最长 128 字符
981
1019
  */
982
1020
  Remark?: string;
983
1021
  }
@@ -1577,6 +1615,14 @@ export interface RevokedDeviceCertificateRequest {
1577
1615
  * CreateAuthorizationPolicy返回参数结构体
1578
1616
  */
1579
1617
  export interface CreateAuthorizationPolicyResponse {
1618
+ /**
1619
+ * 集群Id
1620
+ */
1621
+ InstanceId?: string;
1622
+ /**
1623
+ * 策略id
1624
+ */
1625
+ Id?: number;
1580
1626
  /**
1581
1627
  * 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
1582
1628
  */
@@ -1819,6 +1865,7 @@ export interface DescribeInstanceResponse {
1819
1865
  * 实例类型
1820
1866
  BASIC 基础版
1821
1867
  PRO 专业版
1868
+ PLATINUM 铂金版
1822
1869
  */
1823
1870
  InstanceType?: string;
1824
1871
  /**
@@ -1850,7 +1897,7 @@ export interface DescribeInstanceResponse {
1850
1897
  */
1851
1898
  Remark?: string;
1852
1899
  /**
1853
- * 实例状态
1900
+ * 实例状态, RUNNING, 运行中 MAINTAINING,维护中 ABNORMAL,异常 OVERDUE,欠费 DESTROYED,已删除 CREATING,创建中 MODIFYING,变配中 CREATE_FAILURE,创建失败 MODIFY_FAILURE,变配失败 DELETING,删除中
1854
1901
  */
1855
1902
  InstanceStatus?: string;
1856
1903
  /**
@@ -1880,7 +1927,7 @@ export interface DescribeInstanceResponse {
1880
1927
  */
1881
1928
  AutomaticActivation?: boolean;
1882
1929
  /**
1883
- * 是否自动续费
1930
+ * 是否自动续费。仅包年包月集群生效。 1:自动续费 0:非自动续费
1884
1931
  */
1885
1932
  RenewFlag?: number;
1886
1933
  /**
@@ -1888,11 +1935,11 @@ export interface DescribeInstanceResponse {
1888
1935
  */
1889
1936
  PayMode?: string;
1890
1937
  /**
1891
- * 到期时间,秒为单位
1938
+ * 到期时间,毫秒级时间戳
1892
1939
  */
1893
1940
  ExpiryTime?: number;
1894
1941
  /**
1895
- * 预销毁时间
1942
+ * 预销毁时间,毫秒级时间戳
1896
1943
  */
1897
1944
  DestroyTime?: number;
1898
1945
  /**
@@ -1911,6 +1958,10 @@ export interface DescribeInstanceResponse {
1911
1958
  * 集群最大订阅数
1912
1959
  */
1913
1960
  MaxSubscription?: number;
1961
+ /**
1962
+ * 授权策略开关
1963
+ */
1964
+ AuthorizationPolicy?: boolean;
1914
1965
  /**
1915
1966
  * 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
1916
1967
  */
@@ -2372,7 +2423,7 @@ export interface MQTTClientInfo {
2372
2423
  * MQTT 协议版本
2373
2424
  3:表示MQTT 3.1版本
2374
2425
  4:表示 MQTT 3.1.1
2375
- 5: 标识MQTT 5.0协议
2426
+ 5:表示MQTT 5.0协议
2376
2427
  */
2377
2428
  ProtocolVersion?: number;
2378
2429
  /**
@@ -2605,7 +2656,7 @@ export interface ModifyHttpAuthenticatorRequest {
2605
2656
  */
2606
2657
  export interface DescribeInstanceRequest {
2607
2658
  /**
2608
- * 实例ID
2659
+ * 实例ID [DescribeInstanceList](https://cloud.tencent.com/document/api/1778/111029)
2609
2660
  */
2610
2661
  InstanceId: string;
2611
2662
  }