homebridge-homeassistant-things 2.2.0 → 2.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/config.schema.json +12 -1
- package/index.js +11 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -10,6 +10,14 @@ Todos los cambios relevantes de este proyecto se documentan aquí.
|
|
|
10
10
|
|
|
11
11
|
---
|
|
12
12
|
|
|
13
|
+
## [2.3.0] - 2026-04-02
|
|
14
|
+
|
|
15
|
+
### Added / Añadido
|
|
16
|
+
- **EN** Platform-level `haUrl` and `haToken` defaults — set them once at platform level and all devices inherit them. Individual devices can still override with their own values.
|
|
17
|
+
- **ES** Valores por defecto de `haUrl` y `haToken` a nivel de plataforma — se configuran una vez y todos los dispositivos los heredan. Cada dispositivo puede sobrescribirlos con sus propios valores si es necesario.
|
|
18
|
+
|
|
19
|
+
---
|
|
20
|
+
|
|
13
21
|
## [2.2.0] - 2026-04-02
|
|
14
22
|
|
|
15
23
|
### Added / Añadido
|
package/config.schema.json
CHANGED
|
@@ -10,13 +10,24 @@
|
|
|
10
10
|
"type": "string",
|
|
11
11
|
"default": "HA Things"
|
|
12
12
|
},
|
|
13
|
+
"haUrl": {
|
|
14
|
+
"title": "Default Home Assistant URL",
|
|
15
|
+
"type": "string",
|
|
16
|
+
"placeholder": "http://homeassistant.local:8123",
|
|
17
|
+
"description": "Default HA URL for all devices. Can be overridden per device."
|
|
18
|
+
},
|
|
19
|
+
"haToken": {
|
|
20
|
+
"title": "Default Long-Lived Access Token",
|
|
21
|
+
"type": "string",
|
|
22
|
+
"description": "Default HA token for all devices. Can be overridden per device."
|
|
23
|
+
},
|
|
13
24
|
"devices": {
|
|
14
25
|
"title": "Devices",
|
|
15
26
|
"type": "array",
|
|
16
27
|
"items": {
|
|
17
28
|
"title": "Device",
|
|
18
29
|
"type": "object",
|
|
19
|
-
"required": ["name", "deviceType", "
|
|
30
|
+
"required": ["name", "deviceType", "entityId"],
|
|
20
31
|
"properties": {
|
|
21
32
|
"name": {
|
|
22
33
|
"title": "Name",
|
package/index.js
CHANGED
|
@@ -44,6 +44,17 @@ class HomeAssistantThingsPlatform {
|
|
|
44
44
|
}];
|
|
45
45
|
}
|
|
46
46
|
|
|
47
|
+
// Apply platform-level defaults for haUrl and haToken
|
|
48
|
+
const defaultHaUrl = this.config.haUrl;
|
|
49
|
+
const defaultHaToken = this.config.haToken;
|
|
50
|
+
if (defaultHaUrl || defaultHaToken) {
|
|
51
|
+
devices = devices.map(d => ({
|
|
52
|
+
haUrl: defaultHaUrl,
|
|
53
|
+
haToken: defaultHaToken,
|
|
54
|
+
...d,
|
|
55
|
+
}));
|
|
56
|
+
}
|
|
57
|
+
|
|
47
58
|
const configuredUUIDs = new Set();
|
|
48
59
|
|
|
49
60
|
for (const deviceConfig of devices) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "homebridge-homeassistant-things",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.3.0",
|
|
4
4
|
"description": "Homebridge plugin to control Home Assistant devices (switches, thermostats, blinds, garage doors) as native HomeKit accessories",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"keywords": [
|