@ray-js/api 1.7.79 → 1.7.80

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 (56) hide show
  1. package/@types/AIKit.d.ts +1140 -1009
  2. package/@types/AVideoKit.d.ts +26 -101
  3. package/@types/BaseKit.d.ts +234 -210
  4. package/@types/BizKit.d.ts +271 -296
  5. package/@types/DeviceKit.d.ts +57 -88
  6. package/@types/GroupCITestKit.d.ts +1 -3
  7. package/@types/HealthKit.d.ts +273 -230
  8. package/@types/HomeKit.d.ts +1062 -891
  9. package/@types/IPCKit.d.ts +23 -50
  10. package/@types/LightKit.d.ts +2 -2
  11. package/@types/MapKit.d.ts +592 -381
  12. package/@types/MediaPlayerKit.d.ts +4 -28
  13. package/@types/MiniKit.d.ts +198 -375
  14. package/@types/P2PKit.d.ts +139 -205
  15. package/@types/PayKit.d.ts +10 -79
  16. package/@types/SweeperKit.d.ts +10 -10
  17. package/@types/ThirdAuthKit.d.ts +28 -252
  18. package/@types/WearKit.d.ts +630 -1593
  19. package/@types/api-extend.d.ts +0 -63
  20. package/lib/AIKit-1.6.0.d.ts +732 -35
  21. package/lib/AIKit-1.6.0.js +732 -51
  22. package/lib/BaseKit-3.17.7.d.ts +0 -214
  23. package/lib/BaseKit-3.17.7.js +1 -227
  24. package/lib/DeviceKit-4.13.1.d.ts +3666 -0
  25. package/lib/DeviceKit-4.13.1.js +3666 -0
  26. package/lib/HealthKit-6.5.0.d.ts +603 -0
  27. package/lib/HealthKit-6.5.0.js +603 -0
  28. package/lib/HomeKit-3.1.4.d.ts +4 -0
  29. package/lib/HomeKit-3.1.4.js +4 -0
  30. package/lib/IPCKit-6.4.5.d.ts +0 -1
  31. package/lib/IPCKit-6.4.5.js +0 -1
  32. package/lib/MapKit-3.4.13.d.ts +251 -0
  33. package/lib/MapKit-3.4.13.js +251 -0
  34. package/lib/MediaKit-3.4.1.d.ts +16 -0
  35. package/lib/MediaKit-3.4.1.js +16 -0
  36. package/lib/PlayNetKit-1.3.30.d.ts +930 -0
  37. package/lib/PlayNetKit-1.3.30.js +930 -0
  38. package/lib/cloud/alarm.d.ts +38 -5
  39. package/lib/cloud/alarm.js +38 -5
  40. package/lib/cloud/device.d.ts +42 -6
  41. package/lib/cloud/device.js +42 -6
  42. package/lib/cloud/gateway.d.ts +16 -0
  43. package/lib/cloud/gateway.js +16 -0
  44. package/lib/cloud/health.d.ts +1 -0
  45. package/lib/cloud/health.js +272 -0
  46. package/lib/cloud/interface.d.ts +161 -0
  47. package/lib/cloud/interface.js +18 -0
  48. package/lib/cloud/statistic.d.ts +112 -26
  49. package/lib/cloud/statistic.js +112 -26
  50. package/lib/cloud/timer.d.ts +2 -4
  51. package/lib/nativeRouters/outdoors.d.ts +2 -0
  52. package/lib/nativeRouters/outdoors.js +2 -0
  53. package/lib/nativeRouters/remoteGroup.d.ts +2 -0
  54. package/lib/nativeRouters/remoteGroup.js +2 -0
  55. package/lib/panel/publishDps.js +1 -1
  56. package/package.json +5 -5
@@ -5,111 +5,42 @@
5
5
  */
6
6
  declare namespace ty.pay {
7
7
  /**
8
- * 支付宝快登授权2.0
9
- * @public
10
- * @since PayKit 0.2.0
11
- * @platform iOS Android
12
- */
8
+ *@description 支付宝快登授权2.0*/
13
9
  export function alipayAuth(params: {
14
- /**
15
- * 授权请求信息字串
16
- * @since PayKit 0.2.0
17
- */
10
+ /** 授权请求信息字串 */
18
11
  info: string
19
- /** 接口调用结束的回调函数(调用成功、失败都会执行) */
20
- complete?: () => void
21
- /** 接口调用成功的回调函数 */
22
12
  success?: (params: {
23
- /**
24
- * 结果
25
- * @since PayKit 0.2.0
26
- */
27
- result: Record<any, any>
13
+ /** 结果 */
14
+ result: any
28
15
  }) => void
29
- /** 接口调用失败的回调函数 */
30
16
  fail?: (params: {
31
- /** 错误信息 */
32
17
  errorMsg: string
33
- /** 错误码 */
34
18
  errorCode: string | number
35
- /** 错误扩展 */
36
19
  innerError: {
37
- /** 错误扩展码 */
38
20
  errorCode: string | number
39
- /** 错误扩展信息 */
40
21
  errorMsg: string
41
22
  }
42
23
  }) => void
24
+ complete?: () => void
43
25
  }): void
44
26
 
45
27
  /**
46
- * 支付宝支付接口
47
- * @public
48
- * @since PayKit 0.2.0
49
- * @platform iOS Android
50
- */
28
+ *@description 支付宝支付接口*/
51
29
  export function alipayPay(params: {
52
- /**
53
- * 支付订单信息字串
54
- * @since PayKit 0.2.0
55
- */
30
+ /** 支付订单信息字串 */
56
31
  order: string
57
- /** 接口调用结束的回调函数(调用成功、失败都会执行) */
58
- complete?: () => void
59
- /** 接口调用成功的回调函数 */
60
32
  success?: (params: {
61
- /**
62
- * 结果
63
- * @since PayKit 0.2.0
64
- */
65
- result: Record<any, any>
33
+ /** 结果 */
34
+ result: any
66
35
  }) => void
67
- /** 接口调用失败的回调函数 */
68
36
  fail?: (params: {
69
- /** 错误信息 */
70
37
  errorMsg: string
71
- /** 错误码 */
72
38
  errorCode: string | number
73
- /** 错误扩展 */
74
39
  innerError: {
75
- /** 错误扩展码 */
76
40
  errorCode: string | number
77
- /** 错误扩展信息 */
78
41
  errorMsg: string
79
42
  }
80
43
  }) => void
44
+ complete?: () => void
81
45
  }): void
82
-
83
- /**
84
- * 授权请求
85
- * @since PayKit 0.2.0
86
- */
87
- export interface AuthRequestParams {
88
- /**
89
- * 授权请求信息字串
90
- * @since PayKit 0.2.0
91
- */
92
- info: string
93
- }
94
-
95
- /** @since PayKit 0.2.0 */
96
- export interface Response {
97
- /**
98
- * 结果
99
- * @since PayKit 0.2.0
100
- */
101
- result: Record<any, any>
102
- }
103
-
104
- /**
105
- * 支付请求
106
- * @since PayKit 0.2.0
107
- */
108
- export interface PayRequestParams {
109
- /**
110
- * 支付订单信息字串
111
- * @since PayKit 0.2.0
112
- */
113
- order: string
114
- }
115
46
  }
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * SweeperKit
3
3
  *
4
- * @version 2.0.1
4
+ * @version 2.0.0
5
5
  */
6
6
  declare namespace ty.sweeper {
7
7
  /**
@@ -27,17 +27,17 @@ declare namespace ty.sweeper {
27
27
  */
28
28
  height: number
29
29
  /**
30
- * 清扫点坐标数据
30
+ * 清扫点
31
31
  * @since SweeperKit 0.1.1
32
32
  */
33
33
  sweeper: string
34
34
  /**
35
- * 障碍点坐标数据
35
+ * 障碍点
36
36
  * @since SweeperKit 0.1.1
37
37
  */
38
38
  barrier: string
39
39
  /**
40
- * 未知区域坐标数据
40
+ * 未知点
41
41
  * @since SweeperKit 0.1.1
42
42
  */
43
43
  unknown: string
@@ -84,17 +84,17 @@ declare namespace ty.sweeper {
84
84
  */
85
85
  height: number
86
86
  /**
87
- * 清扫点坐标数据
87
+ * 清扫点
88
88
  * @since SweeperKit 0.1.1
89
89
  */
90
90
  sweeper: string
91
91
  /**
92
- * 障碍点坐标数据
92
+ * 障碍点
93
93
  * @since SweeperKit 0.1.1
94
94
  */
95
95
  barrier: string
96
96
  /**
97
- * 未知区域坐标数据
97
+ * 未知点
98
98
  * @since SweeperKit 0.1.1
99
99
  */
100
100
  unknown: string
@@ -136,17 +136,17 @@ declare namespace ty.sweeper {
136
136
  */
137
137
  height: number
138
138
  /**
139
- * 清扫点坐标数据
139
+ * 清扫点
140
140
  * @since SweeperKit 0.1.1
141
141
  */
142
142
  sweeper: string
143
143
  /**
144
- * 障碍点坐标数据
144
+ * 障碍点
145
145
  * @since SweeperKit 0.1.1
146
146
  */
147
147
  barrier: string
148
148
  /**
149
- * 未知区域坐标数据
149
+ * 未知点
150
150
  * @since SweeperKit 0.1.1
151
151
  */
152
152
  unknown: string
@@ -1,324 +1,100 @@
1
1
  /**
2
2
  * ThirdAuthKit
3
3
  *
4
- * @version 1.0.14
4
+ * @version 1.0.1
5
5
  */
6
6
  declare namespace ty.thirdauth {
7
7
  /**
8
- * QQ音乐授权
9
- * @description.en QQ Music authorization.
10
- * @public
11
- * @since WearKit 1.0.0
12
- * @remarks 注意:WearKit(2.1.0)起下该方法已过时,请使用ThirdAuthKit下同名方法
13
- * @remarksEn Note: Deprecated since WearKit 2.1.0, use the same method in ThirdAuthKit.
14
- * @example 基础用法
15
- * ```tsx
16
- * `ty.wear.qqMusicAuth({
17
- * params: { type: 0 },
18
- * success: (result) => {
19
- * console.log('qqMusicAuth success', result);
20
- * },
21
- * fail: (error) => {
22
- * console.log('qqMusicAuth fail', error.errorMsg);
23
- * },
24
- * });`
25
- * ```
26
- * @see https://developer.tuya.com/
27
- * @platform iOS Android
28
- * @error {10001} 参数错误
29
- * @error {10002} 授权失败
30
- * @error {10003} 解密失败
31
- * @error {10004} JSON解析错误
32
- * @error {10005} 签名校验失败
33
- * @error {10006} 不支持的授权类型
34
- */
8
+ *@description QQ音乐授权
9
+ *注意:WearKit(2.1.0)起下该方法已过时,请使用ThirdAuthKit下同名方法*/
35
10
  export function qqMusicAuth(params: {
36
- /**
37
- * 第三方服务类型,参见 ThirdPartyType 枚举
38
- * @since ThirdAuthKit 1.0.0
39
- */
11
+ /** 三方服务列表 ThirdPartyType */
40
12
  type: number
41
- /** 接口调用结束的回调函数(调用成功、失败都会执行) */
42
- complete?: () => void
43
- /** 接口调用成功的回调函数 */
44
13
  success?: (params: {
45
- /**
46
- * 过期时间(Unix 时间戳,单位:秒)
47
- * @since ThirdAuthKit 1.0.0
48
- */
14
+ /** 过期时间 */
49
15
  expireTime: number
50
- /**
51
- * QQ音乐账户 openId
52
- * @since ThirdAuthKit 1.0.0
53
- */
16
+ /** openId */
54
17
  openId: string
55
- /**
56
- * QQ音乐访问令牌
57
- * @since ThirdAuthKit 1.0.0
58
- */
18
+ /** openToken */
59
19
  openToken: string
60
20
  }) => void
61
- /** 接口调用失败的回调函数 */
62
21
  fail?: (params: {
63
- /** 错误信息 */
64
22
  errorMsg: string
65
- /** 错误码 */
66
23
  errorCode: string | number
67
- /** 错误扩展 */
68
24
  innerError: {
69
- /** 错误扩展码 */
70
25
  errorCode: string | number
71
- /** 错误扩展信息 */
72
26
  errorMsg: string
73
27
  }
74
28
  }) => void
29
+ complete?: () => void
75
30
  }): void
76
31
 
77
32
  /**
78
- * 获取QQ音乐QQ小程序授权参数
79
- * @description.en Get QQ Music QQ Mini Program authorization parameters.
80
- * @public
81
- * @since WearKit 1.0.0
82
- * @remarks 注意:WearKit(2.1.0)起下该方法已过时,请使用ThirdAuthKit下同名方法
83
- * @remarksEn Note: Deprecated since WearKit 2.1.0, use the same method in ThirdAuthKit.
84
- * @example 基础用法
85
- * ```tsx
86
- * `ty.wear.getQQMusicQQMiniProgramAuthParams({
87
- * success: (result) => {
88
- * console.log('getQQMusicQQMiniProgramAuthParams success', result);
89
- * },
90
- * fail: (error) => {
91
- * console.log('getQQMusicQQMiniProgramAuthParams fail', error.errorMsg);
92
- * },
93
- * });`
94
- * ```
95
- * @see https://developer.tuya.com/
96
- * @platform iOS Android
97
- */
33
+ *@description 获取QQ音乐QQ小程序授权参数
34
+ *注意:WearKit(2.1.0)起下该方法已过时,请使用ThirdAuthKit下同名方法*/
98
35
  export function getQQMusicQQMiniProgramAuthParams(params?: {
99
- /** 接口调用结束的回调函数(调用成功、失败都会执行) */
100
- complete?: () => void
101
- /** 接口调用成功的回调函数 */
102
36
  success?: (params: {
103
- /**
104
- * QQ音乐 AppKey
105
- * @since ThirdAuthKit 1.0.0
106
- */
37
+ /** qq音乐appkey */
107
38
  qqMusicAppKey: string
108
- /**
109
- * 加密的签名字符串
110
- * @since ThirdAuthKit 1.0.0
111
- */
39
+ /** 签名字符串 */
112
40
  encryptString: string
113
41
  }) => void
114
- /** 接口调用失败的回调函数 */
115
42
  fail?: (params: {
116
- /** 错误信息 */
117
43
  errorMsg: string
118
- /** 错误码 */
119
44
  errorCode: string | number
120
- /** 错误扩展 */
121
45
  innerError: {
122
- /** 错误扩展码 */
123
46
  errorCode: string | number
124
- /** 错误扩展信息 */
125
47
  errorMsg: string
126
48
  }
127
49
  }) => void
50
+ complete?: () => void
128
51
  }): void
129
52
 
130
53
  /**
131
- * 解析QQ音乐QQ小程序授权结果
132
- * @description.en Parse QQ Music QQ Mini Program authorization result.
133
- * @public
134
- * @since WearKit 1.0.0
135
- * @remarks 注意:WearKit(2.1.0)起下该方法已过时,请使用ThirdAuthKit下同名方法
136
- * @remarksEn Note: Deprecated since WearKit 2.1.0, use the same method in ThirdAuthKit.
137
- * @example 基础用法
138
- * ```tsx
139
- * `ty.wear.parseQQMusicAuthResult({
140
- * params: { encryptString: 'xxx' },
141
- * success: (result) => {
142
- * console.log('parseQQMusicAuthResult success', result);
143
- * },
144
- * fail: (error) => {
145
- * console.log('parseQQMusicAuthResult fail', error.errorMsg);
146
- * },
147
- * });`
148
- * ```
149
- * @see https://developer.tuya.com/
150
- * @platform iOS Android
151
- * @error {10001} 参数错误
152
- * @error {10004} JSON解析错误
153
- * @error {10005} 签名校验失败
154
- * @error {10007} 解密失败
155
- */
54
+ *@description 解析QQ音乐QQ小程序授权结果
55
+ *注意:WearKit(2.1.0)起下该方法已过时,请使用ThirdAuthKit下同名方法*/
156
56
  export function parseQQMusicAuthResult(params: {
157
- /**
158
- * 加密的授权结果字符串
159
- * @since ThirdAuthKit 1.0.0
160
- */
57
+ /** 授权结果 */
161
58
  encryptString: string
162
- /** 接口调用结束的回调函数(调用成功、失败都会执行) */
163
- complete?: () => void
164
- /** 接口调用成功的回调函数 */
165
59
  success?: (params: {
166
- /**
167
- * 过期时间(Unix 时间戳,单位:秒)
168
- * @since ThirdAuthKit 1.0.0
169
- */
60
+ /** 过期时间 */
170
61
  expireTime: number
171
- /**
172
- * QQ音乐账户 openId
173
- * @since ThirdAuthKit 1.0.0
174
- */
62
+ /** openId */
175
63
  openId: string
176
- /**
177
- * QQ音乐访问令牌
178
- * @since ThirdAuthKit 1.0.0
179
- */
64
+ /** openToken */
180
65
  openToken: string
181
66
  }) => void
182
- /** 接口调用失败的回调函数 */
183
67
  fail?: (params: {
184
- /** 错误信息 */
185
68
  errorMsg: string
186
- /** 错误码 */
187
69
  errorCode: string | number
188
- /** 错误扩展 */
189
70
  innerError: {
190
- /** 错误扩展码 */
191
71
  errorCode: string | number
192
- /** 错误扩展信息 */
193
72
  errorMsg: string
194
73
  }
195
74
  }) => void
75
+ complete?: () => void
196
76
  }): void
197
77
 
198
78
  /**
199
- * 监听微信授权代理事件
200
- * @description.en Get WeChat authorization information.
201
- * @public
202
- * @since WearKit 1.0.0
203
- * @remarks 注意:WearKit(2.1.0)起下该方法已过时,请使用ThirdAuthKit下同名方法
204
- * @remarksEn Note: Deprecated since WearKit 2.1.0, use the same method in ThirdAuthKit.
205
- * @example 基础用法
206
- * ```tsx
207
- * `ty.wear.onWechatAuthAgentEvent((response) => {
208
- * console.log('onWechatAuthAgentEvent', response);
209
- * });`
210
- * ```
211
- * @see https://developer.tuya.com/
212
- * @platform iOS Android
213
- */
79
+ *@description 获取微信授权信息
80
+ *注意:WearKit(2.1.0)起下该方法已过时,请使用ThirdAuthKit下同名方法*/
214
81
  export function onWechatAuthAgentEvent(
215
82
  listener: (params: QQMusicAuthResult) => void
216
83
  ): void
217
84
 
218
85
  /**
219
- * 监听微信授权代理事件
220
- * @description.en Get WeChat authorization information.
221
- * @public
222
- * @since WearKit 1.0.0
223
- * @remarks 注意:WearKit(2.1.0)起下该方法已过时,请使用ThirdAuthKit下同名方法
224
- * @remarksEn Note: Deprecated since WearKit 2.1.0, use the same method in ThirdAuthKit.
225
- * @example 基础用法
226
- * ```tsx
227
- * `ty.wear.onWechatAuthAgentEvent((response) => {
228
- * console.log('onWechatAuthAgentEvent', response);
229
- * });`
230
- * ```
231
- * @see https://developer.tuya.com/
232
- * @platform iOS Android
233
- */
86
+ *@description 移除监听:获取微信授权信息
87
+ *注意:WearKit(2.1.0)起下该方法已过时,请使用ThirdAuthKit下同名方法*/
234
88
  export function offWechatAuthAgentEvent(
235
89
  listener: (params: QQMusicAuthResult) => void
236
90
  ): void
237
91
 
238
- /**
239
- * QQ音乐授权请求参数
240
- * @since ThirdAuthKit 1.0.0
241
- */
242
- export interface QQMusicAuthParams {
243
- /**
244
- * 第三方服务类型,参见 ThirdPartyType 枚举
245
- * @since ThirdAuthKit 1.0.0
246
- */
247
- type: number
248
- }
249
-
250
- /**
251
- * QQ音乐授权结果
252
- * @since ThirdAuthKit 1.0.0
253
- */
254
- export interface QQMusicAuthResult {
255
- /**
256
- * 过期时间(Unix 时间戳,单位:秒)
257
- * @since ThirdAuthKit 1.0.0
258
- */
92
+ export type QQMusicAuthResult = {
93
+ /** 过期时间 */
259
94
  expireTime: number
260
- /**
261
- * QQ音乐账户 openId
262
- * @since ThirdAuthKit 1.0.0
263
- */
95
+ /** openId */
264
96
  openId: string
265
- /**
266
- * QQ音乐访问令牌
267
- * @since ThirdAuthKit 1.0.0
268
- */
97
+ /** openToken */
269
98
  openToken: string
270
99
  }
271
-
272
- /**
273
- * QQ音乐小程序授权参数
274
- * @since ThirdAuthKit 1.0.0
275
- */
276
- export interface QQMusicQQMiniProgramAuthParams {
277
- /**
278
- * QQ音乐 AppKey
279
- * @since ThirdAuthKit 1.0.0
280
- */
281
- qqMusicAppKey: string
282
- /**
283
- * 加密的签名字符串
284
- * @since ThirdAuthKit 1.0.0
285
- */
286
- encryptString: string
287
- }
288
-
289
- /**
290
- * QQ音乐授权结果解析参数
291
- * @since ThirdAuthKit 1.0.0
292
- */
293
- export interface QQMusicAuthResultParseParam {
294
- /**
295
- * 加密的授权结果字符串
296
- * @since ThirdAuthKit 1.0.0
297
- */
298
- encryptString: string
299
- }
300
-
301
- /**
302
- * 第三方服务类型枚举
303
- * @since ThirdAuthKit 1.0.0
304
- */
305
- export enum ThirdPartyType {
306
- /**
307
- * qq音乐
308
- * @since ThirdAuthKit 1.0.0
309
- */
310
- QQMusic = 0,
311
-
312
- /**
313
- * qq(暂不支持)
314
- * @since ThirdAuthKit 1.0.0
315
- */
316
- QQ = 1,
317
-
318
- /**
319
- * 微信
320
- * @since ThirdAuthKit 1.0.0
321
- */
322
- Wechat = 2,
323
- }
324
100
  }