matterbridge 1.6.8-dev.9 → 1.7.1

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 (108) hide show
  1. package/CHANGELOG.md +46 -3
  2. package/README-DOCKER.md +8 -6
  3. package/README-EDGE.md +74 -0
  4. package/README-SERVICE.md +3 -3
  5. package/README.md +6 -3
  6. package/dist/cli.d.ts +25 -0
  7. package/dist/cli.d.ts.map +1 -0
  8. package/dist/cli.js +26 -0
  9. package/dist/cli.js.map +1 -0
  10. package/dist/cluster/export.d.ts +2 -0
  11. package/dist/cluster/export.d.ts.map +1 -0
  12. package/dist/cluster/export.js +2 -0
  13. package/dist/cluster/export.js.map +1 -0
  14. package/dist/defaultConfigSchema.d.ts +27 -0
  15. package/dist/defaultConfigSchema.d.ts.map +1 -0
  16. package/dist/defaultConfigSchema.js +23 -0
  17. package/dist/defaultConfigSchema.js.map +1 -0
  18. package/dist/deviceManager.d.ts +46 -0
  19. package/dist/deviceManager.d.ts.map +1 -0
  20. package/dist/deviceManager.js +26 -1
  21. package/dist/deviceManager.js.map +1 -0
  22. package/dist/index.d.ts +40 -0
  23. package/dist/index.d.ts.map +1 -0
  24. package/dist/index.js +30 -0
  25. package/dist/index.js.map +1 -0
  26. package/dist/logger/export.d.ts +2 -0
  27. package/dist/logger/export.d.ts.map +1 -0
  28. package/dist/logger/export.js +1 -0
  29. package/dist/logger/export.js.map +1 -0
  30. package/dist/matter/export.d.ts +11 -0
  31. package/dist/matter/export.d.ts.map +1 -0
  32. package/dist/matter/export.js +4 -0
  33. package/dist/matter/export.js.map +1 -0
  34. package/dist/matterbridge.d.ts +483 -0
  35. package/dist/matterbridge.d.ts.map +1 -0
  36. package/dist/matterbridge.js +818 -110
  37. package/dist/matterbridge.js.map +1 -0
  38. package/dist/matterbridgeAccessoryPlatform.d.ts +39 -0
  39. package/dist/matterbridgeAccessoryPlatform.d.ts.map +1 -0
  40. package/dist/matterbridgeAccessoryPlatform.js +33 -0
  41. package/dist/matterbridgeAccessoryPlatform.js.map +1 -0
  42. package/dist/matterbridgeBehaviors.d.ts +942 -0
  43. package/dist/matterbridgeBehaviors.d.ts.map +1 -0
  44. package/dist/matterbridgeBehaviors.js +29 -1
  45. package/dist/matterbridgeBehaviors.js.map +1 -0
  46. package/dist/matterbridgeDevice.d.ts +7077 -0
  47. package/dist/matterbridgeDevice.d.ts.map +1 -0
  48. package/dist/matterbridgeDevice.js +996 -9
  49. package/dist/matterbridgeDevice.js.map +1 -0
  50. package/dist/matterbridgeDeviceTypes.d.ts +109 -0
  51. package/dist/matterbridgeDeviceTypes.d.ts.map +1 -0
  52. package/dist/matterbridgeDeviceTypes.js +82 -11
  53. package/dist/matterbridgeDeviceTypes.js.map +1 -0
  54. package/dist/matterbridgeDynamicPlatform.d.ts +39 -0
  55. package/dist/matterbridgeDynamicPlatform.d.ts.map +1 -0
  56. package/dist/matterbridgeDynamicPlatform.js +33 -0
  57. package/dist/matterbridgeDynamicPlatform.js.map +1 -0
  58. package/dist/matterbridgeEdge.d.ts +91 -0
  59. package/dist/matterbridgeEdge.d.ts.map +1 -0
  60. package/dist/matterbridgeEdge.js +558 -11
  61. package/dist/matterbridgeEdge.js.map +1 -0
  62. package/dist/matterbridgeEndpoint.d.ts +10151 -0
  63. package/dist/matterbridgeEndpoint.d.ts.map +1 -0
  64. package/dist/matterbridgeEndpoint.js +1120 -11
  65. package/dist/matterbridgeEndpoint.js.map +1 -0
  66. package/dist/matterbridgePlatform.d.ts +145 -0
  67. package/dist/matterbridgePlatform.d.ts.map +1 -0
  68. package/dist/matterbridgePlatform.js +127 -4
  69. package/dist/matterbridgePlatform.js.map +1 -0
  70. package/dist/matterbridgeTypes.d.ts +172 -0
  71. package/dist/matterbridgeTypes.d.ts.map +1 -0
  72. package/dist/matterbridgeTypes.js +24 -0
  73. package/dist/matterbridgeTypes.js.map +1 -0
  74. package/dist/matterbridgeWebsocket.d.ts +49 -0
  75. package/dist/matterbridgeWebsocket.d.ts.map +1 -0
  76. package/dist/matterbridgeWebsocket.js +182 -17
  77. package/dist/matterbridgeWebsocket.js.map +1 -0
  78. package/dist/pluginManager.d.ts +238 -0
  79. package/dist/pluginManager.d.ts.map +1 -0
  80. package/dist/pluginManager.js +238 -3
  81. package/dist/pluginManager.js.map +1 -0
  82. package/dist/storage/export.d.ts +2 -0
  83. package/dist/storage/export.d.ts.map +1 -0
  84. package/dist/storage/export.js +1 -0
  85. package/dist/storage/export.js.map +1 -0
  86. package/dist/utils/colorUtils.d.ts +61 -0
  87. package/dist/utils/colorUtils.d.ts.map +1 -0
  88. package/dist/utils/colorUtils.js +205 -2
  89. package/dist/utils/colorUtils.js.map +1 -0
  90. package/dist/utils/export.d.ts +3 -0
  91. package/dist/utils/export.d.ts.map +1 -0
  92. package/dist/utils/export.js +1 -0
  93. package/dist/utils/export.js.map +1 -0
  94. package/dist/utils/utils.d.ts +221 -0
  95. package/dist/utils/utils.d.ts.map +1 -0
  96. package/dist/utils/utils.js +252 -7
  97. package/dist/utils/utils.js.map +1 -0
  98. package/frontend/build/asset-manifest.json +6 -6
  99. package/frontend/build/index.html +1 -1
  100. package/frontend/build/static/css/{main.823e08b6.css → main.b1a621ee.css} +2 -2
  101. package/frontend/build/static/css/main.b1a621ee.css.map +1 -0
  102. package/frontend/build/static/js/{main.4dd7e165.js → main.ecd94d17.js} +15 -15
  103. package/frontend/build/static/js/main.ecd94d17.js.map +1 -0
  104. package/npm-shrinkwrap.json +33 -20
  105. package/package.json +2 -1
  106. package/frontend/build/static/css/main.823e08b6.css.map +0 -1
  107. package/frontend/build/static/js/main.4dd7e165.js.map +0 -1
  108. /package/frontend/build/static/js/{main.4dd7e165.js.LICENSE.txt → main.ecd94d17.js.LICENSE.txt} +0 -0
package/CHANGELOG.md CHANGED
@@ -13,14 +13,55 @@ It is also available the official Matterbridge Home Assistant plugin https://git
13
13
 
14
14
  Tamer (https://github.com/tammeryousef1006) has created the Matterbridge Discord group: https://discord.gg/QX58CDe6hd.
15
15
 
16
- ## [1.6.8-dev.9] - 2024-12-21
16
+ ### Breaking Changes
17
+
18
+ Matterbridge edge is now released. The default mode is still the normal mode to allow the storage conversion. See https://github.com/Luligu/matterbridge/blob/dev/README-EDGE.md to manually switch to edge mode after the conversion is done.
19
+
20
+ The frontend has a new dark and light mode. The dark mode is now the default mode.
21
+ It is possible to change the mode (Classic, Dark or Light) in Settings, Matterbridge settings.
22
+
23
+ ## [1.7.1] - 2025-01-07
17
24
 
18
25
  ### Added
19
26
 
20
- - [storage]: Added conversion from old matter storage to the new api format with fabrics, resumptionRecords, network, commissioning, operationalCredentials, acl and parts number. The conversion is triggered every time you shutdown or restart matterbridge till the new storage has been used with matterbridge edge.
21
- - [storage]: Added conversion for child endpoint numbers.
27
+ - [platform]: Added selectDevice to get the device names from a list in the config editor.
28
+ - [websocket]: Added api /api/select.
29
+ - [frontend]: Added configUrl to Devices page.
30
+ - [frontend]: Added config button to Devices page.
31
+ - [frontend]: Added id and deviceTypes to Devices page.
32
+
33
+ ### Changed
34
+
35
+ - [websocket]: Added params to /api/clusters.
36
+ - [frontend]: Frontend v.2.3.3
37
+
38
+ ### Fixed
39
+
40
+ - [frontend]: Fixed WebSocketProvider online.
41
+
42
+ <a href="https://www.buymeacoffee.com/luligugithub">
43
+ <img src="./yellow-button.png" alt="Buy me a coffee" width="120">
44
+ </a>
45
+
46
+ ## [1.7.0] - 2025-01-04
47
+
48
+ ### Added
49
+
50
+ - [edge]: Added guide https://github.com/Luligu/matterbridge/blob/dev/README-EDGE.md.
51
+ - [storage]: Added conversion from old matter storage to the new api format with fabrics, resumptionRecords, network, commissioning, operationalCredentials, acl and parts number. The conversion is triggered every time you shutdown or restart matterbridge till the new storage has been used with matterbridge edge.
52
+ - [storage]: Added conversion for child endpoint numbers.
53
+ - [storage]: Added conversion for childbridge mode.
22
54
  - [package]: Update README.md and README-SERVICE.md to include instructions for using SSL on port 443.
23
55
  - [platform]: Added checkEndpointNumbers() to detect endpoint numbers changes.
56
+ - [frontend]: Frontend v.2.3.0
57
+ - [frontend]: Added dark and light mode to the frontend. Dark mode is now the default mode. It is possible to change the mode in Settings, Matterbridge settings.
58
+ - [frontend]: Custom rfjsreact-jsonschema-form for the config editor.
59
+ - [frontend]: Added columns configuration to Devices.
60
+ - [frontend]: Added clear logs button in Logs.
61
+ - [unregister]: Added unregister for Matterbridge edge.
62
+ - [reset]: Added reset for Matterbridge edge.
63
+ - [factoryreset]: Added factoryreset for Matterbridge edge.
64
+ - [websocket]: Added /api/clusters and removed all fetch calls from frontend.
24
65
 
25
66
  ### Changed
26
67
 
@@ -29,6 +70,8 @@ Tamer (https://github.com/tammeryousef1006) has created the Matterbridge Discord
29
70
 
30
71
  ### Fixed
31
72
 
73
+ - [frontend]: Fixed device/cluster api that was not working in Ingress.
74
+
32
75
  <a href="https://www.buymeacoffee.com/luligugithub">
33
76
  <img src="./yellow-button.png" alt="Buy me a coffee" width="120">
34
77
  </a>
package/README-DOCKER.md CHANGED
@@ -40,12 +40,14 @@ sudo groupadd docker
40
40
  sudo usermod -aG docker $USER
41
41
  ```
42
42
 
43
+ After adding your user to the docker group, you need to log out and log back in for the changes to take effect. This ensures that your current session recognizes the group membership change.
44
+
43
45
  ### Run the Docker container and start it
44
46
 
45
47
  The container must have full access to the host network (needed for mdns).
46
48
 
47
49
  ```
48
- docker run --name matterbridge \
50
+ sudo docker run --name matterbridge \
49
51
  -v ${HOME}/Matterbridge:/root/Matterbridge \
50
52
  -v ${HOME}/.matterbridge:/root/.matterbridge \
51
53
  --network host --restart always -d luligu/matterbridge:latest
@@ -61,12 +63,12 @@ The docker-compose.yml file is available in the docker directory of the package
61
63
  services:
62
64
  matterbridge:
63
65
  container_name: matterbridge
64
- image: luligu/matterbridge:latest # Matterbridge image with the latest tag
65
- network_mode: host # Ensures the Matter mdns works
66
- restart: always # Ensures the container always restarts automatically
66
+ image: luligu/matterbridge:latest # Matterbridge image with the latest tag
67
+ network_mode: host # Ensures the Matter mdns works
68
+ restart: always # Ensures the container always restarts automatically
67
69
  volumes:
68
- - "${HOME}/Matterbridge:/root/Matterbridge" # Mounts the Matterbridge plugin directory
69
- - "${HOME}/.matterbridge:/root/.matterbridge" # Mounts the Matterbridge storage directory
70
+ - "${HOME}/Matterbridge:/root/Matterbridge" # Mounts the Matterbridge plugin directory
71
+ - "${HOME}/.matterbridge:/root/.matterbridge" # Mounts the Matterbridge storage directory
70
72
  ```
71
73
 
72
74
  copy it in the home directory or edit the existing one to add the matterbridge service.
package/README-EDGE.md ADDED
@@ -0,0 +1,74 @@
1
+ # <img src="https://github.com/Luligu/matterbridge/blob/main/frontend/public/matterbridge%2064x64.png" alt="Matterbridge Logo" width="64px" height="64px">&nbsp;&nbsp;&nbsp;Matterbridge edge
2
+
3
+ Matterbridge Edge is the version of Matterbridge running with the new Matter.js API.
4
+
5
+ After months of work, the migration of Matterbridge from the old API to the new API is now complete. This includes the conversion of the entire old storage format to the new API storage format, encompassing fabrics, resumption records, network, commissioning, operational credentials, ACL, and part numbers. The conversion doesn't convert the persisted attributes, so at restart for a while it is possible to see wrong states on the controllers.
6
+
7
+ A special thanks goes to Apollon for answering my countless questions and helping to resolve the many small issues that arose during this process.
8
+
9
+ I also want to express my gratitude to Tamer, who continues to test everything daily to ensure we reach a level of confidence needed to release the update with the latest tag.
10
+
11
+ ## Storage conversion
12
+
13
+ Starting from version 1.7.0 (1.6.8-dev.11 before it is published as 1.7.0 with tag latest), the conversion process is automatic and is triggered each time you shut down, restart, or update Matterbridge using the frontend.
14
+
15
+ A message is displayed to inform the user when the conversion is complete.
16
+
17
+ Once the user run Matterbridge in Edge mode for the first time, the conversion will no longer be triggered.
18
+
19
+ The conversion only creates a new storage directory in the new format. It does not modify the old storage in any way, so there is no risk in trying Edge mode before its official release. You can also revert to normal mode by simply removing the -edge parameter. After the conversion is complete, the two storages will be identical. However, once you start using Edge mode, any changes made to one storage will not be reflected in the other. Therefore, it is recommended to let the conversion complete, switch to Edge mode, and continue using it exclusively.
20
+ There is no conversion back to the old storage.
21
+
22
+ ## When it will be released
23
+
24
+ Matterbridge Edge will be officially released as version 2.0.0, as it represents a major update.
25
+
26
+ ## How to run matterbridge in edge mode
27
+
28
+ To start Matterbridge in Edge mode before its official release, you need to add the -edge parameter to the command line or Docker command.
29
+
30
+ ### When you run matterbridge from a terminal
31
+
32
+ ```
33
+ matterbridge -edge
34
+ ```
35
+
36
+ ### When you run matterbridge with systemctl
37
+
38
+ Modify your /etc/systemd/system/matterbridge.service
39
+
40
+ ```
41
+ ExecStart=matterbridge -service -edge
42
+ ```
43
+
44
+ Then run:
45
+
46
+ ```
47
+ sudo systemctl daemon-reload
48
+ sudo systemctl restart matterbridge
49
+ ```
50
+
51
+ ### When you run matterbridge with docker
52
+
53
+ ```
54
+ sudo docker run --name matterbridge \
55
+ -v ${HOME}/Matterbridge:/root/Matterbridge \
56
+ -v ${HOME}/.matterbridge:/root/.matterbridge \
57
+ --network host --restart always -d luligu/matterbridge:latest \
58
+ matterbridge -docker -edge
59
+ ```
60
+
61
+ ### When you run matterbridge with docker compose
62
+
63
+ ```
64
+ services:
65
+ matterbridge:
66
+ container_name: matterbridge
67
+ image: luligu/matterbridge:latest # Matterbridge image with the latest tag
68
+ network_mode: host # Ensures the Matter mdns works
69
+ restart: always # Ensures the container always restarts automatically
70
+ volumes:
71
+ - "${HOME}/Matterbridge:/root/Matterbridge" # Mounts the Matterbridge plugin directory
72
+ - "${HOME}/.matterbridge:/root/.matterbridge" # Mounts the Matterbridge storage directory
73
+ command: [ "matterbridge", "-docker", "-edge" ] # Override the image command adding -edge
74
+ ```
package/README-SERVICE.md CHANGED
@@ -49,14 +49,14 @@ After=network-online.target
49
49
  [Service]
50
50
  Type=simple
51
51
  ExecStart=matterbridge -service
52
- WorkingDirectory=/home/<USER>/Matterbridge # Replace <USER> with your system username
52
+ WorkingDirectory=/home/<USER>/Matterbridge
53
53
  StandardOutput=inherit
54
54
  StandardError=inherit
55
55
  Restart=always
56
56
  RestartSec=10s
57
57
  TimeoutStopSec=30s
58
- User=<USER> # Replace <USER> with your system username
59
- Group=<USER> # Replace <USER> with your system username
58
+ User=<USER>
59
+ Group=<USER>
60
60
 
61
61
  [Install]
62
62
  WantedBy=multi-user.target
package/README.md CHANGED
@@ -179,15 +179,18 @@ Features:
179
179
  - Shelly wifi battery-powered devices with sleep_mode are supported.
180
180
  - Shelly BLU devices are supported through local devices configured as ble gateway.
181
181
  - Discovered shellies are stored in local storage for quick loading on startup.
182
- - The components exposed are Light (with brightness and RGB color), Switch, Relay, Roller, Cover, PowerMeter, Temperature, Humidity and Input.
183
- - All components expose the electrical measurements with the EveHistory cluster (displayed on HA), waiting for the controllers to upgrade to the Matter 1.3 specs.
182
+ - The components exposed are Light (with brightness and RGB color), Switch, Relay, Roller, Cover, PowerMeter, Temperature, Humidity, Illuminance, Thermostat, Button and Input.
183
+ - PowerMeters expose the electrical measurements with the electricalSensor device type (suppoerted by Home Assistant and partially by SmartThings), waiting for the controllers to upgrade to the Matter 1.3 specs.
184
184
  - Shellies are controlled locally, eliminating the need for cloud or MQTT (which can both be disabled).
185
- - Shelly Gen 1 devices are controlled using the CoIoT protocol (see the note below).
185
+ - Shelly Gen 1 devices are controlled using the CoIoT protocol.
186
186
  - Shelly Gen 2 and Gen 3 devices are controlled using WebSocket.
187
187
  - The Matter device takes the name configured in the Shelly device's web page.
188
+ - Each device can be blacklisted or whitelisted using its name, id or mac address.
189
+ - Device components can be blacklisted globally or on a per-device basis.
188
190
  - If the device has a firmware update available, a message is displayed.
189
191
  - If the device's CoIoT protocol is not correctly configured, a message is displayed.
190
192
  - If the device cover/roller component is not calibrated, a message is displayed.
193
+ - If a device changes its ip address on the network, a message is displayed and the new address is stored.
191
194
  - A 10-minute timer checks if the device has reported within that time frame, and fetch un update.
192
195
 
193
196
  ### Zigbee2MQTT
package/dist/cli.d.ts ADDED
@@ -0,0 +1,25 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * This file contains the CLI entry point of Matterbridge.
4
+ *
5
+ * @file cli.ts
6
+ * @author Luca Liguori
7
+ * @date 2023-12-29
8
+ * @version 1.0.11
9
+ *
10
+ * Copyright 2023, 2024, 2025 Luca Liguori.
11
+ *
12
+ * Licensed under the Apache License, Version 2.0 (the "License");
13
+ * you may not use this file except in compliance with the License.
14
+ * You may obtain a copy of the License at
15
+ *
16
+ * http://www.apache.org/licenses/LICENSE-2.0
17
+ *
18
+ * Unless required by applicable law or agreed to in writing, software
19
+ * distributed under the License is distributed on an "AS IS" BASIS,
20
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
21
+ * See the License for the specific language governing permissions and
22
+ * limitations under the License. *
23
+ */
24
+ export {};
25
+ //# sourceMappingURL=cli.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AACA;;;;;;;;;;;;;;;;;;;;;GAqBG"}
package/dist/cli.js CHANGED
@@ -1,4 +1,27 @@
1
1
  #!/usr/bin/env node
2
+ /**
3
+ * This file contains the CLI entry point of Matterbridge.
4
+ *
5
+ * @file cli.ts
6
+ * @author Luca Liguori
7
+ * @date 2023-12-29
8
+ * @version 1.0.11
9
+ *
10
+ * Copyright 2023, 2024, 2025 Luca Liguori.
11
+ *
12
+ * Licensed under the Apache License, Version 2.0 (the "License");
13
+ * you may not use this file except in compliance with the License.
14
+ * You may obtain a copy of the License at
15
+ *
16
+ * http://www.apache.org/licenses/LICENSE-2.0
17
+ *
18
+ * Unless required by applicable law or agreed to in writing, software
19
+ * distributed under the License is distributed on an "AS IS" BASIS,
20
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
21
+ * See the License for the specific language governing permissions and
22
+ * limitations under the License. *
23
+ */
24
+ /* eslint-disable no-console */
2
25
  import { Matterbridge } from './matterbridge.js';
3
26
  import { MatterbridgeEdge } from './matterbridgeEdge.js';
4
27
  let instance;
@@ -41,6 +64,7 @@ async function restart() {
41
64
  async function update() {
42
65
  if (process.argv.includes('-debug'))
43
66
  console.log(cli + 'CLI: received update event, updating...' + rs);
67
+ // TODO: Implement update logic outside of matterbridge
44
68
  if (process.argv.includes('-edge'))
45
69
  instance = await MatterbridgeEdge.loadInstance();
46
70
  else
@@ -48,6 +72,8 @@ async function update() {
48
72
  registerHandlers();
49
73
  }
50
74
  process.title = 'matterbridge';
75
+ // Run the main function
51
76
  main().catch((error) => {
52
77
  console.error(er + `CLI: Matterbridge.loadInstance() failed with error: ${error}` + rs);
53
78
  });
79
+ //# sourceMappingURL=cli.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AACA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,+BAA+B;AAC/B,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAEzD,IAAI,QAAqD,CAAC;AAC1D,MAAM,GAAG,GAAG,YAAY,CAAC;AACzB,MAAM,EAAE,GAAG,gBAAgB,CAAC;AAC5B,MAAM,EAAE,GAAG,cAAc,CAAC;AAE1B,KAAK,UAAU,IAAI;IACjB,IAAI,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC;QAAE,OAAO,CAAC,GAAG,CAAC,GAAG,GAAG,QAAQ,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,kBAAkB,CAAC,CAAC,CAAC,cAAc,wBAAwB,GAAG,EAAE,CAAC,CAAC;IAClK,IAAI,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC;QAAE,QAAQ,GAAG,MAAM,gBAAgB,CAAC,YAAY,CAAC,IAAI,CAAC,CAAC;;QACpF,QAAQ,GAAG,MAAM,YAAY,CAAC,YAAY,CAAC,IAAI,CAAC,CAAC;IACtD,gBAAgB,EAAE,CAAC;IACnB,IAA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AC;AAED,KAAK,UAAU,MAAM;IACnB,IAAI,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC;QAAE,OAAO,CAAC,GAAG,CAAC,GAAG,GAAG,yCAAyC,GAAG,EAAE,CAAC,CAAC;IACvG,uDAAuD;IACvD,IAAI,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC;QAAE,QAAQ,GAAG,MAAM,gBAAgB,CAAC,YAAY,EAAE,CAAC;;QAChF,QAAQ,GAAG,MAAM,YAAY,CAAC,YAAY,CAAC,IAAI,CAAC,CAAC;IACtD,gBAAgB,EAAE,CAAC;AACrB,CAAC;AAED,OAAO,CAAC,KAAK,GAAG,cAAc,CAAC;AAE/B,wBAAwB;AACxB,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,KAAK,EAAE,EAAE;IACrB,OAAO,CAAC,KAAK,CAAC,EAAE,GAAG,uDAAuD,KAAK,EAAE,GAAG,EAAE,CAAC,CAAC;AAC1F,CAAC,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=export.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"export.d.ts","sourceRoot":"","sources":["../../src/cluster/export.ts"],"names":[],"mappings":""}
@@ -1 +1,3 @@
1
1
  export {};
2
+ // Nothing to export right now
3
+ //# sourceMappingURL=export.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"export.js","sourceRoot":"","sources":["../../src/cluster/export.ts"],"names":[],"mappings":";AAAA,8BAA8B"}
@@ -0,0 +1,27 @@
1
+ /**
2
+ * This file contains the default config for the plugins.
3
+ *
4
+ * @file defaultConfigSchema.ts
5
+ * @author Luca Liguori
6
+ * @date 2024-05-07
7
+ * @version 1.0.1
8
+ *
9
+ * Copyright 2024, 2025, 2026 Luca Liguori.
10
+ *
11
+ * Licensed under the Apache License, Version 2.0 (the "License");
12
+ * you may not use this file except in compliance with the License.
13
+ * You may obtain a copy of the License at
14
+ *
15
+ * http://www.apache.org/licenses/LICENSE-2.0
16
+ *
17
+ * Unless required by applicable law or agreed to in writing, software
18
+ * distributed under the License is distributed on an "AS IS" BASIS,
19
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20
+ * See the License for the specific language governing permissions and
21
+ * limitations under the License. *
22
+ */
23
+ import { PlatformConfig } from './matterbridgePlatform.js';
24
+ export declare const zigbee2mqtt_config: PlatformConfig;
25
+ export declare const somfytahoma_config: PlatformConfig;
26
+ export declare const shelly_config: PlatformConfig;
27
+ //# sourceMappingURL=defaultConfigSchema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"defaultConfigSchema.d.ts","sourceRoot":"","sources":["../src/defaultConfigSchema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAE3D,eAAO,MAAM,kBAAkB,EAAE,cAiBhC,CAAC;AAEF,eAAO,MAAM,kBAAkB,EAAE,cAWhC,CAAC;AAEF,eAAO,MAAM,aAAa,EAAE,cAkC3B,CAAC"}
@@ -1,3 +1,25 @@
1
+ /**
2
+ * This file contains the default config for the plugins.
3
+ *
4
+ * @file defaultConfigSchema.ts
5
+ * @author Luca Liguori
6
+ * @date 2024-05-07
7
+ * @version 1.0.1
8
+ *
9
+ * Copyright 2024, 2025, 2026 Luca Liguori.
10
+ *
11
+ * Licensed under the Apache License, Version 2.0 (the "License");
12
+ * you may not use this file except in compliance with the License.
13
+ * You may obtain a copy of the License at
14
+ *
15
+ * http://www.apache.org/licenses/LICENSE-2.0
16
+ *
17
+ * Unless required by applicable law or agreed to in writing, software
18
+ * distributed under the License is distributed on an "AS IS" BASIS,
19
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20
+ * See the License for the specific language governing permissions and
21
+ * limitations under the License. *
22
+ */
1
23
  export const zigbee2mqtt_config = {
2
24
  name: 'matterbridge-zigbee2mqtt',
3
25
  type: 'DynamicPlatform',
@@ -63,3 +85,4 @@ export const shelly_config = {
63
85
  debugWs: false,
64
86
  unregisterOnShutdown: false,
65
87
  };
88
+ //# sourceMappingURL=defaultConfigSchema.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"defaultConfigSchema.js","sourceRoot":"","sources":["../src/defaultConfigSchema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAIH,MAAM,CAAC,MAAM,kBAAkB,GAAmB;IAChD,IAAI,EAAE,0BAA0B;IAChC,IAAI,EAAE,iBAAiB;IACvB,IAAI,EAAE,WAAW;IACjB,QAAQ,EAAE,EAAE;IACZ,QAAQ,EAAE,EAAE;IACZ,IAAI,EAAE,IAAI;IACV,KAAK,EAAE,aAAa;IACpB,SAAS,EAAE,EAAE;IACb,SAAS,EAAE,EAAE;IACb,UAAU,EAAE,EAAE;IACd,SAAS,EAAE,EAAE;IACb,UAAU,EAAE,EAAE;IACd,gBAAgB,EAAE,EAAE;IACpB,sBAAsB,EAAE,EAAE;IAC1B,KAAK,EAAE,KAAK;IACZ,oBAAoB,EAAE,KAAK;CAC5B,CAAC;AAEF,MAAM,CAAC,MAAM,kBAAkB,GAAmB;IAChD,IAAI,EAAE,2BAA2B;IACjC,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE,EAAE;IACZ,QAAQ,EAAE,EAAE;IACZ,OAAO,EAAE,cAAc;IACvB,SAAS,EAAE,EAAE;IACb,SAAS,EAAE,EAAE;IACb,gBAAgB,EAAE,EAAE;IACpB,KAAK,EAAE,KAAK;IACZ,oBAAoB,EAAE,KAAK;CAC5B,CAAC;AAEF,MAAM,CAAC,MAAM,aAAa,GAAmB;IAC3C,IAAI,EAAE,qBAAqB;IAC3B,IAAI,EAAE,iBAAiB;IACvB,QAAQ,EAAE,EAAE;IACZ,QAAQ,EAAE,EAAE;IACZ,YAAY,EAAE,QAAQ;IACtB,UAAU,EAAE,EAAE;IACd,SAAS,EAAE,EAAE;IACb,UAAU,EAAE,EAAE;IACd,WAAW,EAAE,WAAW;IACxB,gBAAgB,EAAE,EAAE;IACpB,kBAAkB,EAAE,EAAE;IACtB,iBAAiB,EAAE,EAAE;IACrB,gBAAgB,EAAE,WAAW;IAC7B,cAAc,EAAE,EAAE;IAClB,gBAAgB,EAAE,UAAU;IAC5B,SAAS,EAAE,EAAE;IACb,SAAS,EAAE,EAAE;IACb,eAAe,EAAE,EAAE;IACnB,qBAAqB,EAAE,EAAE;IACzB,WAAW,EAAE,EAAE;IACf,QAAQ,EAAE,EAAE;IACZ,kBAAkB,EAAE,IAAI;IACxB,qBAAqB,EAAE,IAAI;IAC3B,oBAAoB,EAAE,KAAK;IAC3B,oBAAoB,EAAE,KAAK;IAC3B,iBAAiB,EAAE,IAAI;IACvB,aAAa,EAAE,CAAC;IAChB,OAAO,EAAE,EAAE;IACX,KAAK,EAAE,KAAK;IACZ,SAAS,EAAE,KAAK;IAChB,SAAS,EAAE,KAAK;IAChB,OAAO,EAAE,KAAK;IACd,oBAAoB,EAAE,KAAK;CAC5B,CAAC"}
@@ -0,0 +1,46 @@
1
+ /**
2
+ * This file contains the DeviceManager class.
3
+ *
4
+ * @file devices.ts
5
+ * @author Luca Liguori
6
+ * @date 2024-07-26
7
+ * @version 1.0.8
8
+ *
9
+ * Copyright 2024, 2025, 2026 Luca Liguori.
10
+ *
11
+ * Licensed under the Apache License, Version 2.0 (the "License");
12
+ * you may not use this file except in compliance with the License.
13
+ * You may obtain a copy of the License at
14
+ *
15
+ * http://www.apache.org/licenses/LICENSE-2.0
16
+ *
17
+ * Unless required by applicable law or agreed to in writing, software
18
+ * distributed under the License is distributed on an "AS IS" BASIS,
19
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20
+ * See the License for the specific language governing permissions and
21
+ * limitations under the License. *
22
+ */
23
+ import { LogLevel } from 'node-ansi-logger';
24
+ import { NodeStorage } from 'node-persist-manager';
25
+ import { Matterbridge } from './matterbridge.js';
26
+ import { MatterbridgeDevice } from './matterbridgeDevice.js';
27
+ export declare class DeviceManager {
28
+ private readonly _devices;
29
+ private readonly matterbridge;
30
+ private readonly nodeContext;
31
+ private readonly log;
32
+ constructor(matterbridge: Matterbridge, nodeContext: NodeStorage);
33
+ get length(): number;
34
+ get size(): number;
35
+ has(uniqueId: string): boolean;
36
+ get(uniqueId: string): MatterbridgeDevice | undefined;
37
+ set(device: MatterbridgeDevice): MatterbridgeDevice;
38
+ remove(device: MatterbridgeDevice): boolean;
39
+ clear(): void;
40
+ array(): MatterbridgeDevice[];
41
+ [Symbol.iterator](): MapIterator<MatterbridgeDevice>;
42
+ forEach(callback: (device: MatterbridgeDevice) => Promise<void>): Promise<void>;
43
+ get logLevel(): LogLevel;
44
+ set logLevel(logLevel: LogLevel);
45
+ }
46
+ //# sourceMappingURL=deviceManager.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"deviceManager.d.ts","sourceRoot":"","sources":["../src/deviceManager.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAGH,OAAO,EAAwB,QAAQ,EAAmB,MAAM,kBAAkB,CAAC;AACnF,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAGnD,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACjD,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAG7D,qBAAa,aAAa;IACxB,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAyC;IAClE,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAe;IAC5C,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAc;IAC1C,OAAO,CAAC,QAAQ,CAAC,GAAG,CAAa;gBAErB,YAAY,EAAE,YAAY,EAAE,WAAW,EAAE,WAAW;IAOhE,IAAI,MAAM,IAAI,MAAM,CAEnB;IAED,IAAI,IAAI,IAAI,MAAM,CAEjB;IAED,GAAG,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO;IAI9B,GAAG,CAAC,QAAQ,EAAE,MAAM,GAAG,kBAAkB,GAAG,SAAS;IAIrD,GAAG,CAAC,MAAM,EAAE,kBAAkB,GAAG,kBAAkB;IAOnD,MAAM,CAAC,MAAM,EAAE,kBAAkB,GAAG,OAAO;IAM3C,KAAK,IAAI,IAAI;IAIb,KAAK,IAAI,kBAAkB,EAAE;IAI7B,CAAC,MAAM,CAAC,QAAQ,CAAC;IAIX,OAAO,CAAC,QAAQ,EAAE,CAAC,MAAM,EAAE,kBAAkB,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC;IAYrF,IAAI,QAAQ,IAAI,QAAQ,CAEvB;IAED,IAAI,QAAQ,CAAC,QAAQ,EAAE,QAAQ,EAE9B;CAgCF"}
@@ -1,3 +1,26 @@
1
+ /**
2
+ * This file contains the DeviceManager class.
3
+ *
4
+ * @file devices.ts
5
+ * @author Luca Liguori
6
+ * @date 2024-07-26
7
+ * @version 1.0.8
8
+ *
9
+ * Copyright 2024, 2025, 2026 Luca Liguori.
10
+ *
11
+ * Licensed under the Apache License, Version 2.0 (the "License");
12
+ * you may not use this file except in compliance with the License.
13
+ * You may obtain a copy of the License at
14
+ *
15
+ * http://www.apache.org/licenses/LICENSE-2.0
16
+ *
17
+ * Unless required by applicable law or agreed to in writing, software
18
+ * distributed under the License is distributed on an "AS IS" BASIS,
19
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20
+ * See the License for the specific language governing permissions and
21
+ * limitations under the License. *
22
+ */
23
+ // NodeStorage and AnsiLogger modules
1
24
  import { AnsiLogger, BLUE, er } from 'node-ansi-logger';
2
25
  import { dev } from './matterbridgeTypes.js';
3
26
  export class DeviceManager {
@@ -8,7 +31,7 @@ export class DeviceManager {
8
31
  constructor(matterbridge, nodeContext) {
9
32
  this.matterbridge = matterbridge;
10
33
  this.nodeContext = nodeContext;
11
- this.log = new AnsiLogger({ logName: 'DeviceManager', logTimestampFormat: 4, logLevel: matterbridge.log.logLevel });
34
+ this.log = new AnsiLogger({ logName: 'DeviceManager', logTimestampFormat: 4 /* TimestampFormat.TIME_MILLIS */, logLevel: matterbridge.log.logLevel });
12
35
  this.log.debug('Matterbridge device manager starting...');
13
36
  }
14
37
  get length() {
@@ -54,6 +77,7 @@ export class DeviceManager {
54
77
  }
55
78
  catch (error) {
56
79
  this.log.error(`Error processing forEach device ${dev}${device.deviceName}${er} serialNumber ${BLUE}${device.serialNumber}${er} uniqueId: ${BLUE}${device.uniqueId}${er}:`, error);
80
+ // throw error;
57
81
  }
58
82
  });
59
83
  await Promise.all(tasks);
@@ -65,3 +89,4 @@ export class DeviceManager {
65
89
  this.log.logLevel = logLevel;
66
90
  }
67
91
  }
92
+ //# sourceMappingURL=deviceManager.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"deviceManager.js","sourceRoot":"","sources":["../src/deviceManager.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,qCAAqC;AACrC,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,EAAE,EAA6B,MAAM,kBAAkB,CAAC;AAMnF,OAAO,EAAE,GAAG,EAAE,MAAM,wBAAwB,CAAC;AAE7C,MAAM,OAAO,aAAa;IACP,QAAQ,GAAG,IAAI,GAAG,EAA8B,CAAC;IACjD,YAAY,CAAe;IAC3B,WAAW,CAAc;IACzB,GAAG,CAAa;IAEjC,YAAY,YAA0B,EAAE,WAAwB;QAC9D,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;QACjC,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;QAC/B,IAAI,CAAC,GAAG,GAAG,IAAI,UAAU,CAAC,EAAE,OAAO,EAAE,eAAe,EAAE,kBAAkB,qCAA6B,EAAE,QAAQ,EAAE,YAAY,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC,CAAC;QAC9I,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,yCAAyC,C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AAQ,CAAC;IAC3B,CAAC;IAED,IAAI,QAAQ,CAAC,QAAkB;QAC7B,IAAI,CAAC,GAAG,CAAC,QAAQ,GAAG,QAAQ,CAAC;IAC/B,CAAC;CAgCF"}
@@ -0,0 +1,40 @@
1
+ /**
2
+ * This file contains the entry point of Matterbridge.
3
+ *
4
+ * @file index.ts
5
+ * @author Luca Liguori
6
+ * @date 2023-12-29
7
+ * @version 1.0.6
8
+ *
9
+ * Copyright 2023, 2024, 2025 Luca Liguori.
10
+ *
11
+ * Licensed under the Apache License, Version 2.0 (the "License");
12
+ * you may not use this file except in compliance with the License.
13
+ * You may obtain a copy of the License at
14
+ *
15
+ * http://www.apache.org/licenses/LICENSE-2.0
16
+ *
17
+ * Unless required by applicable law or agreed to in writing, software
18
+ * distributed under the License is distributed on an "AS IS" BASIS,
19
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20
+ * See the License for the specific language governing permissions and
21
+ * limitations under the License. *
22
+ */
23
+ export type Identity<T> = T;
24
+ export type AtLeastOne<T> = ArrayMinLength<T, 1>;
25
+ type BuildArrayMinLength<T, N extends number, Current extends T[]> = Current['length'] extends N ? [...Current, ...T[]] : BuildArrayMinLength<T, N, [...Current, T]>;
26
+ export type ArrayMinLength<T, N extends number> = BuildArrayMinLength<T, N, []>;
27
+ export * from '@matter/main/clusters';
28
+ export * from '@matter/main/types';
29
+ export { SemanticNamespace, ClosureTag, CompassDirectionTag, CompassLocationTag, DirectionTag, ElectricalMeasurementTag, LaundryTag, LevelTag, LocationTag, NumberTag, PositionTag, PowerSourceTag, RefrigeratorTag, RoomAirConditionerTag, SwitchesTag, } from '@matter/node';
30
+ export * from '@project-chip/matter.js/device';
31
+ export * from '@project-chip/matter.js/cluster';
32
+ export * from './matterbridge.js';
33
+ export * from './matterbridgeTypes.js';
34
+ export * from './matterbridgeDevice.js';
35
+ export * from './matterbridgeEndpoint.js';
36
+ export * from './matterbridgeDeviceTypes.js';
37
+ export * from './matterbridgePlatform.js';
38
+ export * from './matterbridgeAccessoryPlatform.js';
39
+ export * from './matterbridgeDynamicPlatform.js';
40
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAKH,MAAM,MAAM,QAAQ,CAAC,CAAC,IAAI,CAAC,CAAC;AAE5B,MAAM,MAAM,UAAU,CAAC,CAAC,IAAI,cAAc,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AAEjD,KAAK,mBAAmB,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,EAAE,OAAO,SAAS,CAAC,EAAE,IAAI,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAC,GAAG,CAAC,GAAG,OAAO,EAAE,GAAG,CAAC,EAAE,CAAC,GAAG,mBAAmB,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,GAAG,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC;AAErK,MAAM,MAAM,cAAc,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,IAAI,mBAAmB,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC;AAIhF,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC;AACnC,OAAO,EACL,iBAAiB,EACjB,UAAU,EACV,mBAAmB,EACnB,kBAAkB,EAClB,YAAY,EACZ,wBAAwB,EACxB,UAAU,EACV,QAAQ,EACR,WAAW,EACX,SAAS,EACT,WAAW,EACX,cAAc,EACd,eAAe,EACf,qBAAqB,EACrB,WAAW,GACZ,MAAM,cAAc,CAAC;AAGtB,cAAc,gCAAgC,CAAC;AAC/C,cAAc,iCAAiC,CAAC;AAGhD,cAAc,mBAAmB,CAAC;AAClC,cAAc,wBAAwB,CAAC;AACvC,cAAc,yBAAyB,CAAC;AACxC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,oCAAoC,CAAC;AACnD,cAAc,kCAAkC,CAAC"}
package/dist/index.js CHANGED
@@ -1,10 +1,36 @@
1
+ /**
2
+ * This file contains the entry point of Matterbridge.
3
+ *
4
+ * @file index.ts
5
+ * @author Luca Liguori
6
+ * @date 2023-12-29
7
+ * @version 1.0.6
8
+ *
9
+ * Copyright 2023, 2024, 2025 Luca Liguori.
10
+ *
11
+ * Licensed under the Apache License, Version 2.0 (the "License");
12
+ * you may not use this file except in compliance with the License.
13
+ * You may obtain a copy of the License at
14
+ *
15
+ * http://www.apache.org/licenses/LICENSE-2.0
16
+ *
17
+ * Unless required by applicable law or agreed to in writing, software
18
+ * distributed under the License is distributed on an "AS IS" BASIS,
19
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
20
+ * See the License for the specific language governing permissions and
21
+ * limitations under the License. *
22
+ */
1
23
  import { Matterbridge } from './matterbridge.js';
2
24
  import { MatterbridgeEdge } from './matterbridgeEdge.js';
25
+ // @matter
26
+ // export { Identity, AtLeastOne } from '@matter/main';
3
27
  export * from '@matter/main/clusters';
4
28
  export * from '@matter/main/types';
5
29
  export { SemanticNamespace, ClosureTag, CompassDirectionTag, CompassLocationTag, DirectionTag, ElectricalMeasurementTag, LaundryTag, LevelTag, LocationTag, NumberTag, PositionTag, PowerSourceTag, RefrigeratorTag, RoomAirConditionerTag, SwitchesTag, } from '@matter/node';
30
+ // @project-chip
6
31
  export * from '@project-chip/matter.js/device';
7
32
  export * from '@project-chip/matter.js/cluster';
33
+ // Matterbridge
8
34
  export * from './matterbridge.js';
9
35
  export * from './matterbridgeTypes.js';
10
36
  export * from './matterbridgeDevice.js';
@@ -17,15 +43,19 @@ const cli = '\u001B[32m';
17
43
  const er = '\u001B[38;5;9m';
18
44
  const rs = '\u001B[40;0m';
19
45
  async function main() {
46
+ // eslint-disable-next-line no-console
20
47
  if (process.argv.includes('-debug'))
21
48
  console.log(cli + 'MAIN: Matterbridge.loadInstance() called' + rs);
22
49
  if (process.argv.includes('-edge'))
23
50
  await MatterbridgeEdge.loadInstance();
24
51
  else
25
52
  await Matterbridge.loadInstance();
53
+ // eslint-disable-next-line no-console
26
54
  if (process.argv.includes('-debug'))
27
55
  console.log(cli + 'MAIN: Matterbridge.loadInstance() exited' + rs);
28
56
  }
29
57
  main().catch((error) => {
58
+ // eslint-disable-next-line no-console
30
59
  console.error(er + `MAIN: Matterbridge.loadInstance() failed with error: ${error}` + rs);
31
60
  });
61
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAUzD,UAAU;AACV,uDAAuD;AACvD,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC;AACnC,OAAO,EACL,iBAAiB,EACjB,UAAU,EACV,mBAAmB,EACnB,kBAAkB,EAClB,YAAY,EACZ,wBAAwB,EACxB,UAAU,EACV,QAAQ,EACR,WAAW,EACX,SAAS,EACT,WAAW,EACX,cAAc,EACd,eAAe,EACf,qBAAqB,EACrB,WAAW,GACZ,MAAM,cAAc,CAAC;AAEtB,gBAAgB;AAChB,cAAc,gCAAgC,CAAC;AAC/C,cAAc,iCAAiC,CAAC;AAEhD,eAAe;AACf,cAAc,mBAAmB,CAAC;AAClC,cAAc,wBAAwB,CAAC;AACvC,cAAc,yBAAyB,CAAC;AACxC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,oCAAoC,CAAC;AACnD,cAAc,kCAAkC,CAAC;AAEjD,MAAM,GAAG,GAAG,YAAY,CAAC;AACzB,MAAM,EAAE,GAAG,gBAAgB,CAAC;AAC5B,MAAM,EAAE,GAAG,cAAc,CAAC;AAE1B,KAAK,UAAU,IAAI;IACjB,sCAAsC;IACtC,IAAI,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC;QAAE,OAAO,CAAC,GAAG,CAAC,GAAG,GAAG,0CAA0C,GAAG,EAAE,CAAC,CAAC;IACxG,IAAI,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC;QAAE,MAAM,gBAAgB,CAAC,YAAY,EAAE,CAAC;;QACrE,MAAM,YAAY,CAAC,YAAY,EAAE,CAAC;IACvC,sCAAsC;IACtC,IAAI,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC;QAAE,OAAO,CAAC,GAAG,CAAC,GAAG,GAAG,0CAA0C,GAAG,EAAE,CAAC,CAAC;AAC1G,CAAC;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,KAAK,EAAE,EAAE;IACrB,sCAAsC;IACtC,OAAO,CAAC,KAAK,CAAC,EAAE,GAAG,wDAAwD,KAAK,EAAE,GAAG,EAAE,CAAC,CAAC;AAC3F,CAAC,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from 'node-ansi-logger';
2
+ //# sourceMappingURL=export.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"export.d.ts","sourceRoot":"","sources":["../../src/logger/export.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC"}
@@ -1 +1,2 @@
1
1
  export * from 'node-ansi-logger';
2
+ //# sourceMappingURL=export.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"export.js","sourceRoot":"","sources":["../../src/logger/export.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC"}
@@ -0,0 +1,11 @@
1
+ export * from '@matter/main';
2
+ export { AggregatorEndpoint } from '@matter/main/endpoints';
3
+ export * from '@matter/main/devices';
4
+ export * from '@matter/main/behaviors';
5
+ export { ExposedFabricInformation, FabricAction, MdnsService, PaseClient } from '@matter/main/protocol';
6
+ export { AttributeElement, ClusterElement, ClusterModel, CommandElement, EventElement, FieldElement } from '@matter/main/model';
7
+ export * from '../matterbridgeDeviceTypes.js';
8
+ export * from '../matterbridgeEndpoint.js';
9
+ export * from '../matterbridgeBehaviors.js';
10
+ export * from '../matterbridgeEdge.js';
11
+ //# sourceMappingURL=export.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"export.d.ts","sourceRoot":"","sources":["../../src/matter/export.ts"],"names":[],"mappings":"AACA,cAAc,cAAc,CAAC;AAC7B,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAC5D,cAAc,sBAAsB,CAAC;AACrC,cAAc,wBAAwB,CAAC;AAEvC,OAAO,EAAE,wBAAwB,EAAE,YAAY,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AACxG,OAAO,EAAE,gBAAgB,EAAE,cAAc,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAGhI,cAAc,+BAA+B,CAAC;AAC9C,cAAc,4BAA4B,CAAC;AAC3C,cAAc,6BAA6B,CAAC;AAC5C,cAAc,wBAAwB,CAAC"}