@ray-js/api 1.7.69 → 1.7.71
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/@types/AIKit.d.ts +5509 -610
- package/@types/AIStreamKit.d.ts +2641 -0
- package/@types/AVideoKit.d.ts +1827 -0
- package/@types/BaseKit.d.ts +8682 -1893
- package/@types/BizKit.d.ts +6639 -1038
- package/@types/CategoryCommonBizKit.d.ts +1459 -0
- package/@types/CommunityKit.d.ts +154 -0
- package/@types/DeviceKit.d.ts +18475 -5662
- package/@types/GroupCITestKit.d.ts +651 -0
- package/@types/HealthKit.d.ts +2290 -357
- package/@types/HomeKit.d.ts +4068 -182
- package/@types/IPCKit.d.ts +4327 -1227
- package/@types/LightKit.d.ts +125 -0
- package/@types/MapKit.d.ts +1560 -204
- package/@types/MediaKit.d.ts +136 -16
- package/@types/MediaPlayerKit.d.ts +47 -0
- package/@types/MiniKit.d.ts +2976 -628
- package/@types/OutdoorKit.d.ts +1337 -24
- package/@types/P2PKit.d.ts +622 -103
- package/@types/PayKit.d.ts +115 -0
- package/@types/PlayNetKit.d.ts +3454 -1309
- package/@types/SweeperKit.d.ts +154 -0
- package/@types/ThirdAuthKit.d.ts +324 -0
- package/@types/ThirdPartyDeviceKit.d.ts +410 -0
- package/@types/WearKit.d.ts +10177 -375
- package/@types/gateway.d.ts +349 -61
- package/@types/health.d.ts +486 -304
- package/lib/AIKit-1.6.0.d.ts +265 -41
- package/lib/AIKit-1.6.0.js +374 -120
- package/lib/BaseKit-3.17.7.d.ts +704 -0
- package/lib/BaseKit-3.17.7.js +720 -1
- package/lib/BizKit-4.10.4.d.ts +336 -0
- package/lib/BizKit-4.10.4.js +342 -5
- package/lib/DeviceKit-4.13.1.d.ts +996 -0
- package/lib/DeviceKit-4.13.1.js +1247 -249
- package/lib/HealthKit-6.5.0.d.ts +210 -44
- package/lib/HealthKit-6.5.0.js +295 -128
- package/lib/HomeKit-3.1.4.d.ts +20 -6
- package/lib/HomeKit-3.1.4.js +29 -14
- package/lib/IPCKit-6.4.5.d.ts +375 -77
- package/lib/IPCKit-6.4.5.js +525 -228
- package/lib/MapKit-3.4.13.d.ts +70 -16
- package/lib/MapKit-3.4.13.js +98 -47
- package/lib/MediaKit-3.4.1.d.ts +5 -3
- package/lib/MediaKit-3.4.1.js +7 -6
- package/lib/MiniKit-3.14.1.d.ts +300 -0
- package/lib/MiniKit-3.14.1.js +302 -0
- package/lib/OutdoorKit-1.0.4.d.ts +55 -13
- package/lib/OutdoorKit-1.0.4.js +78 -35
- package/lib/P2PKit-2.0.3.d.ts +125 -27
- package/lib/P2PKit-2.0.3.js +175 -78
- package/lib/PlayNetKit-1.3.30.d.ts +290 -60
- package/lib/PlayNetKit-1.3.30.js +407 -176
- package/lib/WearKit-1.1.6.d.ts +125 -27
- package/lib/WearKit-1.1.6.js +176 -77
- package/lib/all-kits.d.ts +10 -10
- package/lib/all-kits.js +10 -10
- package/lib/cloud/core.d.ts +31 -1
- package/lib/cloud/core.js +31 -1
- package/lib/cloud/device.d.ts +155 -24
- package/lib/cloud/device.js +153 -22
- package/lib/cloud/gateway.d.ts +254 -0
- package/lib/cloud/gateway.js +269 -9
- package/lib/cloud/health.d.ts +1 -0
- package/lib/cloud/health.js +121 -0
- package/lib/cloud/interface.d.ts +222 -44
- package/lib/cloud/interface.js +15 -2
- package/lib/cloud/laser-clean/deleteCleaningRecord/index.d.ts +27 -0
- package/lib/cloud/laser-clean/deleteCleaningRecord/index.js +28 -0
- package/lib/cloud/laser-clean/deleteCleaningRecord/type.d.ts +7 -0
- package/lib/cloud/laser-clean/deleteCleaningRecord/type.js +1 -0
- package/lib/cloud/laser-clean/deleteGyroCleanRecord/index.d.ts +27 -0
- package/lib/cloud/laser-clean/deleteGyroCleanRecord/index.js +28 -0
- package/lib/cloud/laser-clean/deleteGyroCleanRecord/type.d.ts +7 -0
- package/lib/cloud/laser-clean/deleteGyroCleanRecord/type.js +1 -0
- package/lib/cloud/laser-clean/deleteMultipleMapFiles/index.d.ts +27 -0
- package/lib/cloud/laser-clean/deleteMultipleMapFiles/index.js +28 -0
- package/lib/cloud/laser-clean/deleteMultipleMapFiles/type.d.ts +7 -0
- package/lib/cloud/laser-clean/deleteMultipleMapFiles/type.js +1 -0
- package/lib/cloud/laser-clean/getCleaningRecords/index.d.ts +30 -0
- package/lib/cloud/laser-clean/getCleaningRecords/index.js +31 -0
- package/lib/cloud/laser-clean/getCleaningRecords/type.d.ts +39 -0
- package/lib/cloud/laser-clean/getCleaningRecords/type.js +1 -0
- package/lib/cloud/laser-clean/getGyroCleanRecordDetail/index.d.ts +29 -0
- package/lib/cloud/laser-clean/getGyroCleanRecordDetail/index.js +30 -0
- package/lib/cloud/laser-clean/getGyroCleanRecordDetail/type.d.ts +30 -0
- package/lib/cloud/laser-clean/getGyroCleanRecordDetail/type.js +1 -0
- package/lib/cloud/laser-clean/getGyroCleanRecords/index.d.ts +29 -0
- package/lib/cloud/laser-clean/getGyroCleanRecords/index.js +30 -0
- package/lib/cloud/laser-clean/getGyroCleanRecords/type.d.ts +35 -0
- package/lib/cloud/laser-clean/getGyroCleanRecords/type.js +1 -0
- package/lib/cloud/laser-clean/getGyroLatestCleanMap/index.d.ts +28 -0
- package/lib/cloud/laser-clean/getGyroLatestCleanMap/index.js +29 -0
- package/lib/cloud/laser-clean/getGyroLatestCleanMap/type.d.ts +28 -0
- package/lib/cloud/laser-clean/getGyroLatestCleanMap/type.js +1 -0
- package/lib/cloud/laser-clean/getMultipleMapFiles/index.d.ts +24 -0
- package/lib/cloud/laser-clean/getMultipleMapFiles/index.js +25 -0
- package/lib/cloud/laser-clean/getMultipleMapFiles/type.d.ts +29 -0
- package/lib/cloud/laser-clean/getMultipleMapFiles/type.js +1 -0
- package/lib/cloud/laser-clean/getSweeperStorageConfig/index.d.ts +24 -0
- package/lib/cloud/laser-clean/getSweeperStorageConfig/index.js +25 -0
- package/lib/cloud/laser-clean/getSweeperStorageConfig/type.d.ts +26 -0
- package/lib/cloud/laser-clean/getSweeperStorageConfig/type.js +1 -0
- package/lib/cloud/laser-clean/getVoiceList/index.d.ts +28 -0
- package/lib/cloud/laser-clean/getVoiceList/index.js +29 -0
- package/lib/cloud/laser-clean/getVoiceList/type.d.ts +48 -0
- package/lib/cloud/laser-clean/getVoiceList/type.js +1 -0
- package/lib/cloud/laser-clean/index.d.ts +1 -1
- package/lib/cloud/laser-clean/index.js +1 -1
- package/lib/cloud/laser-clean/map.d.ts +5 -7
- package/lib/cloud/laser-clean/map.js +5 -9
- package/lib/cloud/laser-clean/record.d.ts +5 -6
- package/lib/cloud/laser-clean/record.js +5 -7
- package/lib/cloud/laser-clean/renameHistoryMap/index.d.ts +28 -0
- package/lib/cloud/laser-clean/renameHistoryMap/index.js +29 -0
- package/lib/cloud/laser-clean/renameHistoryMap/type.d.ts +9 -0
- package/lib/cloud/laser-clean/renameHistoryMap/type.js +1 -0
- package/lib/cloud/laser-clean/voice.d.ts +1 -3
- package/lib/cloud/laser-clean/voice.js +1 -4
- package/lib/cloud/linkage.d.ts +271 -53
- package/lib/cloud/linkage.js +256 -51
- package/lib/cloud/remoteGroup.d.ts +37 -0
- package/lib/cloud/remoteGroup.js +37 -0
- package/lib/cloud/timer.d.ts +104 -26
- package/lib/cloud/timer.js +104 -26
- package/lib/getApp/index.thing.d.ts +47 -1
- package/lib/getApp/index.thing.js +40 -2
- package/lib/getBoundingClientRect/index.thing.d.ts +101 -1
- package/lib/getBoundingClientRect/index.thing.js +59 -0
- package/lib/getCurrentPages/index.thing.d.ts +40 -15
- package/lib/getCurrentPages/index.thing.js +36 -15
- package/lib/getCustomConfig/index.d.ts +5 -2
- package/lib/getCustomConfig/index.thing.d.ts +68 -2
- package/lib/getCustomConfig/index.thing.js +62 -0
- package/lib/getCustomConfig/index.wechat.d.ts +5 -2
- package/lib/getCustomConfig/type.d.ts +26 -15
- package/lib/getElementById/index.thing.d.ts +42 -1
- package/lib/getElementById/index.thing.js +40 -0
- package/lib/index.d.ts +3 -0
- package/lib/index.js +4 -2
- package/lib/nativeRouters/common.d.ts +8 -0
- package/lib/nativeRouters/device.d.ts +137 -5
- package/lib/nativeRouters/device.js +138 -6
- package/lib/nativeRouters/gw.d.ts +58 -8
- package/lib/nativeRouters/gw.js +57 -8
- package/lib/nativeRouters/outdoors.d.ts +16 -3
- package/lib/nativeRouters/outdoors.js +16 -3
- package/lib/nativeRouters/remoteGroup.d.ts +23 -0
- package/lib/nativeRouters/remoteGroup.js +23 -0
- package/lib/nativeRouters/root.d.ts +19 -0
- package/lib/nativeRouters/root.js +17 -0
- package/lib/openGroupCreate/index.d.ts +45 -0
- package/lib/openGroupCreate/index.js +32 -0
- package/package.json +5 -5
|
@@ -0,0 +1,410 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ThirdPartyDeviceKit
|
|
3
|
+
*
|
|
4
|
+
* @version 1.0.0-rc.4
|
|
5
|
+
*/
|
|
6
|
+
declare namespace ty.thirdpartydevice {
|
|
7
|
+
/**
|
|
8
|
+
* 根据设备id获取设备信息
|
|
9
|
+
* @public
|
|
10
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
11
|
+
* @platform iOS Android
|
|
12
|
+
*/
|
|
13
|
+
export function getDeviceInfo(params: {
|
|
14
|
+
/**
|
|
15
|
+
* 设备 id
|
|
16
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
17
|
+
*/
|
|
18
|
+
deviceId: string
|
|
19
|
+
/** 接口调用结束的回调函数(调用成功、失败都会执行) */
|
|
20
|
+
complete?: () => void
|
|
21
|
+
/** 接口调用成功的回调函数 */
|
|
22
|
+
success?: (params: {
|
|
23
|
+
/**
|
|
24
|
+
* 设备 id
|
|
25
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
26
|
+
*/
|
|
27
|
+
deviceId: string
|
|
28
|
+
/**
|
|
29
|
+
* 设备名称
|
|
30
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
31
|
+
*/
|
|
32
|
+
name: string
|
|
33
|
+
/**
|
|
34
|
+
* 设备所示家庭id
|
|
35
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
36
|
+
*/
|
|
37
|
+
gId: string
|
|
38
|
+
/**
|
|
39
|
+
* 设备所属房间id,没有房间为空
|
|
40
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
41
|
+
*/
|
|
42
|
+
rId: string
|
|
43
|
+
/**
|
|
44
|
+
* 设备类型: SWITCH("switch"), OUTLET("outlet"), LIGHT("light")
|
|
45
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
46
|
+
*/
|
|
47
|
+
deviceType: string
|
|
48
|
+
/**
|
|
49
|
+
* 设备连接状态
|
|
50
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
51
|
+
*/
|
|
52
|
+
isConnected: boolean
|
|
53
|
+
/**
|
|
54
|
+
* 设备 特征列表
|
|
55
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
56
|
+
*/
|
|
57
|
+
deviceTraits: DeviceTrait[]
|
|
58
|
+
}) => void
|
|
59
|
+
/** 接口调用失败的回调函数 */
|
|
60
|
+
fail?: (params: {
|
|
61
|
+
/** 错误信息 */
|
|
62
|
+
errorMsg: string
|
|
63
|
+
/** 错误码 */
|
|
64
|
+
errorCode: string | number
|
|
65
|
+
/** 错误扩展 */
|
|
66
|
+
innerError: {
|
|
67
|
+
/** 错误扩展码 */
|
|
68
|
+
errorCode: string | number
|
|
69
|
+
/** 错误扩展信息 */
|
|
70
|
+
errorMsg: string
|
|
71
|
+
}
|
|
72
|
+
}) => void
|
|
73
|
+
}): void
|
|
74
|
+
|
|
75
|
+
/**
|
|
76
|
+
* 控制设备
|
|
77
|
+
* @public
|
|
78
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
79
|
+
* @platform iOS Android
|
|
80
|
+
*/
|
|
81
|
+
export function sendCommand(params: {
|
|
82
|
+
/**
|
|
83
|
+
* 设备id
|
|
84
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
85
|
+
*/
|
|
86
|
+
deviceId: string
|
|
87
|
+
/**
|
|
88
|
+
* 设备功能状态点集合
|
|
89
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
90
|
+
*/
|
|
91
|
+
dpValList: DeviceTraitCommand[]
|
|
92
|
+
/** 接口调用结束的回调函数(调用成功、失败都会执行) */
|
|
93
|
+
complete?: () => void
|
|
94
|
+
/** 接口调用成功的回调函数 */
|
|
95
|
+
success?: (params: {
|
|
96
|
+
/**
|
|
97
|
+
* 设备 id
|
|
98
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
99
|
+
*/
|
|
100
|
+
deviceId: string
|
|
101
|
+
/**
|
|
102
|
+
* 设备名称
|
|
103
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
104
|
+
*/
|
|
105
|
+
name: string
|
|
106
|
+
/**
|
|
107
|
+
* 设备所示家庭id
|
|
108
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
109
|
+
*/
|
|
110
|
+
gId: string
|
|
111
|
+
/**
|
|
112
|
+
* 设备所属房间id,没有房间为空
|
|
113
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
114
|
+
*/
|
|
115
|
+
rId: string
|
|
116
|
+
/**
|
|
117
|
+
* 设备类型: SWITCH("switch"), OUTLET("outlet"), LIGHT("light")
|
|
118
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
119
|
+
*/
|
|
120
|
+
deviceType: string
|
|
121
|
+
/**
|
|
122
|
+
* 设备连接状态
|
|
123
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
124
|
+
*/
|
|
125
|
+
isConnected: boolean
|
|
126
|
+
/**
|
|
127
|
+
* 设备 特征列表
|
|
128
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
129
|
+
*/
|
|
130
|
+
deviceTraits: DeviceTrait[]
|
|
131
|
+
}) => void
|
|
132
|
+
/** 接口调用失败的回调函数 */
|
|
133
|
+
fail?: (params: {
|
|
134
|
+
/** 错误信息 */
|
|
135
|
+
errorMsg: string
|
|
136
|
+
/** 错误码 */
|
|
137
|
+
errorCode: string | number
|
|
138
|
+
/** 错误扩展 */
|
|
139
|
+
innerError: {
|
|
140
|
+
/** 错误扩展码 */
|
|
141
|
+
errorCode: string | number
|
|
142
|
+
/** 错误扩展信息 */
|
|
143
|
+
errorMsg: string
|
|
144
|
+
}
|
|
145
|
+
}) => void
|
|
146
|
+
}): void
|
|
147
|
+
|
|
148
|
+
/**
|
|
149
|
+
* 注册设备状态监听
|
|
150
|
+
* @public
|
|
151
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
152
|
+
* @platform iOS Android
|
|
153
|
+
*/
|
|
154
|
+
export function registerDeviceInfoChangeListener(params: {
|
|
155
|
+
/**
|
|
156
|
+
* 设备 id
|
|
157
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
158
|
+
*/
|
|
159
|
+
deviceId: string
|
|
160
|
+
/** 接口调用结束的回调函数(调用成功、失败都会执行) */
|
|
161
|
+
complete?: () => void
|
|
162
|
+
/** 接口调用成功的回调函数 */
|
|
163
|
+
success?: (params: null) => void
|
|
164
|
+
/** 接口调用失败的回调函数 */
|
|
165
|
+
fail?: (params: {
|
|
166
|
+
/** 错误信息 */
|
|
167
|
+
errorMsg: string
|
|
168
|
+
/** 错误码 */
|
|
169
|
+
errorCode: string | number
|
|
170
|
+
/** 错误扩展 */
|
|
171
|
+
innerError: {
|
|
172
|
+
/** 错误扩展码 */
|
|
173
|
+
errorCode: string | number
|
|
174
|
+
/** 错误扩展信息 */
|
|
175
|
+
errorMsg: string
|
|
176
|
+
}
|
|
177
|
+
}) => void
|
|
178
|
+
}): void
|
|
179
|
+
|
|
180
|
+
/**
|
|
181
|
+
* 解除注册设备状态监听
|
|
182
|
+
* @public
|
|
183
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
184
|
+
* @platform iOS Android
|
|
185
|
+
*/
|
|
186
|
+
export function unregisterDeviceInfoChangeListener(params: {
|
|
187
|
+
/**
|
|
188
|
+
* 设备 id
|
|
189
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
190
|
+
*/
|
|
191
|
+
deviceId: string
|
|
192
|
+
/** 接口调用结束的回调函数(调用成功、失败都会执行) */
|
|
193
|
+
complete?: () => void
|
|
194
|
+
/** 接口调用成功的回调函数 */
|
|
195
|
+
success?: (params: null) => void
|
|
196
|
+
/** 接口调用失败的回调函数 */
|
|
197
|
+
fail?: (params: {
|
|
198
|
+
/** 错误信息 */
|
|
199
|
+
errorMsg: string
|
|
200
|
+
/** 错误码 */
|
|
201
|
+
errorCode: string | number
|
|
202
|
+
/** 错误扩展 */
|
|
203
|
+
innerError: {
|
|
204
|
+
/** 错误扩展码 */
|
|
205
|
+
errorCode: string | number
|
|
206
|
+
/** 错误扩展信息 */
|
|
207
|
+
errorMsg: string
|
|
208
|
+
}
|
|
209
|
+
}) => void
|
|
210
|
+
}): void
|
|
211
|
+
|
|
212
|
+
/**
|
|
213
|
+
* 进入设备面板以后,监听设备在线状态事件
|
|
214
|
+
* @public
|
|
215
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
216
|
+
* @platform iOS Android
|
|
217
|
+
*/
|
|
218
|
+
export function onConnectStateChange(
|
|
219
|
+
listener: (params: onConnectStateChangeBody) => void
|
|
220
|
+
): void
|
|
221
|
+
|
|
222
|
+
/**
|
|
223
|
+
* 进入设备面板以后,监听设备在线状态事件
|
|
224
|
+
* @public
|
|
225
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
226
|
+
* @platform iOS Android
|
|
227
|
+
*/
|
|
228
|
+
export function offConnectStateChange(
|
|
229
|
+
listener: (params: onConnectStateChangeBody) => void
|
|
230
|
+
): void
|
|
231
|
+
|
|
232
|
+
/**
|
|
233
|
+
* 进入设备面板以后,设备在线状态事件
|
|
234
|
+
* @public
|
|
235
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
236
|
+
* @platform iOS Android
|
|
237
|
+
*/
|
|
238
|
+
export function onDeviceTraitInfoChange(
|
|
239
|
+
listener: (params: onDeviceTraitInfoChangeBody) => void
|
|
240
|
+
): void
|
|
241
|
+
|
|
242
|
+
/**
|
|
243
|
+
* 进入设备面板以后,设备在线状态事件
|
|
244
|
+
* @public
|
|
245
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
246
|
+
* @platform iOS Android
|
|
247
|
+
*/
|
|
248
|
+
export function offDeviceTraitInfoChange(
|
|
249
|
+
listener: (params: onDeviceTraitInfoChangeBody) => void
|
|
250
|
+
): void
|
|
251
|
+
|
|
252
|
+
/** @since ThirdPartyDeviceKit 1.0.0 */
|
|
253
|
+
export interface Device {
|
|
254
|
+
/**
|
|
255
|
+
* 设备 id
|
|
256
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
257
|
+
*/
|
|
258
|
+
deviceId: string
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
/**
|
|
262
|
+
* 设备特征模型
|
|
263
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
264
|
+
*/
|
|
265
|
+
export interface DeviceTrait {
|
|
266
|
+
/**
|
|
267
|
+
* 设备特征id:参照:文档参考: https://developers.home.google.com/matter/clusters?hl=zh-cn
|
|
268
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
269
|
+
*/
|
|
270
|
+
traitId: string
|
|
271
|
+
/**
|
|
272
|
+
* 设备特征功能code:目前暂时只支持插座,开关,灯。dpcode 我们定义如下:
|
|
273
|
+
* switch:开关
|
|
274
|
+
* bright:亮度
|
|
275
|
+
* color_hue:色调
|
|
276
|
+
* color_saturation:饱和度
|
|
277
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
278
|
+
*/
|
|
279
|
+
dpCode: string
|
|
280
|
+
/**
|
|
281
|
+
* 设备特征功能code对应的值
|
|
282
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
283
|
+
*/
|
|
284
|
+
dpValue: string
|
|
285
|
+
/**
|
|
286
|
+
* 设备特征功能code对应的值的类型
|
|
287
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
288
|
+
*/
|
|
289
|
+
valType: string
|
|
290
|
+
/**
|
|
291
|
+
* 设备特征功能code对应的值的最大值
|
|
292
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
293
|
+
*/
|
|
294
|
+
maxValue: number
|
|
295
|
+
/**
|
|
296
|
+
* 设备特征功能code对应的值的最小值
|
|
297
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
298
|
+
*/
|
|
299
|
+
minValue: number
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
/**
|
|
303
|
+
* 设备信息模型
|
|
304
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
305
|
+
*/
|
|
306
|
+
export interface DeviceInfoResponse {
|
|
307
|
+
/**
|
|
308
|
+
* 设备 id
|
|
309
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
310
|
+
*/
|
|
311
|
+
deviceId: string
|
|
312
|
+
/**
|
|
313
|
+
* 设备名称
|
|
314
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
315
|
+
*/
|
|
316
|
+
name: string
|
|
317
|
+
/**
|
|
318
|
+
* 设备所示家庭id
|
|
319
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
320
|
+
*/
|
|
321
|
+
gId: string
|
|
322
|
+
/**
|
|
323
|
+
* 设备所属房间id,没有房间为空
|
|
324
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
325
|
+
*/
|
|
326
|
+
rId: string
|
|
327
|
+
/**
|
|
328
|
+
* 设备类型: SWITCH("switch"), OUTLET("outlet"), LIGHT("light")
|
|
329
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
330
|
+
*/
|
|
331
|
+
deviceType: string
|
|
332
|
+
/**
|
|
333
|
+
* 设备连接状态
|
|
334
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
335
|
+
*/
|
|
336
|
+
isConnected: boolean
|
|
337
|
+
/**
|
|
338
|
+
* 设备 特征列表
|
|
339
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
340
|
+
*/
|
|
341
|
+
deviceTraits: DeviceTrait[]
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
/**
|
|
345
|
+
* 设备特征控制功能点模型
|
|
346
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
347
|
+
*/
|
|
348
|
+
export interface DeviceTraitCommand {
|
|
349
|
+
/**
|
|
350
|
+
* 设备特征功能code
|
|
351
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
352
|
+
*/
|
|
353
|
+
dpCode: string
|
|
354
|
+
/**
|
|
355
|
+
* 设备特征功能code对应变化的值
|
|
356
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
357
|
+
*/
|
|
358
|
+
dpVal: string
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
/**
|
|
362
|
+
* 设备特征控制模型
|
|
363
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
364
|
+
*/
|
|
365
|
+
export interface DeviceCommandParam {
|
|
366
|
+
/**
|
|
367
|
+
* 设备id
|
|
368
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
369
|
+
*/
|
|
370
|
+
deviceId: string
|
|
371
|
+
/**
|
|
372
|
+
* 设备功能状态点集合
|
|
373
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
374
|
+
*/
|
|
375
|
+
dpValList: DeviceTraitCommand[]
|
|
376
|
+
}
|
|
377
|
+
|
|
378
|
+
/** @since ThirdPartyDeviceKit 1.0.0 */
|
|
379
|
+
export interface onConnectStateChangeBody {
|
|
380
|
+
/**
|
|
381
|
+
* 设备id
|
|
382
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
383
|
+
*/
|
|
384
|
+
deviceId: string
|
|
385
|
+
/**
|
|
386
|
+
* 设备连接状态
|
|
387
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
388
|
+
*/
|
|
389
|
+
isConnected: boolean
|
|
390
|
+
}
|
|
391
|
+
|
|
392
|
+
/** @since ThirdPartyDeviceKit 1.0.0 */
|
|
393
|
+
export interface onDeviceTraitInfoChangeBody {
|
|
394
|
+
/**
|
|
395
|
+
* 设备id
|
|
396
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
397
|
+
*/
|
|
398
|
+
deviceId: string
|
|
399
|
+
/**
|
|
400
|
+
* 设备特征功能code
|
|
401
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
402
|
+
*/
|
|
403
|
+
dpCode: string
|
|
404
|
+
/**
|
|
405
|
+
* 设备特征功能code对应变化的值
|
|
406
|
+
* @since ThirdPartyDeviceKit 1.0.0
|
|
407
|
+
*/
|
|
408
|
+
dpVal: string
|
|
409
|
+
}
|
|
410
|
+
}
|