mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-15 15:45:27 +03:00
Add onConnect to mqtt and doucment
This commit is contained in:
parent
a6ccb37683
commit
ed1ad26c29
@ -147,6 +147,10 @@ Message published for each changed review item. The first message is published w
|
|||||||
|
|
||||||
Same data available at `/api/stats` published at a configurable interval.
|
Same data available at `/api/stats` published at a configurable interval.
|
||||||
|
|
||||||
|
### `frigate/camera_activity`
|
||||||
|
|
||||||
|
Returns data about each camera, its current features, and if it is detecting motion, objects, etc. Can be triggered by publising to `frigate/onConnect`
|
||||||
|
|
||||||
### `frigate/notifications/set`
|
### `frigate/notifications/set`
|
||||||
|
|
||||||
Topic to turn notifications on and off. Expected values are `ON` and `OFF`.
|
Topic to turn notifications on and off. Expected values are `ON` and `OFF`.
|
||||||
|
|||||||
@ -222,6 +222,10 @@ class MqttClient(Communicator): # type: ignore[misc]
|
|||||||
self.on_mqtt_command,
|
self.on_mqtt_command,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
self.client.message_callback_add(
|
||||||
|
f"{self.mqtt_config.topic_prefix}/onConnect", self.on_mqtt_command
|
||||||
|
)
|
||||||
|
|
||||||
self.client.message_callback_add(
|
self.client.message_callback_add(
|
||||||
f"{self.mqtt_config.topic_prefix}/restart", self.on_mqtt_command
|
f"{self.mqtt_config.topic_prefix}/restart", self.on_mqtt_command
|
||||||
)
|
)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user