@switchbot/homebridge-switchbot 5.0.0-beta.70 → 5.0.0-beta.72

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 (534) hide show
  1. package/.github/ISSUE_TEMPLATE/e2e-verification.md +36 -0
  2. package/.github/workflows/ci.yml +61 -0
  3. package/.github/workflows/manual-e2e.yml +103 -0
  4. package/CHANGELOG.md +20 -0
  5. package/E2E-VERIFICATION.md +121 -0
  6. package/MIGRATION.md +44 -0
  7. package/README.md +11 -0
  8. package/config.schema.json +99 -1940
  9. package/dist/deviceFactory.d.ts +13 -0
  10. package/dist/deviceFactory.d.ts.map +1 -0
  11. package/dist/deviceFactory.js +81 -0
  12. package/dist/deviceFactory.js.map +1 -0
  13. package/dist/devices/deviceBase.d.ts +50 -0
  14. package/dist/devices/deviceBase.d.ts.map +1 -0
  15. package/dist/devices/deviceBase.js +119 -0
  16. package/dist/devices/deviceBase.js.map +1 -0
  17. package/dist/devices/genericDevice.d.ts +283 -0
  18. package/dist/devices/genericDevice.d.ts.map +1 -0
  19. package/dist/devices/genericDevice.js +1035 -0
  20. package/dist/devices/genericDevice.js.map +1 -0
  21. package/dist/homebridge-ui/public/index.html +72 -440
  22. package/dist/homebridge-ui/server.d.ts +3 -1
  23. package/dist/homebridge-ui/server.d.ts.map +1 -1
  24. package/dist/homebridge-ui/server.js +47 -10
  25. package/dist/homebridge-ui/server.js.map +1 -1
  26. package/dist/index.d.ts.map +1 -1
  27. package/dist/index.js +1 -3
  28. package/dist/index.js.map +1 -1
  29. package/dist/platform.d.ts +27 -0
  30. package/dist/platform.d.ts.map +1 -0
  31. package/dist/platform.js +404 -0
  32. package/dist/platform.js.map +1 -0
  33. package/dist/settings.d.ts +10 -317
  34. package/dist/settings.d.ts.map +1 -1
  35. package/dist/settings.js +5 -30
  36. package/dist/settings.js.map +1 -1
  37. package/dist/switchbotClient.d.ts +32 -0
  38. package/dist/switchbotClient.d.ts.map +1 -0
  39. package/dist/switchbotClient.js +259 -0
  40. package/dist/switchbotClient.js.map +1 -0
  41. package/dist/utils.d.ts +36 -248
  42. package/dist/utils.d.ts.map +1 -1
  43. package/dist/utils.js +38 -1367
  44. package/dist/utils.js.map +1 -1
  45. package/docs/assets/icons.js +1 -1
  46. package/docs/assets/icons.svg +1 -1
  47. package/docs/assets/style.css +3 -3
  48. package/docs/index.html +50 -15
  49. package/docs/variables/default.html +1 -1
  50. package/package.json +19 -18
  51. package/scripts/e2e/README.md +25 -0
  52. package/scripts/e2e/curtain-e2e.sh +70 -0
  53. package/scripts/e2e/fan-e2e.sh +75 -0
  54. package/scripts/e2e/light-advanced-e2e.sh +97 -0
  55. package/scripts/e2e/light-e2e.sh +75 -0
  56. package/scripts/e2e/list-accessories.sh +19 -0
  57. package/scripts/e2e/lock-e2e.sh +65 -0
  58. package/scripts/generate-matter-maps.js +60 -0
  59. package/scripts/run-e2e-local.sh +14 -0
  60. package/src/deviceFactory.ts +122 -0
  61. package/src/devices/deviceBase.ts +141 -0
  62. package/src/devices/genericDevice.ts +965 -0
  63. package/src/homebridge-ui/public/index.html +72 -440
  64. package/src/homebridge-ui/server.ts +52 -10
  65. package/src/index.ts +1 -3
  66. package/src/platform.ts +395 -0
  67. package/src/settings.ts +12 -352
  68. package/src/switchbotClient.ts +266 -0
  69. package/src/utils.ts +47 -1456
  70. package/test/accessory-restore.spec.ts +73 -0
  71. package/test/device-mapping.spec.ts +37 -0
  72. package/test/deviceFactory.spec.ts +18 -0
  73. package/test/e2e/run-e2e.spec.ts +50 -0
  74. package/test/fan-swing.spec.ts +29 -0
  75. package/test/helpers/matter-harness.ts +53 -0
  76. package/test/lock-users.spec.ts +44 -0
  77. package/test/matter-childbridge.spec.ts +55 -0
  78. package/test/matter-descriptors.spec.ts +97 -0
  79. package/test/matter-device-state.spec.ts +101 -0
  80. package/test/matter-integration.spec.ts +70 -0
  81. package/test/platform.integration.spec.ts +55 -0
  82. package/test/switchbot-client-debounce.spec.ts +131 -0
  83. package/test/switchbot-client-openapi.spec.ts +56 -0
  84. package/test/switchbotClient.spec.ts +10 -0
  85. package/test/utils.spec.ts +20 -0
  86. package/vitest.config.ts +7 -0
  87. package/coverage/base.css +0 -224
  88. package/coverage/block-navigation.js +0 -87
  89. package/coverage/clover.xml +0 -15847
  90. package/coverage/coverage-final.json +0 -42
  91. package/coverage/docs/assets/dmt/dmt-component-data.js.html +0 -85
  92. package/coverage/docs/assets/dmt/dmt-components.js.html +0 -286
  93. package/coverage/docs/assets/dmt/index.html +0 -131
  94. package/coverage/docs/assets/hierarchy.js.html +0 -85
  95. package/coverage/docs/assets/icons.js.html +0 -136
  96. package/coverage/docs/assets/index.html +0 -146
  97. package/coverage/docs/assets/main.js.html +0 -265
  98. package/coverage/favicon.png +0 -0
  99. package/coverage/index.html +0 -191
  100. package/coverage/prettify.css +0 -1
  101. package/coverage/prettify.js +0 -2
  102. package/coverage/sort-arrow-sprite.png +0 -0
  103. package/coverage/sorter.js +0 -196
  104. package/coverage/src/device/blindtilt.ts.html +0 -3238
  105. package/coverage/src/device/bot.ts.html +0 -2803
  106. package/coverage/src/device/ceilinglight.ts.html +0 -2338
  107. package/coverage/src/device/colorbulb.ts.html +0 -2824
  108. package/coverage/src/device/contact.ts.html +0 -1465
  109. package/coverage/src/device/curtain.ts.html +0 -2869
  110. package/coverage/src/device/device.ts.html +0 -2500
  111. package/coverage/src/device/fan.ts.html +0 -2242
  112. package/coverage/src/device/hub.ts.html +0 -1408
  113. package/coverage/src/device/humidifier.ts.html +0 -2116
  114. package/coverage/src/device/index.html +0 -416
  115. package/coverage/src/device/iosensor.ts.html +0 -1375
  116. package/coverage/src/device/lightstrip.ts.html +0 -2617
  117. package/coverage/src/device/lock.ts.html +0 -1963
  118. package/coverage/src/device/meter.ts.html +0 -1372
  119. package/coverage/src/device/meterplus.ts.html +0 -1384
  120. package/coverage/src/device/meterpro.ts.html +0 -1618
  121. package/coverage/src/device/motion.ts.html +0 -1264
  122. package/coverage/src/device/plug.ts.html +0 -1372
  123. package/coverage/src/device/relayswitch.ts.html +0 -2284
  124. package/coverage/src/device/robotvacuumcleaner.ts.html +0 -1810
  125. package/coverage/src/device/waterdetector.ts.html +0 -1294
  126. package/coverage/src/homebridge-ui/index.html +0 -116
  127. package/coverage/src/homebridge-ui/server.ts.html +0 -229
  128. package/coverage/src/index.html +0 -161
  129. package/coverage/src/index.ts.html +0 -124
  130. package/coverage/src/irdevice/airconditioner.ts.html +0 -1687
  131. package/coverage/src/irdevice/airpurifier.ts.html +0 -844
  132. package/coverage/src/irdevice/camera.ts.html +0 -475
  133. package/coverage/src/irdevice/fan.ts.html +0 -766
  134. package/coverage/src/irdevice/index.html +0 -251
  135. package/coverage/src/irdevice/irdevice.ts.html +0 -1117
  136. package/coverage/src/irdevice/light.ts.html +0 -826
  137. package/coverage/src/irdevice/other.ts.html +0 -2458
  138. package/coverage/src/irdevice/tv.ts.html +0 -1222
  139. package/coverage/src/irdevice/vacuumcleaner.ts.html +0 -466
  140. package/coverage/src/irdevice/waterheater.ts.html +0 -469
  141. package/coverage/src/platform.ts.html +0 -8776
  142. package/coverage/src/settings.ts.html +0 -934
  143. package/coverage/src/utils.ts.html +0 -2092
  144. package/dist/devices-hap/airpurifier.d.ts +0 -54
  145. package/dist/devices-hap/airpurifier.d.ts.map +0 -1
  146. package/dist/devices-hap/airpurifier.js +0 -533
  147. package/dist/devices-hap/airpurifier.js.map +0 -1
  148. package/dist/devices-hap/blindtilt.d.ts +0 -90
  149. package/dist/devices-hap/blindtilt.d.ts.map +0 -1
  150. package/dist/devices-hap/blindtilt.js +0 -974
  151. package/dist/devices-hap/blindtilt.js.map +0 -1
  152. package/dist/devices-hap/bot.d.ts +0 -102
  153. package/dist/devices-hap/bot.d.ts.map +0 -1
  154. package/dist/devices-hap/bot.js +0 -822
  155. package/dist/devices-hap/bot.js.map +0 -1
  156. package/dist/devices-hap/ceilinglight.d.ts +0 -85
  157. package/dist/devices-hap/ceilinglight.d.ts.map +0 -1
  158. package/dist/devices-hap/ceilinglight.js +0 -707
  159. package/dist/devices-hap/ceilinglight.js.map +0 -1
  160. package/dist/devices-hap/colorbulb.d.ts +0 -88
  161. package/dist/devices-hap/colorbulb.d.ts.map +0 -1
  162. package/dist/devices-hap/colorbulb.js +0 -921
  163. package/dist/devices-hap/colorbulb.js.map +0 -1
  164. package/dist/devices-hap/contact.d.ts +0 -44
  165. package/dist/devices-hap/contact.d.ts.map +0 -1
  166. package/dist/devices-hap/contact.js +0 -409
  167. package/dist/devices-hap/contact.js.map +0 -1
  168. package/dist/devices-hap/curtain.d.ts +0 -73
  169. package/dist/devices-hap/curtain.d.ts.map +0 -1
  170. package/dist/devices-hap/curtain.js +0 -869
  171. package/dist/devices-hap/curtain.js.map +0 -1
  172. package/dist/devices-hap/device.d.ts +0 -108
  173. package/dist/devices-hap/device.d.ts.map +0 -1
  174. package/dist/devices-hap/device.js +0 -821
  175. package/dist/devices-hap/device.js.map +0 -1
  176. package/dist/devices-hap/fan.d.ts +0 -69
  177. package/dist/devices-hap/fan.d.ts.map +0 -1
  178. package/dist/devices-hap/fan.js +0 -655
  179. package/dist/devices-hap/fan.js.map +0 -1
  180. package/dist/devices-hap/hub.d.ts +0 -37
  181. package/dist/devices-hap/hub.d.ts.map +0 -1
  182. package/dist/devices-hap/hub.js +0 -393
  183. package/dist/devices-hap/hub.js.map +0 -1
  184. package/dist/devices-hap/humidifier.d.ts +0 -73
  185. package/dist/devices-hap/humidifier.d.ts.map +0 -1
  186. package/dist/devices-hap/humidifier.js +0 -716
  187. package/dist/devices-hap/humidifier.js.map +0 -1
  188. package/dist/devices-hap/iosensor.d.ts +0 -42
  189. package/dist/devices-hap/iosensor.d.ts.map +0 -1
  190. package/dist/devices-hap/iosensor.js +0 -397
  191. package/dist/devices-hap/iosensor.js.map +0 -1
  192. package/dist/devices-hap/lightstrip.d.ts +0 -79
  193. package/dist/devices-hap/lightstrip.d.ts.map +0 -1
  194. package/dist/devices-hap/lightstrip.js +0 -827
  195. package/dist/devices-hap/lightstrip.js.map +0 -1
  196. package/dist/devices-hap/lock.d.ts +0 -53
  197. package/dist/devices-hap/lock.d.ts.map +0 -1
  198. package/dist/devices-hap/lock.js +0 -569
  199. package/dist/devices-hap/lock.js.map +0 -1
  200. package/dist/devices-hap/meter.d.ts +0 -37
  201. package/dist/devices-hap/meter.d.ts.map +0 -1
  202. package/dist/devices-hap/meter.js +0 -380
  203. package/dist/devices-hap/meter.js.map +0 -1
  204. package/dist/devices-hap/meterplus.d.ts +0 -42
  205. package/dist/devices-hap/meterplus.d.ts.map +0 -1
  206. package/dist/devices-hap/meterplus.js +0 -385
  207. package/dist/devices-hap/meterplus.js.map +0 -1
  208. package/dist/devices-hap/meterpro.d.ts +0 -43
  209. package/dist/devices-hap/meterpro.d.ts.map +0 -1
  210. package/dist/devices-hap/meterpro.js +0 -469
  211. package/dist/devices-hap/meterpro.js.map +0 -1
  212. package/dist/devices-hap/motion.d.ts +0 -42
  213. package/dist/devices-hap/motion.d.ts.map +0 -1
  214. package/dist/devices-hap/motion.js +0 -345
  215. package/dist/devices-hap/motion.js.map +0 -1
  216. package/dist/devices-hap/plug.d.ts +0 -49
  217. package/dist/devices-hap/plug.d.ts.map +0 -1
  218. package/dist/devices-hap/plug.js +0 -400
  219. package/dist/devices-hap/plug.js.map +0 -1
  220. package/dist/devices-hap/relayswitch.d.ts +0 -96
  221. package/dist/devices-hap/relayswitch.d.ts.map +0 -1
  222. package/dist/devices-hap/relayswitch.js +0 -642
  223. package/dist/devices-hap/relayswitch.js.map +0 -1
  224. package/dist/devices-hap/robotvacuumcleaner.d.ts +0 -54
  225. package/dist/devices-hap/robotvacuumcleaner.d.ts.map +0 -1
  226. package/dist/devices-hap/robotvacuumcleaner.js +0 -530
  227. package/dist/devices-hap/robotvacuumcleaner.js.map +0 -1
  228. package/dist/devices-hap/waterdetector.d.ts +0 -41
  229. package/dist/devices-hap/waterdetector.d.ts.map +0 -1
  230. package/dist/devices-hap/waterdetector.js +0 -356
  231. package/dist/devices-hap/waterdetector.js.map +0 -1
  232. package/dist/devices-matter/BaseMatterAccessory.d.ts +0 -90
  233. package/dist/devices-matter/BaseMatterAccessory.d.ts.map +0 -1
  234. package/dist/devices-matter/BaseMatterAccessory.js +0 -264
  235. package/dist/devices-matter/BaseMatterAccessory.js.map +0 -1
  236. package/dist/devices-matter/ColorLightAccessory.d.ts +0 -20
  237. package/dist/devices-matter/ColorLightAccessory.d.ts.map +0 -1
  238. package/dist/devices-matter/ColorLightAccessory.js +0 -95
  239. package/dist/devices-matter/ColorLightAccessory.js.map +0 -1
  240. package/dist/devices-matter/ColorTemperatureLightAccessory.d.ts +0 -18
  241. package/dist/devices-matter/ColorTemperatureLightAccessory.d.ts.map +0 -1
  242. package/dist/devices-matter/ColorTemperatureLightAccessory.js +0 -76
  243. package/dist/devices-matter/ColorTemperatureLightAccessory.js.map +0 -1
  244. package/dist/devices-matter/ContactSensorAccessory.d.ts +0 -12
  245. package/dist/devices-matter/ContactSensorAccessory.d.ts.map +0 -1
  246. package/dist/devices-matter/ContactSensorAccessory.js +0 -34
  247. package/dist/devices-matter/ContactSensorAccessory.js.map +0 -1
  248. package/dist/devices-matter/DimmableLightAccessory.d.ts +0 -58
  249. package/dist/devices-matter/DimmableLightAccessory.d.ts.map +0 -1
  250. package/dist/devices-matter/DimmableLightAccessory.js +0 -167
  251. package/dist/devices-matter/DimmableLightAccessory.js.map +0 -1
  252. package/dist/devices-matter/DoorLockAccessory.d.ts +0 -14
  253. package/dist/devices-matter/DoorLockAccessory.d.ts.map +0 -1
  254. package/dist/devices-matter/DoorLockAccessory.js +0 -50
  255. package/dist/devices-matter/DoorLockAccessory.js.map +0 -1
  256. package/dist/devices-matter/ExtendedColorLightAccessory.d.ts +0 -21
  257. package/dist/devices-matter/ExtendedColorLightAccessory.d.ts.map +0 -1
  258. package/dist/devices-matter/ExtendedColorLightAccessory.js +0 -106
  259. package/dist/devices-matter/ExtendedColorLightAccessory.js.map +0 -1
  260. package/dist/devices-matter/FanAccessory.d.ts +0 -16
  261. package/dist/devices-matter/FanAccessory.d.ts.map +0 -1
  262. package/dist/devices-matter/FanAccessory.js +0 -81
  263. package/dist/devices-matter/FanAccessory.js.map +0 -1
  264. package/dist/devices-matter/HumiditySensorAccessory.d.ts +0 -12
  265. package/dist/devices-matter/HumiditySensorAccessory.d.ts.map +0 -1
  266. package/dist/devices-matter/HumiditySensorAccessory.js +0 -34
  267. package/dist/devices-matter/HumiditySensorAccessory.js.map +0 -1
  268. package/dist/devices-matter/LeakSensorAccessory.d.ts +0 -12
  269. package/dist/devices-matter/LeakSensorAccessory.d.ts.map +0 -1
  270. package/dist/devices-matter/LeakSensorAccessory.js +0 -33
  271. package/dist/devices-matter/LeakSensorAccessory.js.map +0 -1
  272. package/dist/devices-matter/LightSensorAccessory.d.ts +0 -12
  273. package/dist/devices-matter/LightSensorAccessory.d.ts.map +0 -1
  274. package/dist/devices-matter/LightSensorAccessory.js +0 -34
  275. package/dist/devices-matter/LightSensorAccessory.js.map +0 -1
  276. package/dist/devices-matter/OccupancySensorAccessory.d.ts +0 -12
  277. package/dist/devices-matter/OccupancySensorAccessory.d.ts.map +0 -1
  278. package/dist/devices-matter/OccupancySensorAccessory.js +0 -39
  279. package/dist/devices-matter/OccupancySensorAccessory.js.map +0 -1
  280. package/dist/devices-matter/OnOffLightAccessory.d.ts +0 -38
  281. package/dist/devices-matter/OnOffLightAccessory.d.ts.map +0 -1
  282. package/dist/devices-matter/OnOffLightAccessory.js +0 -110
  283. package/dist/devices-matter/OnOffLightAccessory.js.map +0 -1
  284. package/dist/devices-matter/OnOffOutletAccessory.d.ts +0 -14
  285. package/dist/devices-matter/OnOffOutletAccessory.d.ts.map +0 -1
  286. package/dist/devices-matter/OnOffOutletAccessory.js +0 -43
  287. package/dist/devices-matter/OnOffOutletAccessory.js.map +0 -1
  288. package/dist/devices-matter/OnOffSwitchAccessory.d.ts +0 -14
  289. package/dist/devices-matter/OnOffSwitchAccessory.d.ts.map +0 -1
  290. package/dist/devices-matter/OnOffSwitchAccessory.js +0 -42
  291. package/dist/devices-matter/OnOffSwitchAccessory.js.map +0 -1
  292. package/dist/devices-matter/RoboticVacuumAccessory.d.ts +0 -61
  293. package/dist/devices-matter/RoboticVacuumAccessory.d.ts.map +0 -1
  294. package/dist/devices-matter/RoboticVacuumAccessory.js +0 -544
  295. package/dist/devices-matter/RoboticVacuumAccessory.js.map +0 -1
  296. package/dist/devices-matter/SmokeCOAlarmAccessory.d.ts +0 -11
  297. package/dist/devices-matter/SmokeCOAlarmAccessory.d.ts.map +0 -1
  298. package/dist/devices-matter/SmokeCOAlarmAccessory.js +0 -49
  299. package/dist/devices-matter/SmokeCOAlarmAccessory.js.map +0 -1
  300. package/dist/devices-matter/TemperatureSensorAccessory.d.ts +0 -12
  301. package/dist/devices-matter/TemperatureSensorAccessory.d.ts.map +0 -1
  302. package/dist/devices-matter/TemperatureSensorAccessory.js +0 -36
  303. package/dist/devices-matter/TemperatureSensorAccessory.js.map +0 -1
  304. package/dist/devices-matter/ThermostatAccessory.d.ts +0 -19
  305. package/dist/devices-matter/ThermostatAccessory.d.ts.map +0 -1
  306. package/dist/devices-matter/ThermostatAccessory.js +0 -95
  307. package/dist/devices-matter/ThermostatAccessory.js.map +0 -1
  308. package/dist/devices-matter/VenetianBlindAccessory.d.ts +0 -19
  309. package/dist/devices-matter/VenetianBlindAccessory.d.ts.map +0 -1
  310. package/dist/devices-matter/VenetianBlindAccessory.js +0 -99
  311. package/dist/devices-matter/VenetianBlindAccessory.js.map +0 -1
  312. package/dist/devices-matter/WindowBlindAccessory.d.ts +0 -17
  313. package/dist/devices-matter/WindowBlindAccessory.d.ts.map +0 -1
  314. package/dist/devices-matter/WindowBlindAccessory.js +0 -131
  315. package/dist/devices-matter/WindowBlindAccessory.js.map +0 -1
  316. package/dist/devices-matter/custom/PowerStripAccessory.d.ts +0 -97
  317. package/dist/devices-matter/custom/PowerStripAccessory.d.ts.map +0 -1
  318. package/dist/devices-matter/custom/PowerStripAccessory.js +0 -265
  319. package/dist/devices-matter/custom/PowerStripAccessory.js.map +0 -1
  320. package/dist/devices-matter/custom/index.d.ts +0 -8
  321. package/dist/devices-matter/custom/index.d.ts.map +0 -1
  322. package/dist/devices-matter/custom/index.js +0 -8
  323. package/dist/devices-matter/custom/index.js.map +0 -1
  324. package/dist/devices-matter/index.d.ts +0 -29
  325. package/dist/devices-matter/index.d.ts.map +0 -1
  326. package/dist/devices-matter/index.js +0 -28
  327. package/dist/devices-matter/index.js.map +0 -1
  328. package/dist/irdevice/airconditioner.d.ts +0 -61
  329. package/dist/irdevice/airconditioner.d.ts.map +0 -1
  330. package/dist/irdevice/airconditioner.js +0 -472
  331. package/dist/irdevice/airconditioner.js.map +0 -1
  332. package/dist/irdevice/airpurifier.d.ts +0 -50
  333. package/dist/irdevice/airpurifier.d.ts.map +0 -1
  334. package/dist/irdevice/airpurifier.js +0 -213
  335. package/dist/irdevice/airpurifier.js.map +0 -1
  336. package/dist/irdevice/camera.d.ts +0 -32
  337. package/dist/irdevice/camera.d.ts.map +0 -1
  338. package/dist/irdevice/camera.js +0 -107
  339. package/dist/irdevice/camera.js.map +0 -1
  340. package/dist/irdevice/fan.d.ts +0 -36
  341. package/dist/irdevice/fan.d.ts.map +0 -1
  342. package/dist/irdevice/fan.js +0 -200
  343. package/dist/irdevice/fan.js.map +0 -1
  344. package/dist/irdevice/irdevice.d.ts +0 -69
  345. package/dist/irdevice/irdevice.d.ts.map +0 -1
  346. package/dist/irdevice/irdevice.js +0 -339
  347. package/dist/irdevice/irdevice.js.map +0 -1
  348. package/dist/irdevice/light.d.ts +0 -36
  349. package/dist/irdevice/light.d.ts.map +0 -1
  350. package/dist/irdevice/light.js +0 -206
  351. package/dist/irdevice/light.js.map +0 -1
  352. package/dist/irdevice/other.d.ts +0 -57
  353. package/dist/irdevice/other.d.ts.map +0 -1
  354. package/dist/irdevice/other.js +0 -778
  355. package/dist/irdevice/other.js.map +0 -1
  356. package/dist/irdevice/tv.d.ts +0 -45
  357. package/dist/irdevice/tv.d.ts.map +0 -1
  358. package/dist/irdevice/tv.js +0 -327
  359. package/dist/irdevice/tv.js.map +0 -1
  360. package/dist/irdevice/vacuumcleaner.d.ts +0 -28
  361. package/dist/irdevice/vacuumcleaner.d.ts.map +0 -1
  362. package/dist/irdevice/vacuumcleaner.js +0 -104
  363. package/dist/irdevice/vacuumcleaner.js.map +0 -1
  364. package/dist/irdevice/waterheater.d.ts +0 -30
  365. package/dist/irdevice/waterheater.d.ts.map +0 -1
  366. package/dist/irdevice/waterheater.js +0 -105
  367. package/dist/irdevice/waterheater.js.map +0 -1
  368. package/dist/platform-hap.d.ts +0 -160
  369. package/dist/platform-hap.d.ts.map +0 -1
  370. package/dist/platform-hap.js +0 -3041
  371. package/dist/platform-hap.js.map +0 -1
  372. package/dist/platform-matter.d.ts +0 -188
  373. package/dist/platform-matter.d.ts.map +0 -1
  374. package/dist/platform-matter.js +0 -2545
  375. package/dist/platform-matter.js.map +0 -1
  376. package/dist/test/apiRequestTracker.test.d.ts +0 -2
  377. package/dist/test/apiRequestTracker.test.d.ts.map +0 -1
  378. package/dist/test/apiRequestTracker.test.js +0 -392
  379. package/dist/test/apiRequestTracker.test.js.map +0 -1
  380. package/dist/test/hap/device-webhook-context.test.d.ts +0 -2
  381. package/dist/test/hap/device-webhook-context.test.d.ts.map +0 -1
  382. package/dist/test/hap/device-webhook-context.test.js +0 -128
  383. package/dist/test/hap/device-webhook-context.test.js.map +0 -1
  384. package/dist/test/hap/platform-hap.logging.test.d.ts +0 -2
  385. package/dist/test/hap/platform-hap.logging.test.d.ts.map +0 -1
  386. package/dist/test/hap/platform-hap.logging.test.js +0 -33
  387. package/dist/test/hap/platform-hap.logging.test.js.map +0 -1
  388. package/dist/test/hap/platform-hap.test.d.ts +0 -2
  389. package/dist/test/hap/platform-hap.test.d.ts.map +0 -1
  390. package/dist/test/hap/platform-hap.test.js +0 -62
  391. package/dist/test/hap/platform-hap.test.js.map +0 -1
  392. package/dist/test/helpers/platform-fixtures.d.ts +0 -9
  393. package/dist/test/helpers/platform-fixtures.d.ts.map +0 -1
  394. package/dist/test/helpers/platform-fixtures.js +0 -30
  395. package/dist/test/helpers/platform-fixtures.js.map +0 -1
  396. package/dist/test/homebridge-ui/server.test.d.ts +0 -2
  397. package/dist/test/homebridge-ui/server.test.d.ts.map +0 -1
  398. package/dist/test/homebridge-ui/server.test.js +0 -445
  399. package/dist/test/homebridge-ui/server.test.js.map +0 -1
  400. package/dist/test/index.test.d.ts +0 -2
  401. package/dist/test/index.test.d.ts.map +0 -1
  402. package/dist/test/index.test.js +0 -19
  403. package/dist/test/index.test.js.map +0 -1
  404. package/dist/test/matter/devices-matter/baseMatterAccessory.test.d.ts +0 -2
  405. package/dist/test/matter/devices-matter/baseMatterAccessory.test.d.ts.map +0 -1
  406. package/dist/test/matter/devices-matter/baseMatterAccessory.test.js +0 -71
  407. package/dist/test/matter/devices-matter/baseMatterAccessory.test.js.map +0 -1
  408. package/dist/test/matter/platform-matter.additional.test.d.ts +0 -2
  409. package/dist/test/matter/platform-matter.additional.test.d.ts.map +0 -1
  410. package/dist/test/matter/platform-matter.additional.test.js +0 -35
  411. package/dist/test/matter/platform-matter.additional.test.js.map +0 -1
  412. package/dist/test/matter/platform-matter.bleparse.test.d.ts +0 -2
  413. package/dist/test/matter/platform-matter.bleparse.test.d.ts.map +0 -1
  414. package/dist/test/matter/platform-matter.bleparse.test.js +0 -43
  415. package/dist/test/matter/platform-matter.bleparse.test.js.map +0 -1
  416. package/dist/test/matter/platform-matter.cleanup.test.d.ts +0 -2
  417. package/dist/test/matter/platform-matter.cleanup.test.d.ts.map +0 -1
  418. package/dist/test/matter/platform-matter.cleanup.test.js +0 -70
  419. package/dist/test/matter/platform-matter.cleanup.test.js.map +0 -1
  420. package/dist/test/matter/platform-matter.keepstale.test.d.ts +0 -2
  421. package/dist/test/matter/platform-matter.keepstale.test.d.ts.map +0 -1
  422. package/dist/test/matter/platform-matter.keepstale.test.js +0 -27
  423. package/dist/test/matter/platform-matter.keepstale.test.js.map +0 -1
  424. package/dist/test/matter/platform-matter.logging.test.d.ts +0 -2
  425. package/dist/test/matter/platform-matter.logging.test.d.ts.map +0 -1
  426. package/dist/test/matter/platform-matter.logging.test.js +0 -29
  427. package/dist/test/matter/platform-matter.logging.test.js.map +0 -1
  428. package/dist/test/matter/platform-matter.mapping.test.d.ts +0 -2
  429. package/dist/test/matter/platform-matter.mapping.test.d.ts.map +0 -1
  430. package/dist/test/matter/platform-matter.mapping.test.js +0 -43
  431. package/dist/test/matter/platform-matter.mapping.test.js.map +0 -1
  432. package/dist/test/matter/platform-matter.openapi-mapping.test.d.ts +0 -2
  433. package/dist/test/matter/platform-matter.openapi-mapping.test.d.ts.map +0 -1
  434. package/dist/test/matter/platform-matter.openapi-mapping.test.js +0 -84
  435. package/dist/test/matter/platform-matter.openapi-mapping.test.js.map +0 -1
  436. package/dist/test/matter/platform-matter.test.d.ts +0 -2
  437. package/dist/test/matter/platform-matter.test.d.ts.map +0 -1
  438. package/dist/test/matter/platform-matter.test.js +0 -117
  439. package/dist/test/matter/platform-matter.test.js.map +0 -1
  440. package/dist/test/matter/platform-matter.unregister.test.d.ts +0 -2
  441. package/dist/test/matter/platform-matter.unregister.test.d.ts.map +0 -1
  442. package/dist/test/matter/platform-matter.unregister.test.js +0 -30
  443. package/dist/test/matter/platform-matter.unregister.test.js.map +0 -1
  444. package/dist/test/matter/platform-matter.webhook.test.d.ts +0 -2
  445. package/dist/test/matter/platform-matter.webhook.test.d.ts.map +0 -1
  446. package/dist/test/matter/platform-matter.webhook.test.js +0 -46
  447. package/dist/test/matter/platform-matter.webhook.test.js.map +0 -1
  448. package/dist/test/utils.test.d.ts +0 -2
  449. package/dist/test/utils.test.d.ts.map +0 -1
  450. package/dist/test/utils.test.js +0 -95
  451. package/dist/test/utils.test.js.map +0 -1
  452. package/dist/test/verifyconfig.test.d.ts +0 -2
  453. package/dist/test/verifyconfig.test.d.ts.map +0 -1
  454. package/dist/test/verifyconfig.test.js +0 -167
  455. package/dist/test/verifyconfig.test.js.map +0 -1
  456. package/src/custom.d.ts +0 -7
  457. package/src/devices-hap/airpurifier.ts +0 -568
  458. package/src/devices-hap/blindtilt.ts +0 -1049
  459. package/src/devices-hap/bot.ts +0 -910
  460. package/src/devices-hap/ceilinglight.ts +0 -747
  461. package/src/devices-hap/colorbulb.ts +0 -940
  462. package/src/devices-hap/contact.ts +0 -457
  463. package/src/devices-hap/curtain.ts +0 -944
  464. package/src/devices-hap/device.ts +0 -890
  465. package/src/devices-hap/fan.ts +0 -716
  466. package/src/devices-hap/hub.ts +0 -440
  467. package/src/devices-hap/humidifier.ts +0 -762
  468. package/src/devices-hap/iosensor.ts +0 -442
  469. package/src/devices-hap/lightstrip.ts +0 -863
  470. package/src/devices-hap/lock.ts +0 -627
  471. package/src/devices-hap/meter.ts +0 -427
  472. package/src/devices-hap/meterplus.ts +0 -431
  473. package/src/devices-hap/meterpro.ts +0 -523
  474. package/src/devices-hap/motion.ts +0 -390
  475. package/src/devices-hap/plug.ts +0 -427
  476. package/src/devices-hap/relayswitch.ts +0 -727
  477. package/src/devices-hap/robotvacuumcleaner.ts +0 -574
  478. package/src/devices-hap/waterdetector.ts +0 -400
  479. package/src/devices-matter/BaseMatterAccessory.ts +0 -302
  480. package/src/devices-matter/ColorLightAccessory.ts +0 -110
  481. package/src/devices-matter/ColorTemperatureLightAccessory.ts +0 -90
  482. package/src/devices-matter/ContactSensorAccessory.ts +0 -41
  483. package/src/devices-matter/DimmableLightAccessory.ts +0 -192
  484. package/src/devices-matter/DoorLockAccessory.ts +0 -60
  485. package/src/devices-matter/ExtendedColorLightAccessory.ts +0 -122
  486. package/src/devices-matter/FanAccessory.ts +0 -95
  487. package/src/devices-matter/HumiditySensorAccessory.ts +0 -41
  488. package/src/devices-matter/LeakSensorAccessory.ts +0 -40
  489. package/src/devices-matter/LightSensorAccessory.ts +0 -41
  490. package/src/devices-matter/OccupancySensorAccessory.ts +0 -48
  491. package/src/devices-matter/OnOffLightAccessory.ts +0 -125
  492. package/src/devices-matter/OnOffOutletAccessory.ts +0 -51
  493. package/src/devices-matter/OnOffSwitchAccessory.ts +0 -51
  494. package/src/devices-matter/RoboticVacuumAccessory.ts +0 -621
  495. package/src/devices-matter/SmokeCOAlarmAccessory.ts +0 -59
  496. package/src/devices-matter/TemperatureSensorAccessory.ts +0 -43
  497. package/src/devices-matter/ThermostatAccessory.ts +0 -110
  498. package/src/devices-matter/VenetianBlindAccessory.ts +0 -115
  499. package/src/devices-matter/WindowBlindAccessory.ts +0 -135
  500. package/src/devices-matter/custom/PowerStripAccessory.ts +0 -309
  501. package/src/devices-matter/custom/index.ts +0 -8
  502. package/src/devices-matter/index.ts +0 -29
  503. package/src/irdevice/airconditioner.ts +0 -533
  504. package/src/irdevice/airpurifier.ts +0 -252
  505. package/src/irdevice/camera.ts +0 -129
  506. package/src/irdevice/fan.ts +0 -226
  507. package/src/irdevice/irdevice.ts +0 -383
  508. package/src/irdevice/light.ts +0 -246
  509. package/src/irdevice/other.ts +0 -790
  510. package/src/irdevice/tv.ts +0 -378
  511. package/src/irdevice/vacuumcleaner.ts +0 -126
  512. package/src/irdevice/waterheater.ts +0 -127
  513. package/src/platform-hap.ts +0 -3193
  514. package/src/platform-matter.ts +0 -2703
  515. package/src/test/apiRequestTracker.test.ts +0 -417
  516. package/src/test/hap/device-webhook-context.test.ts +0 -136
  517. package/src/test/hap/platform-hap.logging.test.ts +0 -36
  518. package/src/test/hap/platform-hap.test.ts +0 -70
  519. package/src/test/helpers/platform-fixtures.ts +0 -33
  520. package/src/test/homebridge-ui/server.test.ts +0 -486
  521. package/src/test/index.test.ts +0 -24
  522. package/src/test/matter/devices-matter/baseMatterAccessory.test.ts +0 -88
  523. package/src/test/matter/platform-matter.additional.test.ts +0 -44
  524. package/src/test/matter/platform-matter.bleparse.test.ts +0 -47
  525. package/src/test/matter/platform-matter.cleanup.test.ts +0 -86
  526. package/src/test/matter/platform-matter.keepstale.test.ts +0 -37
  527. package/src/test/matter/platform-matter.logging.test.ts +0 -33
  528. package/src/test/matter/platform-matter.mapping.test.ts +0 -57
  529. package/src/test/matter/platform-matter.openapi-mapping.test.ts +0 -109
  530. package/src/test/matter/platform-matter.test.ts +0 -144
  531. package/src/test/matter/platform-matter.unregister.test.ts +0 -39
  532. package/src/test/matter/platform-matter.webhook.test.ts +0 -54
  533. package/src/test/utils.test.ts +0 -96
  534. package/src/test/verifyconfig.test.ts +0 -198
@@ -1,1947 +1,106 @@
1
- {
2
- "pluginAlias": "SwitchBot",
3
- "pluginType": "platform",
4
- "singular": true,
5
- "customUi": true,
6
- "customUiPath": "./dist/homebridge-ui",
7
- "headerDisplay": "<p align='center'><img width='100px' src='https://user-images.githubusercontent.com/9875439/102681754-ac2eb800-4189-11eb-8e17-7c47c804484b.png'></p>\n\nThe **SwitchBot** plugin allows you to control SwitchBot Devices. \n\nTo get started link your SwitchBot account.\n\n1. Download SwitchBot App on App Store or Google Play Store.\n\n2. Register a SwitchBot account and log in into your account.\n\n3. Generate an Open Token within the App.\n\n4. Input your `Open Token` into the parameter below.",
8
- "footerDisplay": "Please raise any issues on our [project page](https://github.com/OpenWonderLabs/homebridge-switchbot/issues).\n\nIf you would like to have other SwitchBot Devices added to this plugin fill out [Feature Request Form](https://github.com/OpenWonderLabs/homebridge-switchbot/issues/new?assignees=&labels=&template=feature_request.md).\n\n[SwitchBot Website](https://www.switch-bot.com)",
9
- "schema": {
10
- "type": "object",
11
- "properties": {
12
- "name": {
13
- "type": "string",
14
- "title": "Name",
15
- "default": "SwitchBot"
16
- },
17
- "credentials": {
18
- "type": "object",
19
- "properties": {
20
- "token": {
21
- "title": "Token",
22
- "type": "string",
23
- "pattern": "^[0-9A-Fa-f]+$",
24
- "x-schema-form": {
25
- "type": "password",
26
- "placeholder": "Paste your Open Token here"
27
- }
28
- },
29
- "secret": {
30
- "title": "Secret",
31
- "type": "string",
32
- "pattern": "^[0-9A-Fa-f]+$",
33
- "x-schema-form": {
34
- "type": "password",
35
- "placeholder": "Paste your Open Secret here"
36
- }
37
- }
38
- }
39
- },
40
- "options": {
41
- "type": "object",
42
- "properties": {
43
- "devices": {
44
- "type": "array",
45
- "items": {
46
- "title": "Devices",
47
- "type": "object",
48
- "properties": {
49
- "configDeviceName": {
50
- "title": "Device Name",
51
- "type": "string",
52
- "pattern": "^[a-zA-Z0-9]+([a-zA-Z0-9 ]*[a-zA-Z0-9]+)?$",
53
- "placeholder": "SwitchBot",
54
- "condition": {
55
- "functionBody": "return (model.options && model.options.devices && model.options.devices[arrayIndices].deviceId);"
56
- }
57
- },
58
- "deviceId": {
59
- "title": "Device ID",
60
- "type": "string",
61
- "placeholder": "81F3UT59513F",
62
- "pattern": "^[0-9A-F]{12}$|^[0-9A-Z0-9]{15}$|^[0-9A-Z0-9]{18}$"
63
- },
64
- "hide_device": {
65
- "title": "Hide Device",
66
- "type": "boolean",
67
- "description": "If true, device will be removed or hidden from HomeKit.",
68
- "condition": {
69
- "functionBody": "return (model.options && model.options.devices && model.options.devices[arrayIndices].deviceId);"
70
- }
71
- },
72
- "configDeviceType": {
73
- "title": "Device Type",
74
- "type": "string",
75
- "condition": {
76
- "functionBody": "return (model.options && model.options.devices && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_device);"
77
- },
78
- "oneOf": [
79
- {
80
- "title": "Blind Tilt",
81
- "enum": [
82
- "Blind Tilt"
83
- ]
84
- },
85
- {
86
- "title": "Bot",
87
- "enum": [
88
- "Bot"
89
- ]
90
- },
91
- {
92
- "title": "Relay Switch 1",
93
- "enum": [
94
- "Relay Switch 1"
95
- ]
96
- },
97
- {
98
- "title": "Relay Switch 1PM",
99
- "enum": [
100
- "Relay Switch 1PM"
101
- ]
102
- },
103
- {
104
- "title": "Battery Circulator Fan",
105
- "enum": [
106
- "Battery Circulator Fan"
107
- ]
108
- },
109
- {
110
- "title": "Ceiling Light",
111
- "enum": [
112
- "Ceiling Light"
113
- ]
114
- },
115
- {
116
- "title": "Ceiling Light Pro",
117
- "enum": [
118
- "Ceiling Light Pro"
119
- ]
120
- },
121
- {
122
- "title": "Color Bulb",
123
- "enum": [
124
- "Color Bulb"
125
- ]
126
- },
127
- {
128
- "title": "Contact Sensor",
129
- "enum": [
130
- "Contact Sensor"
131
- ]
132
- },
133
- {
134
- "title": "Curtain",
135
- "enum": [
136
- "Curtain"
137
- ]
138
- },
139
- {
140
- "title": "Curtain 3",
141
- "enum": [
142
- "Curtain3"
143
- ]
144
- },
145
- {
146
- "title": "Floor Cleaning Robot S10",
147
- "enum": [
148
- "WoSweeper"
149
- ]
150
- },
151
- {
152
- "title": "Hub 2",
153
- "enum": [
154
- "Hub 2"
155
- ]
156
- },
157
- {
158
- "title": "Humidifier",
159
- "enum": [
160
- "Humidifier"
161
- ]
162
- },
163
- {
164
- "title": "Evaporative Humidifier",
165
- "enum": [
166
- "Humidifier2"
167
- ]
168
- },
169
- {
170
- "title": "Indoor/Outdoor Sensor",
171
- "enum": [
172
- "WoIOSensor"
173
- ]
174
- },
175
- {
176
- "title": "Water Detector",
177
- "enum": [
178
- "Water Detector"
179
- ]
180
- },
181
- {
182
- "title": "Meter",
183
- "enum": [
184
- "Meter"
185
- ]
186
- },
187
- {
188
- "title": "Meter Plus (JP)",
189
- "enum": [
190
- "Meter Plus (JP)"
191
- ]
192
- },
193
- {
194
- "title": "Meter Plus (US)",
195
- "enum": [
196
- "MeterPlus"
197
- ]
198
- },
199
- {
200
- "title": "Meter Pro",
201
- "enum": [
202
- "MeterPro"
203
- ]
204
- },
205
- {
206
- "title": "Meter Pro (CO2)",
207
- "enum": [
208
- "MeterPro(CO2)"
209
- ]
210
- },
211
- {
212
- "title": "Mini Robot Vacuum K10+",
213
- "enum": [
214
- "K10+"
215
- ]
216
- },
217
- {
218
- "title": "Mini Robot Vacuum K10+ Pro",
219
- "enum": [
220
- "K10+ Pro"
221
- ]
222
- },
223
- {
224
- "title": "Mini Robot Vacuum K10+ (WoSweeperMini)",
225
- "enum": [
226
- "WoSweeperMini"
227
- ]
228
- },
229
- {
230
- "title": "Mini Robot Vacuum K10+ Pro (WoSweeperMiniPro)",
231
- "enum": [
232
- "WoSweeperMiniPro"
233
- ]
234
- },
235
- {
236
- "title": "Motion Sensor",
237
- "enum": [
238
- "Motion Sensor"
239
- ]
240
- },
241
- {
242
- "title": "Plug",
243
- "enum": [
244
- "Plug"
245
- ]
246
- },
247
- {
248
- "title": "Plug Mini (JP)",
249
- "enum": [
250
- "Plug Mini (JP)"
251
- ]
252
- },
253
- {
254
- "title": "Plug Mini (US)",
255
- "enum": [
256
- "Plug Mini (US)"
257
- ]
258
- },
259
- {
260
- "title": "Robot Vacuum Cleaner S1",
261
- "enum": [
262
- "WoSweeper"
263
- ]
264
- },
265
- {
266
- "title": "Robot Vacuum Cleaner S1 Plus",
267
- "enum": [
268
- "WoSweeperPlus"
269
- ]
270
- },
271
- {
272
- "title": "Robot Vacuum Cleaner S10",
273
- "enum": [
274
- "Robot Vacuum Cleaner S10"
275
- ]
276
- },
277
- {
278
- "title": "Roller Shade",
279
- "enum": [
280
- "WoRollerShade"
281
- ]
282
- },
283
- {
284
- "title": "Smart Fan",
285
- "enum": [
286
- "Smart Fan"
287
- ]
288
- },
289
- {
290
- "title": "Smart Lock",
291
- "enum": [
292
- "Smart Lock"
293
- ]
294
- },
295
- {
296
- "title": "Smart Lock Pro",
297
- "enum": [
298
- "Smart Lock Pro"
299
- ]
300
- },
301
- {
302
- "title": "Smart Lock Ultra",
303
- "enum": [
304
- "Smart Lock Ultra"
305
- ]
306
- },
307
- {
308
- "title": "Strip Light",
309
- "enum": [
310
- "Strip Light"
311
- ]
312
- },
313
- {
314
- "title": "Wallet Finder",
315
- "enum": [
316
- "WalletFinder"
317
- ]
318
- }
319
- ]
320
- },
321
- "connectionType": {
322
- "title": "Connection Type",
323
- "type": "string",
324
- "description": "Bluetooth (BLE) API is only available on certain Device Types, see the Wiki for more information.",
325
- "condition": {
326
- "functionBody": "return (model.options && model.options.devices && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_device);"
327
- },
328
- "oneOf": [
329
- {
330
- "title": "BLE",
331
- "enum": [
332
- "BLE"
333
- ]
334
- },
335
- {
336
- "title": "BLE/OpenAPI",
337
- "enum": [
338
- "BLE/OpenAPI"
339
- ]
340
- },
341
- {
342
- "title": "Disable",
343
- "enum": [
344
- "Disabled"
345
- ]
346
- },
347
- {
348
- "title": "OpenAPI",
349
- "enum": [
350
- "OpenAPI"
351
- ]
352
- }
353
- ]
354
- },
355
- "disablePlatformBLE": {
356
- "title": "Disable Platform BLE",
357
- "type": "boolean",
358
- "description": "If set to true, this will disable the platform BLE for this specific device.",
359
- "condition": {
360
- "functionBody": "return (model.options && model.options.devices && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].connectionType !== 'Disabled');"
361
- }
362
- },
363
- "scanDuration": {
364
- "title": "Scan Duration (Default is 1 Second) for BLE",
365
- "type": "number",
366
- "placeholder": 1,
367
- "condition": {
368
- "functionBody": "return (model.options && model.options.devices && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].connectionType === 'BLE' || model.options.devices[arrayIndices].connectionType === 'BLE/OpenAPI'));"
369
- }
370
- },
371
- "customBLEaddress": {
372
- "title": "Custom BLE Address",
373
- "type": "string",
374
- "placeholder": "81F3UT59513F",
375
- "condition": {
376
- "functionBody": "return (model.options && model.options.devices && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].connectionType === 'BLE' || model.options.devices[arrayIndices].connectionType === 'BLE/OpenAPI'));"
377
- }
378
- },
379
- "webhook": {
380
- "title": "Enable Webhook",
381
- "type": "boolean",
382
- "condition": {
383
- "functionBody": "return (model.options && model.options.devices && model.options.webhookURL && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].connectionType === 'OpenAPI' || model.options.devices[arrayIndices].connectionType === 'BLE/OpenAPI'));"
384
- }
385
- },
386
- "type": {
387
- "title": "What Type of Device do you want to display in the Home App?",
388
- "type": "string",
389
- "default": "",
390
- "placeholder": "outlet",
391
- "condition": {
392
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType === 'Bot' && model.options.devices[arrayIndices].deviceId);"
393
- },
394
- "oneOf": [
395
- {
396
- "title": "Default",
397
- "enum": [
398
- ""
399
- ]
400
- },
401
- {
402
- "title": "Door",
403
- "enum": [
404
- "door"
405
- ]
406
- },
407
- {
408
- "title": "Fan",
409
- "enum": [
410
- "fan"
411
- ]
412
- },
413
- {
414
- "title": "Faucet",
415
- "enum": [
416
- "faucet"
417
- ]
418
- },
419
- {
420
- "title": "Garage Door",
421
- "enum": [
422
- "garagedoor"
423
- ]
424
- },
425
- {
426
- "title": "Lock",
427
- "enum": [
428
- "lock"
429
- ]
430
- },
431
- {
432
- "title": "Outlet",
433
- "enum": [
434
- "outlet"
435
- ]
436
- },
437
- {
438
- "title": "Stateful Programmable Switch (Only Works in 3rd Party Home Apps)",
439
- "enum": [
440
- "stateful"
441
- ]
442
- },
443
- {
444
- "title": "Switch",
445
- "enum": [
446
- "switch"
447
- ]
448
- },
449
- {
450
- "title": "Window",
451
- "enum": [
452
- "window"
453
- ]
454
- },
455
- {
456
- "title": "Window Covering",
457
- "enum": [
458
- "windowcovering"
459
- ]
460
- }
461
- ]
462
- },
463
- "mode": {
464
- "title": "Bot Mode",
465
- "type": "string",
466
- "default": "",
467
- "oneOf": [
468
- {
469
- "title": "Default",
470
- "enum": [
471
- ""
472
- ]
473
- },
474
- {
475
- "title": "Multi-Press",
476
- "enum": [
477
- "multipress"
478
- ]
479
- },
480
- {
481
- "title": "Press",
482
- "enum": [
483
- "press"
484
- ]
485
- },
486
- {
487
- "title": "Switch",
488
- "enum": [
489
- "switch"
490
- ]
491
- }
492
- ],
493
- "condition": {
494
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType === 'Bot' && model.options.devices[arrayIndices].deviceId);"
495
- }
496
- },
497
- "mapping": {
498
- "title": "Mapping Mode",
499
- "type": "string",
500
- "default": "",
501
- "oneOf": [
502
- {
503
- "title": "Default",
504
- "enum": [
505
- ""
506
- ]
507
- },
508
- {
509
- "title": "Down and Up",
510
- "enum": [
511
- "down_and_up"
512
- ]
513
- },
514
- {
515
- "title": "Only Down",
516
- "enum": [
517
- "only_down"
518
- ]
519
- },
520
- {
521
- "title": "Only Up",
522
- "enum": [
523
- "only_up"
524
- ]
525
- },
526
- {
527
- "title": "Up and Down",
528
- "enum": [
529
- "up_and_down"
530
- ]
531
- },
532
- {
533
- "title": "Use Tilt for Direction",
534
- "enum": [
535
- "use_tilt_for_direction"
536
- ]
537
- }
538
- ],
539
- "condition": {
540
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType === 'Blind Tilt' && model.options.devices[arrayIndices].deviceId);"
541
- }
542
- },
543
- "allowPush": {
544
- "title": "Allow Changes to Be Pushed",
545
- "description": "If set to true, this will allow commands to be sent even if device state is already in state that is being pushed.",
546
- "type": "boolean",
547
- "condition": {
548
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].deviceId);"
549
- }
550
- },
551
- "doublePress": {
552
- "title": "How many presses do you want to simulate?",
553
- "type": "number",
554
- "placeholder": "2",
555
- "condition": {
556
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType === 'Bot' && model.options.devices[arrayIndices].deviceId && model.options.devices[arrayIndices].mode);"
557
- }
558
- },
559
- "pushRatePress": {
560
- "title": "Double Press Push Rate",
561
- "type": "number",
562
- "placeholder": "15",
563
- "description": "Indicates the number of seconds between pushes for double presses to SwitchBot API",
564
- "condition": {
565
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType === 'Bot' && model.options.devices[arrayIndices].deviceId && model.options.devices[arrayIndices].mode && model.options.devices[arrayIndices].doublePress > 1);"
566
- }
567
- },
568
- "hide_temperature": {
569
- "title": "Hide Temperature Sensor",
570
- "type": "boolean",
571
- "condition": {
572
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Hub 2' || model.options.devices[arrayIndices].configDeviceType === 'Humidifier' || model.options.devices[arrayIndices].configDeviceType === 'Humidifier2' || model.options.devices[arrayIndices].configDeviceType === 'WoIOSensor' || model.options.devices[arrayIndices].configDeviceType === 'Meter' || model.options.devices[arrayIndices].configDeviceType === 'MeterPlus' || model.options.devices[arrayIndices].configDeviceType === 'Meter Plus (JP)' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro(CO2)') && model.options.devices[arrayIndices].deviceId);"
573
- }
574
- },
575
- "convertUnitTo": {
576
- "title": "Convert Temperature Unit To",
577
- "type": "string",
578
- "condition": {
579
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Hub 2' || model.options.devices[arrayIndices].configDeviceType === 'Humidifier' || model.options.devices[arrayIndices].configDeviceType === 'Humidifier2' || model.options.devices[arrayIndices].configDeviceType === 'WoIOSensor' || model.options.devices[arrayIndices].configDeviceType === 'Meter' || model.options.devices[arrayIndices].configDeviceType === 'MeterPlus' || model.options.devices[arrayIndices].configDeviceType === 'Meter Plus (JP)' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro(CO2)') && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_temperature);"
580
- },
581
- "oneOf": [
582
- {
583
- "title": "Celsius",
584
- "enum": [
585
- "CELSIUS"
586
- ]
587
- },
588
- {
589
- "title": "Fahrenheit",
590
- "enum": [
591
- "FAHRENHEIT"
592
- ]
593
- }
594
- ]
595
- },
596
- "hide_humidity": {
597
- "title": "Hide Humidity Sensor",
598
- "type": "boolean",
599
- "condition": {
600
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Hub 2' || model.options.devices[arrayIndices].configDeviceType === 'WoIOSensor' || model.options.devices[arrayIndices].configDeviceType === 'Meter' || model.options.devices[arrayIndices].configDeviceType === 'MeterPlus' || model.options.devices[arrayIndices].configDeviceType === 'Meter Plus (JP)' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro(CO2)') && model.options.devices[arrayIndices].deviceId);"
601
- }
602
- },
603
- "hide_lightsensor": {
604
- "title": "Hide Light Sensor",
605
- "type": "boolean",
606
- "condition": {
607
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Hub 2' || model.options.devices[arrayIndices].configDeviceType === 'Contact Sensor' || model.options.devices[arrayIndices].configDeviceType === 'Motion Sensor' || model.options.devices[arrayIndices].configDeviceType === 'Blind Tilt' || model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Curtain3' || model.options.devices[arrayIndices].configDeviceType === 'WoRollerShade' || model.options.devices[arrayIndices].configDeviceType === 'Roller Shade') && model.options.devices[arrayIndices].deviceId);"
608
- }
609
- },
610
- "hide_motionsensor": {
611
- "title": "Hide Contact Sensor's Motion Sensor",
612
- "type": "boolean",
613
- "condition": {
614
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType === 'Contact Sensor' && model.options.devices[arrayIndices].deviceId);"
615
- }
616
- },
617
- "hide_contactsensor": {
618
- "title": "Hide Lock's Contact Sensor",
619
- "type": "boolean",
620
- "condition": {
621
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Smart Lock' || model.options.devices[arrayIndices].configDeviceType === 'Smart Lock Pro' || model.options.devices[arrayIndices].configDeviceType === 'Smart Lock Ultra') && model.options.devices[arrayIndices].deviceId);"
622
- }
623
- },
624
- "hide_leak": {
625
- "title": "Hide Water Detector's Leak Sensor",
626
- "type": "boolean",
627
- "condition": {
628
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType === 'Water Detector' && model.options.devices[arrayIndices].deviceId);"
629
- }
630
- },
631
- "disable_group": {
632
- "title": "Disable Grouping",
633
- "type": "boolean",
634
- "condition": {
635
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Curtain3' || model.options.devices[arrayIndices].configDeviceType === 'Blind Tilt' || model.options.devices[arrayIndices].configDeviceType === 'WoRollerShade' || model.options.devices[arrayIndices].configDeviceType === 'Roller Shade') && model.options.devices[arrayIndices].deviceId);"
636
- }
637
- },
638
- "disableCaching": {
639
- "title": "Disable Caching",
640
- "type": "boolean",
641
- "condition": {
642
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].deviceId);"
643
- }
644
- },
645
- "adaptiveLightingShift": {
646
- "title": "Adaptive Lighting Shift",
647
- "type": "number",
648
- "placeholder": "-1",
649
- "description": "The mired for each Adaptive Lighting update will be increased by this value, making the light appear warmer. Set to -1 to remove Adaptive Lighting feature. Must be -1 or more.",
650
- "condition": {
651
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Color Bulb' || model.options.devices[arrayIndices].configDeviceType === 'Strip Light' || model.options.devices[arrayIndices].configDeviceType === 'Ceiling Light' || model.options.devices[arrayIndices].configDeviceType === 'Ceiling Light Pro') && model.options.devices[arrayIndices].deviceId);"
652
- }
653
- },
654
- "activate_latchbutton": {
655
- "title": "Activate Latch Button",
656
- "type": "boolean",
657
- "condition": {
658
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Smart Lock' || model.options.devices[arrayIndices].configDeviceType === 'Smart Lock Pro' || model.options.devices[arrayIndices].configDeviceType === 'Smart Lock Ultra') && model.options.devices[arrayIndices].deviceId);"
659
- }
660
- },
661
- "activate_dryingfilter": {
662
- "title": "Enable Drying Filter Switch",
663
- "type": "boolean",
664
- "description": "Humidifier2 only. Adds a HomeKit switch that triggers the built-in Drying Filter mode via OpenAPI.",
665
- "condition": {
666
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType === 'Humidifier2' && model.options.devices[arrayIndices].deviceId);"
667
- }
668
- },
669
- "dry": {
670
- "title": "Water Detector's Dry Alert",
671
- "type": "boolean",
672
- "description": "If true, the Water Detector will send an alert when it is dry.",
673
- "condition": {
674
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType === 'Water Detector' && model.options.devices[arrayIndices].deviceId);"
675
- }
676
- },
677
- "set_minStep": {
678
- "title": "Set Minimum Step",
679
- "type": "number",
680
- "placeholder": "1",
681
- "description": "Sets the minimum steps device will take. So if set to 20, it would allow you to set the curtain state to 0, 20, 40, 60, 80, and 100.",
682
- "condition": {
683
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Strip Light' || model.options.devices[arrayIndices].configDeviceType === 'Color Bulb' || model.options.devices[arrayIndices].configDeviceType === 'Blind Tilt' || model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Curtain3' || model.options.devices[arrayIndices].configDeviceType === 'WoRollerShade' || model.options.devices[arrayIndices].configDeviceType === 'Roller Shade' || model.options.devices[arrayIndices].configDeviceType === 'Humidifier' || model.options.devices[arrayIndices].configDeviceType === 'Humidifier2') && model.options.devices[arrayIndices].deviceId);"
684
- }
685
- },
686
- "set_min": {
687
- "title": "Set Minimum Open State",
688
- "type": "number",
689
- "placeholder": "0",
690
- "description": "Sets the minimum percentage before needed to set to Open.",
691
- "condition": {
692
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Blind Tilt' || model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Curtain3' || model.options.devices[arrayIndices].configDeviceType === 'WoRollerShade' || model.options.devices[arrayIndices].configDeviceType === 'Roller Shade' || model.options.devices[arrayIndices].configDeviceType === 'Hub 2' || model.options.devices[arrayIndices].configDeviceType === 'Motion Sensor' || model.options.devices[arrayIndices].configDeviceType === 'Contact Sensor' || model.options.devices[arrayIndices].configDeviceType === 'Humidifier' || model.options.devices[arrayIndices].configDeviceType === 'Humidifier2' || model.options.devices[arrayIndices].configDeviceType === 'Strip Light' || model.options.devices[arrayIndices].configDeviceType === 'Ceiling Light' || model.options.devices[arrayIndices].configDeviceType === 'Ceiling Light Pro') && model.options.devices[arrayIndices].deviceId);"
693
- }
694
- },
695
- "set_max": {
696
- "title": "Set Maximum Close State",
697
- "type": "number",
698
- "placeholder": "100",
699
- "description": "Sets the maximum percentage before needing to set to Closed.",
700
- "condition": {
701
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Blind Tilt' || model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Curtain3' || model.options.devices[arrayIndices].configDeviceType === 'WoRollerShade' || model.options.devices[arrayIndices].configDeviceType === 'Roller Shade' || model.options.devices[arrayIndices].configDeviceType === 'Hub 2' || model.options.devices[arrayIndices].configDeviceType === 'Motion Sensor' || model.options.devices[arrayIndices].configDeviceType === 'Contact Sensor' || model.options.devices[arrayIndices].configDeviceType === 'Humidifier' || model.options.devices[arrayIndices].configDeviceType === 'Humidifier2' || model.options.devices[arrayIndices].configDeviceType === 'Strip Light' || model.options.devices[arrayIndices].configDeviceType === 'Ceiling Light' || model.options.devices[arrayIndices].configDeviceType === 'Ceiling Light Pro') && model.options.devices[arrayIndices].deviceId);"
702
- }
703
- },
704
- "set_minlux": {
705
- "title": "Set Min Lux",
706
- "type": "number",
707
- "placeholder": "1",
708
- "condition": {
709
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Hub 2' || model.options.devices[arrayIndices].configDeviceType === 'Contact Sensor' || model.options.devices[arrayIndices].configDeviceType === 'Motion Sensor' || model.options.devices[arrayIndices].configDeviceType === 'Blind Tilt' || model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Curtain3' || model.options.devices[arrayIndices].configDeviceType === 'WoRollerShade' || model.options.devices[arrayIndices].configDeviceType === 'Roller Shade') && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_lightsensor);"
710
- }
711
- },
712
- "set_maxlux": {
713
- "title": "Set Max Lux",
714
- "type": "number",
715
- "placeholder": "6001",
716
- "condition": {
717
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Hub 2' || model.options.devices[arrayIndices].configDeviceType === 'Contact Sensor' || model.options.devices[arrayIndices].configDeviceType === 'Motion Sensor' || model.options.devices[arrayIndices].configDeviceType === 'Blind Tilt' || model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Curtain3' || model.options.devices[arrayIndices].configDeviceType === 'WoRollerShade' || model.options.devices[arrayIndices].configDeviceType === 'Roller Shade') && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_lightsensor);"
718
- }
719
- },
720
- "setOpenMode": {
721
- "title": "Opening Mode",
722
- "type": "string",
723
- "condition": {
724
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Curtain3' || model.options.devices[arrayIndices].configDeviceType === 'Blind Tilt' || model.options.devices[arrayIndices].configDeviceType === 'WoRollerShade' || model.options.devices[arrayIndices].configDeviceType === 'Roller Shade') && model.options.devices[arrayIndices].deviceId);"
725
- },
726
- "oneOf": [
727
- {
728
- "enum": [
729
- "0"
730
- ],
731
- "title": "Performance Mode"
732
- },
733
- {
734
- "enum": [
735
- "1"
736
- ],
737
- "title": "Silent Mode"
738
- }
739
- ]
740
- },
741
- "setCloseMode": {
742
- "title": "Closing Mode",
743
- "type": "string",
744
- "condition": {
745
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Curtain3' || model.options.devices[arrayIndices].configDeviceType === 'Blind Tilt' || model.options.devices[arrayIndices].configDeviceType === 'WoRollerShade' || model.options.devices[arrayIndices].configDeviceType === 'Roller Shade') && model.options.devices[arrayIndices].deviceId);"
746
- },
747
- "oneOf": [
748
- {
749
- "enum": [
750
- "0"
751
- ],
752
- "title": "Performance Mode"
753
- },
754
- {
755
- "enum": [
756
- "1"
757
- ],
758
- "title": "Silent Mode"
759
- }
760
- ]
761
- },
762
- "silentModeSwitch": {
763
- "title": "Enable Silent Mode Switches",
764
- "type": "boolean",
765
- "condition": {
766
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Curtain3' || model.options.devices[arrayIndices].configDeviceType === 'Blind Tilt' || model.options.devices[arrayIndices].configDeviceType === 'WoRollerShade' || model.options.devices[arrayIndices].configDeviceType === 'Roller Shade') && model.options.devices[arrayIndices].deviceId);"
767
- }
768
- },
769
- "maxRetry": {
770
- "title": "Max Retries for BLE",
771
- "type": "number",
772
- "placeholder": "5",
773
- "condition": {
774
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].deviceId && (model.options.devices[arrayIndices].connectionType === 'BLE' || model.options.devices[arrayIndices].connectionType === 'BLE/OpenAPI'));"
775
- }
776
- },
777
- "maxRetries": {
778
- "title": "Device Max Retries for OpenAPI",
779
- "type": "number",
780
- "placeholder": 5,
781
- "condition": {
782
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].deviceId && (model.options.devices[arrayIndices].connectionType === 'OpenAPI' || model.options.devices[arrayIndices].connectionType === 'BLE/OpenAPI'));"
783
- }
784
- },
785
- "delayBetweenRetries": {
786
- "title": "Device Delay Between Retries for OpenAPI (In Seconds)",
787
- "type": "number",
788
- "placeholder": 3,
789
- "condition": {
790
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].deviceId && (model.options.devices[arrayIndices].connectionType === 'OpenAPI' || model.options.devices[arrayIndices].connectionType === 'BLE/OpenAPI'));"
791
- }
792
- },
793
- "mqttURL": {
794
- "title": "MQTT URL (Device Specific)",
795
- "type": "string",
796
- "placeholder": "192.168.7.1",
797
- "condition": {
798
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].deviceId && (model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Water Detector' || model.options.devices[arrayIndices].configDeviceType === 'WoIOSensor' || model.options.devices[arrayIndices].configDeviceType === 'Hub 2' || model.options.devices[arrayIndices].configDeviceType === 'Meter' || model.options.devices[arrayIndices].configDeviceType === 'MeterPlus' || model.options.devices[arrayIndices].configDeviceType === 'Meter Plus (JP)' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro(CO2)'));"
799
- }
800
- },
801
- "mqttOptions": {
802
- "title": "MQTT Options (Device Specific)",
803
- "type": "string",
804
- "condition": {
805
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].deviceId && model.options.devices[arrayIndices].mqttURL && (model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Water Detector' || model.options.devices[arrayIndices].configDeviceType === 'WoIOSensor' || model.options.devices[arrayIndices].configDeviceType === 'Hub 2' || model.options.devices[arrayIndices].configDeviceType === 'Meter' || model.options.devices[arrayIndices].configDeviceType === 'MeterPlus' || model.options.devices[arrayIndices].configDeviceType === 'Meter Plus (JP)' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro(CO2)'));"
806
- }
807
- },
808
- "mqttPubOptions": {
809
- "title": "MQTT Pub Options (Device Specific)",
810
- "type": "string",
811
- "condition": {
812
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].deviceId && model.options.devices[arrayIndices].mqttURL && (model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Water Detector' || model.options.devices[arrayIndices].configDeviceType === 'WoIOSensor' || model.options.devices[arrayIndices].configDeviceType === 'Hub 2' || model.options.devices[arrayIndices].configDeviceType === 'Meter' || model.options.devices[arrayIndices].configDeviceType === 'MeterPlus' || model.options.devices[arrayIndices].configDeviceType === 'Meter Plus (JP)' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro(CO2)'));"
813
- }
814
- },
815
- "history": {
816
- "title": "EVE History",
817
- "type": "boolean",
818
- "condition": {
819
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].deviceId && (model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Water Detector' || model.options.devices[arrayIndices].configDeviceType === 'WoIOSensor' || model.options.devices[arrayIndices].configDeviceType === 'Hub 2' || model.options.devices[arrayIndices].configDeviceType === 'Meter' || model.options.devices[arrayIndices].configDeviceType === 'MeterPlus' || model.options.devices[arrayIndices].configDeviceType === 'Meter Plus (JP)' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro' || model.options.devices[arrayIndices].configDeviceType === 'MeterPro(CO2)'));"
820
- }
821
- },
822
- "offline": {
823
- "title": "Offline as Off",
824
- "type": "boolean",
825
- "condition": {
826
- "functionBody": "return (model.options && model.options.devices && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType);"
827
- }
828
- },
829
- "firmware": {
830
- "title": "Firmware Override",
831
- "type": "string",
832
- "placeholder": "1.2.8",
833
- "condition": {
834
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].deviceId && model.options.devices[arrayIndices].configDeviceType);"
835
- }
836
- },
837
- "external": {
838
- "title": "External Accessory",
839
- "type": "boolean",
840
- "condition": {
841
- "functionBody": "return (model.options && model.options.devices && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType);"
842
- }
843
- },
844
- "logging": {
845
- "title": "Device Logging Override Setting",
846
- "type": "string",
847
- "default": "",
848
- "condition": {
849
- "functionBody": "return (model.options && model.options.devices && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType);"
850
- },
851
- "oneOf": [
852
- {
853
- "title": "Debug Logging",
854
- "enum": [
855
- "debug"
856
- ]
857
- },
858
- {
859
- "title": "No Logging",
860
- "enum": [
861
- "none"
862
- ]
863
- },
864
- {
865
- "title": "Standard Logging",
866
- "enum": [
867
- "standard"
868
- ]
869
- }
870
- ]
871
- },
872
- "refreshRate": {
873
- "title": "Device Refresh Rate",
874
- "type": "number",
875
- "placeholder": 360,
876
- "condition": {
877
- "functionBody": "return (model.options && model.options.devices && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType);"
878
- }
879
- },
880
- "updateRate": {
881
- "title": "Update Rate",
882
- "type": "number",
883
- "minimum": 1,
884
- "placeholder": 5,
885
- "description": "Indicates the number of seconds before refreshing status while updating progress.",
886
- "condition": {
887
- "functionBody": "return (model.options && model.options.devices && !model.options.devices[arrayIndices].hide_device && (model.options.devices[arrayIndices].configDeviceType === 'Curtain' || model.options.devices[arrayIndices].configDeviceType === 'Curtain3' || model.options.devices[arrayIndices].configDeviceType === 'Blind Tilt' || model.options.devices[arrayIndices].configDeviceType === 'WoRollerShade' || model.options.devices[arrayIndices].configDeviceType === 'Roller Shade') && model.options.devices[arrayIndices].deviceId);"
888
- }
889
- },
890
- "pushRate": {
891
- "title": "Device Push Rate",
892
- "type": "number",
893
- "placeholder": 360,
894
- "condition": {
895
- "functionBody": "return (model.options && model.options.devices && model.options.devices[arrayIndices].deviceId && !model.options.devices[arrayIndices].hide_device && model.options.devices[arrayIndices].configDeviceType);"
896
- }
897
- }
898
- }
899
- },
900
- "uniqueItems": true
901
- },
902
- "irdevices": {
903
- "type": "array",
904
- "items": {
905
- "title": "IR Devices",
906
- "type": "object",
907
- "properties": {
908
- "configDeviceName": {
909
- "title": "Device Name",
910
- "type": "string",
911
- "placeholder": "SwitchBot",
912
- "pattern": "^[a-zA-Z0-9]+([a-zA-Z0-9 ]*[a-zA-Z0-9]+)?$",
913
- "condition": {
914
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId);"
915
- }
916
- },
917
- "deviceId": {
918
- "title": "Device ID",
919
- "type": "string",
920
- "placeholder": "81F3UT59513F",
921
- "pattern": "^[0-9A-Za-z]{2}-[0-9A-Za-z]{12}-[0-9A-Za-z]{8}$|^[0-9A-Za-z]{18}$"
922
- },
923
- "hide_device": {
924
- "title": "Hide Device",
925
- "type": "boolean",
926
- "description": "If true, device will be removed or hidden from HomeKit.",
927
- "condition": {
928
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId);"
929
- }
930
- },
931
- "configRemoteType": {
932
- "title": "Remote Type",
933
- "type": "string",
934
- "oneOf": [
935
- {
936
- "title": "Air Conditioner (IR)",
937
- "enum": [
938
- "Air Conditioner"
939
- ]
940
- },
941
- {
942
- "title": "Air Purifier (IR)",
943
- "enum": [
944
- "Air Purifier"
945
- ]
946
- },
947
- {
948
- "title": "Camera (IR)",
949
- "enum": [
950
- "Camera"
951
- ]
952
- },
953
- {
954
- "title": "DIY Air Conditioner (IR)",
955
- "enum": [
956
- "DIY Air Conditioner"
957
- ]
958
- },
959
- {
960
- "title": "DIY Air Purifier (IR)",
961
- "enum": [
962
- "DIY Air Purifier"
963
- ]
964
- },
965
- {
966
- "title": "DIY Camera (IR)",
967
- "enum": [
968
- "DIY Camera"
969
- ]
970
- },
971
- {
972
- "title": "DIY DVD (IR)",
973
- "enum": [
974
- "DIY DVD"
975
- ]
976
- },
977
- {
978
- "title": "DIY Fan (IR)",
979
- "enum": [
980
- "DIY Fan"
981
- ]
982
- },
983
- {
984
- "title": "DIY IPTV (IR)",
985
- "enum": [
986
- "DIY IPTV"
987
- ]
988
- },
989
- {
990
- "title": "DIY Light (IR)",
991
- "enum": [
992
- "DIY Light"
993
- ]
994
- },
995
- {
996
- "title": "DIY Projector (IR)",
997
- "enum": [
998
- "DIY Projector"
999
- ]
1000
- },
1001
- {
1002
- "title": "DIY Set Top Box (IR)",
1003
- "enum": [
1004
- "DIY Set Top Box"
1005
- ]
1006
- },
1007
- {
1008
- "title": "DIY Speaker (IR)",
1009
- "enum": [
1010
- "DIY Speaker"
1011
- ]
1012
- },
1013
- {
1014
- "title": "DIY TV (IR)",
1015
- "enum": [
1016
- "DIY TV"
1017
- ]
1018
- },
1019
- {
1020
- "title": "DIY Vacuum Cleaner (IR)",
1021
- "enum": [
1022
- "DIY Vacuum Cleaner"
1023
- ]
1024
- },
1025
- {
1026
- "title": "DIY Water Heater (IR)",
1027
- "enum": [
1028
- "DIY Water Heater"
1029
- ]
1030
- },
1031
- {
1032
- "title": "DVD (IR)",
1033
- "enum": [
1034
- "DVD"
1035
- ]
1036
- },
1037
- {
1038
- "title": "Fan (IR)",
1039
- "enum": [
1040
- "Fan"
1041
- ]
1042
- },
1043
- {
1044
- "title": "IPTV (IR)",
1045
- "enum": [
1046
- "IPTV"
1047
- ]
1048
- },
1049
- {
1050
- "title": "Light (IR)",
1051
- "enum": [
1052
- "Light"
1053
- ]
1054
- },
1055
- {
1056
- "title": "Others (IR)",
1057
- "enum": [
1058
- "Others"
1059
- ]
1060
- },
1061
- {
1062
- "title": "Projector (IR)",
1063
- "enum": [
1064
- "Projector"
1065
- ]
1066
- },
1067
- {
1068
- "title": "Set Top Box (IR)",
1069
- "enum": [
1070
- "Set Top Box"
1071
- ]
1072
- },
1073
- {
1074
- "title": "Speaker (IR)",
1075
- "enum": [
1076
- "Speaker"
1077
- ]
1078
- },
1079
- {
1080
- "title": "TV (IR)",
1081
- "enum": [
1082
- "TV"
1083
- ]
1084
- },
1085
- {
1086
- "title": "Vacuum Cleaner (IR)",
1087
- "enum": [
1088
- "Vacuum Cleaner"
1089
- ]
1090
- },
1091
- {
1092
- "title": "Water Heater (IR)",
1093
- "enum": [
1094
- "Water Heater"
1095
- ]
1096
- }
1097
- ],
1098
- "condition": {
1099
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device);"
1100
- }
1101
- },
1102
- "connectionType": {
1103
- "title": "Connection Type",
1104
- "type": "string",
1105
- "placeholder": "OpenAPI",
1106
- "oneOf": [
1107
- {
1108
- "enum": [
1109
- "Disabled"
1110
- ],
1111
- "title": "Disable"
1112
- },
1113
- {
1114
- "enum": [
1115
- "OpenAPI"
1116
- ],
1117
- "title": "OpenAPI"
1118
- }
1119
- ],
1120
- "description": "Enables OpenAPI, if disabled will leave device in HomeKit and commands will not be sent to OpenAPI.",
1121
- "condition": {
1122
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device && model.options.irdevices[arrayIndices].configRemoteType);"
1123
- }
1124
- },
1125
- "type": {
1126
- "title": "What Type of Device do you want to display in the Home App?",
1127
- "type": "string",
1128
- "default": "",
1129
- "oneOf": [
1130
- {
1131
- "title": "Door",
1132
- "enum": [
1133
- "door"
1134
- ]
1135
- },
1136
- {
1137
- "title": "Fan",
1138
- "enum": [
1139
- "fan"
1140
- ]
1141
- },
1142
- {
1143
- "title": "Faucet",
1144
- "enum": [
1145
- "faucet"
1146
- ]
1147
- },
1148
- {
1149
- "title": "Garage Door",
1150
- "enum": [
1151
- "garagedoor"
1152
- ]
1153
- },
1154
- {
1155
- "title": "Lock",
1156
- "enum": [
1157
- "lock"
1158
- ]
1159
- },
1160
- {
1161
- "title": "Outlet",
1162
- "enum": [
1163
- "outlet"
1164
- ]
1165
- },
1166
- {
1167
- "title": "Stateful Programmable Switch (Only Works in 3rd Party Home Apps)",
1168
- "enum": [
1169
- "stateful"
1170
- ]
1171
- },
1172
- {
1173
- "title": "Switch",
1174
- "enum": [
1175
- "switch"
1176
- ]
1177
- },
1178
- {
1179
- "title": "Window",
1180
- "enum": [
1181
- "window"
1182
- ]
1183
- },
1184
- {
1185
- "title": "Window Covering",
1186
- "enum": [
1187
- "windowcovering"
1188
- ]
1189
- }
1190
- ],
1191
- "condition": {
1192
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && model.options.irdevices[arrayIndices].configRemoteType === 'Others' && model.options.irdevices[arrayIndices].deviceId);"
1193
- }
1194
- },
1195
- "customize": {
1196
- "title": "Custom IR Commands",
1197
- "type": "boolean",
1198
- "description": "Enables Custom IR Commands",
1199
- "condition": {
1200
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device && model.options.irdevices[arrayIndices].configRemoteType);"
1201
- }
1202
- },
1203
- "customOn": {
1204
- "title": "Custom <em class='primary-text'> On </em> Command",
1205
- "type": "string",
1206
- "placeholder": "On",
1207
- "condition": {
1208
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device && model.options.irdevices[arrayIndices].configRemoteType && model.options.irdevices[arrayIndices].customize);"
1209
- }
1210
- },
1211
- "customOff": {
1212
- "title": "Custom <em class='primary-text'> Off </em> Command",
1213
- "type": "string",
1214
- "placeholder": "Off",
1215
- "condition": {
1216
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device && model.options.irdevices[arrayIndices].configRemoteType && model.options.irdevices[arrayIndices].customize);"
1217
- }
1218
- },
1219
- "commandType": {
1220
- "title": "Command Type",
1221
- "type": "string",
1222
- "description": "Customize your command type, Default: command",
1223
- "placeholder": "tag",
1224
- "condition": {
1225
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device && model.options.irdevices[arrayIndices].configRemoteType && model.options.irdevices[arrayIndices].customize);"
1226
- }
1227
- },
1228
- "disablePushOn": {
1229
- "title": "Disable Sending <em class='primary-text'> On </em> Command",
1230
- "type": "boolean",
1231
- "condition": {
1232
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device && model.options.irdevices[arrayIndices].configRemoteType);"
1233
- }
1234
- },
1235
- "disablePushOff": {
1236
- "title": "Disable Sending <em class='primary-text'> Off </em> Command",
1237
- "type": "boolean",
1238
- "condition": {
1239
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device && model.options.irdevices[arrayIndices].configRemoteType);"
1240
- }
1241
- },
1242
- "disablePushDetail": {
1243
- "title": "Disable Sending <em class='primary-text'> Detail </em> Command(s)",
1244
- "description": "Details would be like tempearture for Air Conditioners.",
1245
- "type": "boolean",
1246
- "condition": {
1247
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device && model.options.irdevices[arrayIndices].configRemoteType);"
1248
- }
1249
- },
1250
- "hide_automode": {
1251
- "title": "Hide Auto Mode on IR Air Conditioners",
1252
- "type": "boolean",
1253
- "condition": {
1254
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Air Conditioner' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Air Conditioner') && model.options.irdevices[arrayIndices].deviceId);"
1255
- }
1256
- },
1257
- "set_max_heat": {
1258
- "title": "IR Air Conditioner Maximum Heat Range",
1259
- "type": "number",
1260
- "placeholder": "25",
1261
- "description": "Set the maximum heat range for the IR Air Conditioner.",
1262
- "condition": {
1263
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Air Conditioner' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Air Conditioner') && model.options.irdevices[arrayIndices].deviceId);"
1264
- }
1265
- },
1266
- "set_min_heat": {
1267
- "title": "IR Air Conditioner Minimum Heat Range",
1268
- "type": "number",
1269
- "placeholder": "0",
1270
- "description": "Set the minimum heat range for the IR Air Conditioner.",
1271
- "condition": {
1272
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Air Conditioner' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Air Conditioner') && model.options.irdevices[arrayIndices].deviceId);"
1273
- }
1274
- },
1275
- "set_max_cool": {
1276
- "title": "IR Air Conditioner Maximum Cool Range",
1277
- "type": "number",
1278
- "placeholder": "35",
1279
- "description": "Set the maximum cool range for the IR Air Conditioner.",
1280
- "multipleOf": 1,
1281
- "condition": {
1282
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Air Conditioner' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Air Conditioner') && model.options.irdevices[arrayIndices].deviceId);"
1283
- }
1284
- },
1285
- "set_min_cool": {
1286
- "title": "IR Air Conditioner Minimum Cool Range",
1287
- "type": "number",
1288
- "placeholder": "10",
1289
- "description": "Set the minimum cool range for the IR Air Conditioner.",
1290
- "condition": {
1291
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Air Conditioner' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Air Conditioner') && model.options.irdevices[arrayIndices].deviceId);"
1292
- }
1293
- },
1294
- "meterType": {
1295
- "title": "Use an existing Switchbot device for temperature/humidity",
1296
- "type": "string",
1297
- "oneOf": [
1298
- {
1299
- "title": "Hub 2",
1300
- "enum": [
1301
- "Hub 2"
1302
- ]
1303
- },
1304
- {
1305
- "title": "Meter",
1306
- "enum": [
1307
- "Meter"
1308
- ]
1309
- },
1310
- {
1311
- "title": "Meter Plus",
1312
- "enum": [
1313
- "MeterPlus"
1314
- ]
1315
- },
1316
- {
1317
- "title": "Meter Plus (JP)",
1318
- "enum": [
1319
- "Meter Plus (JP)"
1320
- ]
1321
- },
1322
- {
1323
- "title": "Meter Pro",
1324
- "enum": [
1325
- "MeterPro"
1326
- ]
1327
- },
1328
- {
1329
- "title": "Meter Pro (CO2)",
1330
- "enum": [
1331
- "MeterPro(CO2)"
1332
- ]
1333
- },
1334
- {
1335
- "title": "WoIOSensor",
1336
- "enum": [
1337
- "WoIOSensor"
1338
- ]
1339
- },
1340
- {
1341
- "title": "Humidifier",
1342
- "enum": [
1343
- "Humidifier"
1344
- ]
1345
- }
1346
- ],
1347
- "condition": {
1348
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Air Conditioner' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Air Conditioner') && model.options.irdevices[arrayIndices].deviceId);"
1349
- }
1350
- },
1351
- "meterId": {
1352
- "title": "Device ID of the device to use for temperature/humidity",
1353
- "type": "string",
1354
- "condition": {
1355
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Air Conditioner' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Air Conditioner') && model.options.irdevices[arrayIndices].deviceId && model.options.irdevices[arrayIndices].irair?.meterType);"
1356
- }
1357
- },
1358
- "rotation_speed": {
1359
- "title": "Enable Rotation Speed",
1360
- "type": "boolean",
1361
- "condition": {
1362
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Fan' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Fan') && model.options.irdevices[arrayIndices].deviceId);"
1363
- }
1364
- },
1365
- "swing_mode": {
1366
- "title": "Enable Swing Mode",
1367
- "type": "boolean",
1368
- "condition": {
1369
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Fan' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Fan') && model.options.irdevices[arrayIndices].deviceId);"
1370
- }
1371
- },
1372
- "set_minStep": {
1373
- "title": "Set Min Step",
1374
- "type": "number",
1375
- "placeholder": "1",
1376
- "condition": {
1377
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Fan' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Fan') && model.options.irdevices[arrayIndices].deviceId && model.options.irdevices[arrayIndices].irfan && !model.options.irdevices[arrayIndices].irfan.rotation_speed);"
1378
- }
1379
- },
1380
- "set_min": {
1381
- "title": "Set Min",
1382
- "type": "number",
1383
- "placeholder": "0",
1384
- "condition": {
1385
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Fan' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Fan') && model.options.irdevices[arrayIndices].deviceId && model.options.irdevices[arrayIndices].irfan && !model.options.irdevices[arrayIndices].irfan.rotation_speed);"
1386
- }
1387
- },
1388
- "set_max": {
1389
- "title": "Set Max",
1390
- "type": "number",
1391
- "placeholder": "100",
1392
- "condition": {
1393
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Fan' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Fan') && model.options.irdevices[arrayIndices].deviceId && model.options.irdevices[arrayIndices].irfan && !model.options.irdevices[arrayIndices].irfan.rotation_speed);"
1394
- }
1395
- },
1396
- "stateless": {
1397
- "title": "Enable Stateless Buttons",
1398
- "type": "boolean",
1399
- "condition": {
1400
- "functionBody": "return (model.options && model.options.irdevices && !model.options.irdevices[arrayIndices].hide_device && (model.options.irdevices[arrayIndices].configRemoteType === 'Light' || model.options.irdevices[arrayIndices].configRemoteType === 'DIY Light') && model.options.irdevices[arrayIndices].deviceId);"
1401
- }
1402
- },
1403
- "external": {
1404
- "title": "External Accessory",
1405
- "type": "boolean",
1406
- "condition": {
1407
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device && model.options.irdevices[arrayIndices].configRemoteType);"
1408
- }
1409
- },
1410
- "disableCaching": {
1411
- "title": "Disable Caching",
1412
- "type": "boolean",
1413
- "condition": {
1414
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device);"
1415
- }
1416
- },
1417
- "offline": {
1418
- "title": "Offline as Off",
1419
- "type": "boolean",
1420
- "condition": {
1421
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device);"
1422
- }
1423
- },
1424
- "history": {
1425
- "title": "EVE History",
1426
- "type": "boolean",
1427
- "condition": {
1428
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device);"
1429
- }
1430
- },
1431
- "firmware": {
1432
- "title": "Firmware Override",
1433
- "type": "string",
1434
- "placeholder": "1.2.8",
1435
- "condition": {
1436
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device && model.options.irdevices[arrayIndices].configRemoteType);"
1437
- }
1438
- },
1439
- "logging": {
1440
- "title": "Device Logging Override Setting",
1441
- "type": "string",
1442
- "default": "",
1443
- "oneOf": [
1444
- {
1445
- "title": "Debug Logging",
1446
- "enum": [
1447
- "debug"
1448
- ]
1449
- },
1450
- {
1451
- "title": "Default Logging",
1452
- "enum": [
1453
- ""
1454
- ]
1455
- },
1456
- {
1457
- "title": "No Logging",
1458
- "enum": [
1459
- "none"
1460
- ]
1461
- },
1462
- {
1463
- "title": "Standard Logging",
1464
- "enum": [
1465
- "standard"
1466
- ]
1467
- }
1468
- ],
1469
- "condition": {
1470
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device && model.options.irdevices[arrayIndices].configRemoteType);"
1471
- }
1472
- },
1473
- "refreshRate": {
1474
- "title": "Device Refresh Rate",
1475
- "type": "number",
1476
- "placeholder": 360,
1477
- "condition": {
1478
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device);"
1479
- }
1480
- },
1481
- "updateRate": {
1482
- "title": "Update Rate",
1483
- "type": "number",
1484
- "minimum": 1,
1485
- "placeholder": 5,
1486
- "description": "Indicates the number of seconds before refreshing status while updating progress.",
1487
- "condition": {
1488
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device);"
1489
- }
1490
- },
1491
- "pushRate": {
1492
- "title": "Device Push Rate",
1493
- "type": "number",
1494
- "placeholder": 360,
1495
- "condition": {
1496
- "functionBody": "return (model.options && model.options.irdevices && model.options.irdevices[arrayIndices].deviceId && !model.options.irdevices[arrayIndices].hide_device);"
1497
- }
1498
- }
1499
- }
1500
- },
1501
- "uniqueItems": true
1502
- },
1503
- "matterBatchRefreshRate": {
1504
- "title": "Matter Batch Refresh Interval (seconds)",
1505
- "type": "number",
1506
- "placeholder": 300,
1507
- "description": "Platform-level interval for batched Matter device status refreshes. Devices with a per-device refreshRate will use their own timer and be excluded from the batch."
1508
- },
1509
- "matterBatchConcurrency": {
1510
- "title": "Matter Batch Concurrency",
1511
- "type": "number",
1512
- "placeholder": 5,
1513
- "description": "Maximum number of parallel OpenAPI status calls during a batch refresh."
1514
- },
1515
- "matterBatchEnabled": {
1516
- "title": "Enable Matter Batch Refresh",
1517
- "type": "boolean",
1518
- "default": true,
1519
- "description": "When true (default), the platform runs a single batched refresh timer. Devices with a per-device refreshRate still use their own timers."
1520
- },
1521
- "matterBatchJitter": {
1522
- "title": "Matter Batch Start Jitter (seconds)",
1523
- "type": "number",
1524
- "placeholder": 30,
1525
- "description": "Random delay added before starting the platform-level batch timer to reduce synchronized spikes."
1526
- },
1527
- "BLE": {
1528
- "title": "Enable BLE Scanning",
1529
- "type": "boolean"
1530
- },
1531
- "discoverBLE": {
1532
- "title": "Discover BLE Devices",
1533
- "type": "boolean"
1534
- },
1535
- "disableLogsforBLE": {
1536
- "title": "Disable Logging from BLE",
1537
- "type": "boolean"
1538
- },
1539
- "disableLogsforOpenAPI": {
1540
- "title": "Disable Logging from OpenAPI",
1541
- "type": "boolean"
1542
- },
1543
- "hostname": {
1544
- "title": "hostname",
1545
- "type": "string",
1546
- "placeholder": "https://api.switch-bot.com",
1547
- "description": "Allows for the override of the SwitchBot API hostname."
1548
- },
1549
- "webhookURL": {
1550
- "title": "Webhook URL",
1551
- "type": "string",
1552
- "placeholder": "http://${FQDN}:${PORT}/${PATH}"
1553
- },
1554
- "webhook": {
1555
- "title": "Enable Webhook for All Devices",
1556
- "type": "boolean",
1557
- "description": "When enabled, all devices will use webhook by default (requires webhookURL). Individual devices can override this setting.",
1558
- "condition": {
1559
- "functionBody": "return model.options && model.options.webhookURL;"
1560
- }
1561
- },
1562
- "mqttURL": {
1563
- "title": "MQTT URL",
1564
- "type": "string",
1565
- "placeholder": "192.168.7.1"
1566
- },
1567
- "mqttOptions": {
1568
- "title": "MQTT Options",
1569
- "type": "string"
1570
- },
1571
- "mqttPubOptions": {
1572
- "title": "MQTT Pub Options",
1573
- "type": "string"
1574
- },
1575
- "maxRetries": {
1576
- "title": "Max Retries for OpenAPI",
1577
- "type": "number",
1578
- "placeholder": 5
1579
- },
1580
- "delayBetweenRetries": {
1581
- "title": "Delay Between Retries for OpenAPI (In Seconds)",
1582
- "type": "number",
1583
- "placeholder": 3
1584
- },
1585
- "refreshRate": {
1586
- "title": "Refresh Rate",
1587
- "type": "number",
1588
- "placeholder": 360
1589
- },
1590
- "updateRate": {
1591
- "title": "Update Rate",
1592
- "type": "number",
1593
- "placeholder": 5
1594
- },
1595
- "pushRate": {
1596
- "title": "Push Rate",
1597
- "type": "number",
1598
- "placeholder": 1
1599
- },
1600
- "dailyApiLimit": {
1601
- "title": "Daily OpenAPI Limit",
1602
- "type": "number",
1603
- "placeholder": 10000
1604
- },
1605
- "dailyApiReserveForCommands": {
1606
- "title": "Reserve For Commands (daily)",
1607
- "type": "number",
1608
- "placeholder": 1000
1609
- },
1610
- "webhookOnlyOnReserve": {
1611
- "title": "Webhook-only When Near Limit",
1612
- "type": "boolean",
1613
- "default": false
1614
- },
1615
- "dailyApiResetLocalMidnight": {
1616
- "title": "Reset Daily Counter at Local Midnight",
1617
- "type": "boolean",
1618
- "default": false
1619
- },
1620
- "resetDailyApiCounter": {
1621
- "title": "Reset Daily API Counter",
1622
- "type": "boolean",
1623
- "description": "Set to true to reset the daily API counter to zero. This is useful for testing purposes."
1624
- },
1625
- "logging": {
1626
- "title": "Logging Setting",
1627
- "type": "string",
1628
- "default": "standard",
1629
- "oneOf": [
1630
- {
1631
- "title": "Debug Logging",
1632
- "enum": [
1633
- "debug"
1634
- ]
1
+ {
2
+ "pluginAlias": "SwitchBot",
3
+ "pluginType": "platform",
4
+ "singular": true,
5
+ "customUi": true,
6
+ "customUiPath": "./dist/homebridge-ui",
7
+ "headerDisplay": "<p align='center'><img width='100px' src='https://user-images.githubusercontent.com/9875439/102681754-ac2eb800-4189-11eb-8e17-7c47c804484b.png'></p>\n\nThe **SwitchBot** plugin allows you to control SwitchBot Devices. Use the hybrid client (BLE + OpenAPI) or only OpenAPI by supplying an Open Token.",
8
+ "footerDisplay": "Please raise any issues on our [project page](https://github.com/OpenWonderLabs/homebridge-switchbot/issues).",
9
+ "schema": {
10
+ "type": "object",
11
+ "required": [],
12
+ "properties": {
13
+ "name": {
14
+ "type": "string",
15
+ "title": "Name",
16
+ "default": "SwitchBot"
17
+ },
18
+ "openApiToken": {
19
+ "type": "string",
20
+ "title": "OpenAPI Token",
21
+ "description": "SwitchBot OpenAPI token used as a fallback when BLE isn't available. Keep this secret.",
22
+ "format": "password"
23
+ },
24
+ "openApiSecret": {
25
+ "type": "string",
26
+ "title": "OpenAPI Secret (optional)",
27
+ "description": "Optional OpenAPI secret for certain account setups.",
28
+ "format": "password"
29
+ },
30
+ "enableMatter": {
31
+ "type": "boolean",
32
+ "title": "Enable Matter Support",
33
+ "default": true,
34
+ "description": "Allow the plugin to register Matter accessories when Homebridge Matter is available."
35
+ },
36
+ "preferMatter": {
37
+ "type": "boolean",
38
+ "title": "Prefer Matter when available",
39
+ "default": true,
40
+ "description": "If enabled and Matter is available, device will be presented as Matter accessories where supported."
41
+ },
42
+ "devices": {
43
+ "type": "array",
44
+ "title": "Devices",
45
+ "description": "List of SwitchBot devices to manage. Use the UI to add devices and copy device IDs.",
46
+ "items": {
47
+ "type": "object",
48
+ "required": ["deviceId", "configDeviceType"],
49
+ "properties": {
50
+ "configDeviceName": {
51
+ "type": "string",
52
+ "title": "Name",
53
+ "description": "Friendly name for this device as shown in HomeKit/Matter."
1635
54
  },
1636
- {
1637
- "title": "No Logging",
1638
- "enum": [
1639
- "none"
1640
- ]
55
+ "deviceId": {
56
+ "type": "string",
57
+ "title": "Device ID",
58
+ "description": "The SwitchBot device identifier (MAC or SwitchBot Cloud deviceId). Use the plugin UI to copy this."
1641
59
  },
1642
- {
1643
- "title": "Standard Logging",
60
+ "configDeviceType": {
61
+ "type": "string",
62
+ "title": "Device Type",
63
+ "description": "Select the device type so the plugin can expose the correct HomeKit/Matter services and characteristics.",
1644
64
  "enum": [
1645
- "standard"
1646
- ]
65
+ "bot",
66
+ "curtain",
67
+ "fan",
68
+ "light",
69
+ "lightstrip",
70
+ "motion",
71
+ "contact",
72
+ "vacuum",
73
+ "lock",
74
+ "humidifier",
75
+ "temperature",
76
+ "relay",
77
+ "plug",
78
+ "wosweeper",
79
+ "blindtilt",
80
+ "curtain3",
81
+ "rollershade",
82
+ "meter",
83
+ "waterdetector",
84
+ "walletfinder",
85
+ "unknown"
86
+ ],
87
+ "default": "unknown"
88
+ },
89
+ "connectionPreference": {
90
+ "type": "string",
91
+ "title": "Connection Preference",
92
+ "description": "Select whether this device should prefer BLE, OpenAPI, or auto-detect (hybrid).",
93
+ "enum": ["auto", "ble", "openapi"],
94
+ "default": "auto"
95
+ },
96
+ "room": {
97
+ "type": "string",
98
+ "title": "Room",
99
+ "description": "Optional room/location metadata for the device."
1647
100
  }
1648
- ]
1649
- },
1650
- "allowConfigOnlyDevices": {
1651
- "title": "Allow Config-only Devices",
1652
- "type": "boolean",
1653
- "description": "If true, devices declared in options.devices that are not discovered by the SwitchBot OpenAPI will still be included (config-only devices). Default: false."
1654
- },
1655
- "keepStaleAccessories": {
1656
- "title": "Keep Stale Accessories",
1657
- "type": "boolean",
1658
- "description": "If true, accessories that are no longer found via the SwitchBot OpenAPI will be kept in HomeKit. Default: false."
1659
- },
1660
- "allowInvalidCharacters": {
1661
- "title": "Allow Invalid Characters",
1662
- "type": "boolean",
1663
- "description": "If true, invalid characters will be allowed in the device name."
1664
- }
1665
- },
1666
- "required": [
1667
- "logging"
1668
- ]
1669
- }
1670
- }
1671
- },
1672
- "layout": [
1673
- {
1674
- "type": "fieldset",
1675
- "title": "SwitchBot Account Info",
1676
- "expandable": true,
1677
- "expanded": false,
1678
- "items": [
1679
- "credentials.token",
1680
- "credentials.secret"
1681
- ]
1682
- },
1683
- {
1684
- "type": "fieldset",
1685
- "title": "SwitchBot Device Settings",
1686
- "expandable": true,
1687
- "expanded": false,
1688
- "items": [
1689
- {
1690
- "type": "help",
1691
- "helpvalue": "<em class='primary-text'>With SwitchBot Device Setting, you can set device specific settings based on <b style='color: var(--secondary-color);'>deviceId</b>. This will override Device Type Settings</em>"
1692
- },
1693
- {
1694
- "key": "options.devices",
1695
- "notitle": false,
1696
- "type": "tabarray",
1697
- "title": "{{ value.configDeviceName || value.deviceId || 'New SwitchBot Device' }}",
1698
- "expandable": true,
1699
- "expanded": false,
1700
- "draggable": true,
1701
- "orderable": true,
1702
- "items": [
1703
- "options.devices[].configDeviceName",
1704
- "options.devices[].deviceId",
1705
- "options.devices[].hide_device",
1706
- "options.devices[].configDeviceType",
1707
- "options.devices[].connectionType",
1708
- "options.devices[].disablePlatformBLE",
1709
- "options.devices[].scanDuration",
1710
- "options.devices[].customBLEaddress",
1711
- "options.devices[].webhook",
1712
- "options.devices[].type",
1713
- "options.devices[].mode",
1714
- "options.devices[].mapping",
1715
- "options.devices[].allowPush",
1716
- "options.devices[].doublePress",
1717
- "options.devices[].pushRatePress",
1718
- "options.devices[].hide_temperature",
1719
- "options.devices[].convertUnitTo",
1720
- "options.devices[].hide_humidity",
1721
- "options.devices[].hide_lightsensor",
1722
- "options.devices[].hide_motionsensor",
1723
- "options.devices[].hide_contactsensor",
1724
- "options.devices[].hide_leak",
1725
- "options.devices[].disable_group",
1726
- "options.devices[].disableCaching",
1727
- "options.devices[].adaptiveLightingShift",
1728
- "options.devices[].activate_latchbutton",
1729
- "options.devices[].dry",
1730
- "options.devices[].activate_dryingfilter",
1731
- "options.devices[].set_minStep",
1732
- "options.devices[].set_min",
1733
- "options.devices[].set_max",
1734
- "options.devices[].set_minlux",
1735
- "options.devices[].set_maxlux",
1736
- "options.devices[].setOpenMode",
1737
- "options.devices[].setCloseMode",
1738
- "options.devices[].silentModeSwitch",
1739
- "options.devices[].maxRetry",
1740
- "options.devices[].maxRetries",
1741
- "options.devices[].delayBetweenRetries",
1742
- "options.devices[].mqttURL",
1743
- "options.devices[].mqttOptions",
1744
- "options.devices[].mqttPubOptions",
1745
- "options.devices[].history",
1746
- "options.devices[].offline",
1747
- "options.devices[].firmware",
1748
- "options.devices[].external",
1749
- "options.devices[].logging",
1750
- {
1751
- "key": "options.devices[].refreshRate",
1752
- "description": "<em class='primary-text'>Specifies the interval, in seconds, for retrieving the latest device status from the SwitchBot API. This interval applies only to this specific device.</em>"
1753
- },
1754
- {
1755
- "key": "options.devices[].updateRate",
1756
- "description": "<em class='primary-text'>Specifies the interval, in seconds, at which this device will request updates from the SwitchBot API while the device is in motion, for Curtain(s) and Blind Tilt(s) only.</em>"
1757
- },
1758
- {
1759
- "key": "options.devices[].pushRate",
1760
- "description": "<em class='primary-text'>Specifies the interval, in seconds, between pushes to the SwitchBot API for this specific device.</em>"
1761
101
  }
1762
- ]
1763
- }
1764
- ]
1765
- },
1766
- {
1767
- "type": "fieldset",
1768
- "title": "IR Device Settings",
1769
- "expandable": true,
1770
- "expanded": false,
1771
- "items": [
1772
- {
1773
- "type": "help",
1774
- "helpvalue": "<em class='primary-text'>With IR Device Setting, you can set device specific settings based on <b style='color: var(--secondary-color);'>deviceId</b>. This will override IR Remote Type Settings</em>"
1775
- },
1776
- {
1777
- "key": "options.irdevices",
1778
- "notitle": false,
1779
- "type": "tabarray",
1780
- "title": "{{ value.configDeviceName || value.deviceId || 'New IR Device' }}",
1781
- "expandable": true,
1782
- "expanded": false,
1783
- "draggable": true,
1784
- "orderable": true,
1785
- "items": [
1786
- "options.irdevices[].configDeviceName",
1787
- "options.irdevices[].deviceId",
1788
- "options.irdevices[].hide_device",
1789
- "options.irdevices[].configRemoteType",
1790
- "options.irdevices[].connectionType",
1791
- "options.irdevices[].type",
1792
- "options.irdevices[].customize",
1793
- "options.irdevices[].customOn",
1794
- "options.irdevices[].customOff",
1795
- "options.irdevices[].commandType",
1796
- "options.irdevices[].disablePushOn",
1797
- "options.irdevices[].disablePushOff",
1798
- "options.irdevices[].disablePushDetail",
1799
- "options.irdevices[].hide_automode",
1800
- "options.irdevices[].set_max_heat",
1801
- "options.irdevices[].set_min_heat",
1802
- "options.irdevices[].set_max_cool",
1803
- "options.irdevices[].set_min_cool",
1804
- "options.irdevices[].meterType",
1805
- "options.irdevices[].meterId",
1806
- "options.irdevices[].rotation_speed",
1807
- "options.irdevices[].swing_mode",
1808
- "options.irdevices[].set_minStep",
1809
- "options.irdevices[].set_min",
1810
- "options.irdevices[].set_max",
1811
- "options.irdevices[].stateless",
1812
- "options.irdevices[].external",
1813
- "options.irdevices[].disableCaching",
1814
- "options.irdevices[].offline",
1815
- "options.irdevices[].history",
1816
- "options.irdevices[].firmware",
1817
- "options.irdevices[].logging",
1818
- "options.irdevices[].refreshRate",
1819
- "options.irdevices[].updateRate",
1820
- "options.irdevices[].pushRate"
1821
- ]
1822
- }
1823
- ]
1824
- },
1825
- {
1826
- "type": "fieldset",
1827
- "title": "Advanced Settings",
1828
- "expandable": true,
1829
- "expanded": false,
1830
- "items": [
1831
- "options.BLE",
1832
- {
1833
- "key": "options.discoverBLE",
1834
- "description": "This will scan for BLE devices and <em class='primary-text'>display</em> an Array in the logs so you can add them to the config."
1835
- },
1836
- {
1837
- "key": "options.disableLogsforBLE",
1838
- "description": "This will disable the logs coming from <em class='primary-text>node-switchbot</em> BLE ."
1839
- },
1840
- {
1841
- "key": "options.disableLogsforOpenAPI",
1842
- "description": "This will disable the logs coming from <em class='primary-text>node-switchbot</em> OpenAPI."
1843
- },
1844
- {
1845
- "key": "options.hostname",
1846
- "description": "Allows for the override of the SwitchBot API hostname."
1847
- },
1848
- {
1849
- "key": "options.webhookURL",
1850
- "description": "Allows for the override of the SwitchBot API webhook URL."
1851
- },
1852
- {
1853
- "key": "options.webhook",
1854
- "description": "When enabled, all devices will use webhook by default (requires webhookURL). Individual devices can override this setting."
1855
- },
1856
- {
1857
- "key": "options.mqttURL",
1858
- "description": "Allows for the override of the MQTT broker URL."
1859
- },
1860
- {
1861
- "key": "options.mqttOptions",
1862
- "description": "Allows for the override of the MQTT connection options."
1863
- },
1864
- {
1865
- "key": "options.mqttPubOptions",
1866
- "description": "Allows for the override of the MQTT publish options."
1867
- },
1868
- {
1869
- "key": "options.maxRetries",
1870
- "description": "Specifies the maximum number of retry attempts for OpenAPI requests."
1871
- },
1872
- {
1873
- "key": "options.delayBetweenRetries",
1874
- "description": "Specifies the delay, in seconds, between retry attempts for OpenAPI requests."
1875
- },
1876
- {
1877
- "type": "help",
1878
- "helpvalue": "<em class='primary-text'>The following settings apply to all devices unless overridden at the device level.</em>"
1879
- },
1880
- {
1881
- "key": "options.matterBatchRefreshRate",
1882
- "description": "<em class='primary-text'>Specifies the interval, in seconds, for retrieving the latest device status from the SwitchBot API when batching Matter requests.</em>"
1883
- },
1884
- {
1885
- "key": "options.matterBatchConcurrency",
1886
- "description": "<em class='primary-text'>Specifies the maximum number of Matter requests to process concurrently.</em>"
1887
- },
1888
- {
1889
- "key": "options.matterBatchEnabled",
1890
- "description": "<em class='primary-text'>If true, enables batching of Matter requests to optimize performance. Default: false.</em>"
1891
- },
1892
- {
1893
- "key": "options.matterBatchJitter",
1894
- "description": "<em class='primary-text'>Specifies the maximum random jitter, in seconds, to add to the batch processing interval to prevent synchronization issues. Default: 0.</em>"
1895
- },
1896
- {
1897
- "key": "options.refreshRate",
1898
- "description": "<em class='primary-text'>Specifies the interval, in seconds, for retrieving the latest device status from the SwitchBot API.</em>"
1899
- },
1900
- {
1901
- "key": "options.updateRate",
1902
- "description": "<em class='primary-text'>Specifies the interval, in seconds, at which devices will request updates from the SwitchBot API while in motion, for Curtain(s) and Blind Tilt(s) only.</em>"
1903
- },
1904
- {
1905
- "key": "options.pushRate",
1906
- "description": "<em class='primary-text'>Specifies the interval, in seconds, between pushes to the SwitchBot API.</em>"
1907
- },
1908
- {
1909
- "key": "options.dailyApiLimit",
1910
- "description": "Maximum OpenAPI requests per day. Default: 10000. When close to this limit, the plugin will pause background polling to avoid overage."
1911
- },
1912
- {
1913
- "key": "options.dailyApiReserveForCommands",
1914
- "description": "Requests reserved for user-initiated commands. When the remaining budget is below this, background polling/discovery pauses until reset. Default: 1000."
1915
- },
1916
- {
1917
- "key": "options.webhookOnlyOnReserve",
1918
- "description": "If true, completely stop background polling/discovery once the remaining budget hits the reserve. Webhooks and commands still work until the hard limit."
1919
- },
1920
- {
1921
- "key": "options.logging",
1922
- "description": "<em class='primary-text'>Specifies the logging level for the plugin. Default: info.</em>"
1923
- },
1924
- {
1925
- "key": "options.allowConfigOnlyDevices",
1926
- "description": "<em class='primary-text'>If true, devices declared in options.devices that are not discovered by the SwitchBot OpenAPI will still be included (config-only devices). Default: false.</em>"
1927
- },
1928
- {
1929
- "key": "options.keepStaleAccessories",
1930
- "description": "<em class='primary-text'>If true, previously-registered accessories for devices that are no longer discovered or configured will be kept on the bridge. Default: false (stale accessories are removed automatically).</em>"
1931
- },
1932
- {
1933
- "key": "options.dailyApiResetLocalMidnight",
1934
- "description": "<em class='primary-text'>If true, the daily API request counter will reset at local midnight (system timezone). If false (default), it will reset at UTC midnight.</em>"
1935
- },
1936
- {
1937
- "key": "options.resetDailyApiCounter",
1938
- "description": "<em class='primary-text'>Resets the daily API request counter to zero. This is useful for testing or if you want to manually manage your API usage.</em>"
1939
- },
1940
- {
1941
- "key": "options.allowInvalidCharacters",
1942
- "description": "<em class='primary-text'>Allows device names with characters that are normally invalid in HomeKit. Use with caution, as this may lead to unexpected behavior.</em>"
102
+ }
1943
103
  }
1944
- ]
104
+ }
1945
105
  }
1946
- ]
1947
- }
106
+ }