Skip to content

Commit 9aeeaf1

Browse files
committed
v3.4.7
## [3.4.7](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v3.4.7) (2025-01-24) ### What's Changed - Add Types for Relay Switch 1 && Relay Switch 1 PM - Housekeeping and update dependencies **Full Changelog**: v3.4.6...v3.4.7
1 parent b911482 commit 9aeeaf1

File tree

5 files changed

+40
-3
lines changed

5 files changed

+40
-3
lines changed

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,14 @@
22

33
All notable changes to this project will be documented in this file. This project uses [Semantic Versioning](https://semver.org/)
44

5+
## [3.4.7](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v3.4.7) (2025-01-24)
6+
7+
### What's Changed
8+
- Add Types for Relay Switch 1 && Relay Switch 1 PM
9+
- Housekeeping and update dependencies
10+
11+
**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v3.4.6...v3.4.7
12+
513
## [3.4.6](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v3.4.6) (2025-01-24)
614

715
### What's Changed

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "node-switchbot",
33
"type": "module",
4-
"version": "3.4.6",
4+
"version": "3.4.7",
55
"description": "The node-switchbot is a Node.js module which allows you to control your Switchbot Devices through Bluetooth (BLE).",
66
"author": "OpenWonderLabs (https://github.com/OpenWonderLabs)",
77
"license": "MIT",

src/types/devicestatus.ts

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,3 +213,17 @@ export type circulatorFanStatus = deviceStatus & {
213213
verticalOscillation: string
214214
fanSpeed: number
215215
}
216+
217+
export type relaySwitch1Status = deviceStatus & {
218+
switchStatus: 0 | 1
219+
version: string
220+
}
221+
222+
export type relaySwitch1PMStatus = deviceStatus & {
223+
switchStatus: 0 | 1
224+
voltage: number
225+
version: string
226+
power: number
227+
usedElectricity: number
228+
electricCurrent: number
229+
}

src/types/devicewebhookstatus.ts

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -266,3 +266,18 @@ export type humidifier2WebhookContext = deviceWebhookContext & {
266266
humidity: number
267267
scale: 'CELSIUS' | 'FAHRENHEIT'
268268
}
269+
270+
export type relaySwitch1Context = deviceWebhookContext & {
271+
online: boolean
272+
overTemperature: boolean
273+
switchStatus: 0 | 1
274+
version: string
275+
}
276+
277+
export type relaySwitch1PMContext = deviceWebhookContext & {
278+
online: boolean
279+
overTemperature: boolean
280+
switchStatus: 0 | 1
281+
overload: boolean
282+
version: string
283+
}

0 commit comments

Comments
 (0)