mirror of
https://github.com/blakeblackshear/frigate.git
synced 2024-11-21 19:07:46 +01:00
add telegram example
This commit is contained in:
parent
a4b88ac4a7
commit
f20b1d75e6
@ -1,5 +1,6 @@
|
|||||||
# Notification examples
|
# Notification examples
|
||||||
|
|
||||||
|
Here are some examples of notifications for the HomeAssistant android companion app:
|
||||||
```yaml
|
```yaml
|
||||||
automation:
|
automation:
|
||||||
|
|
||||||
@ -50,3 +51,21 @@ automation:
|
|||||||
image: "https://url.com/api/frigate/notifications/{{trigger.payload_json['after']['id']}}.jpg"
|
image: "https://url.com/api/frigate/notifications/{{trigger.payload_json['after']['id']}}.jpg"
|
||||||
tag: "{{trigger.payload_json['after']['id']}}"
|
tag: "{{trigger.payload_json['after']['id']}}"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
If you are using telegram, you can fetch the image directly from Frigate:
|
||||||
|
```yaml
|
||||||
|
automation:
|
||||||
|
- alias: Notify of events
|
||||||
|
trigger:
|
||||||
|
platform: mqtt
|
||||||
|
topic: frigate/events
|
||||||
|
action:
|
||||||
|
- service: notify.telegram_full
|
||||||
|
data_template:
|
||||||
|
message: 'A {{trigger.payload_json["after"]["label"]}} was detected.'
|
||||||
|
data:
|
||||||
|
photo:
|
||||||
|
# this url should work for addon users
|
||||||
|
- url: 'http://ccab4aaf-frigate:5000/events/{{trigger.payload_json["after"]["id"]}}/snapshot.jpg'
|
||||||
|
caption : 'A {{trigger.payload_json["after"]["label"]}} was detected on {{ trigger.payload_json["after"]["camera"] }} camera'
|
||||||
|
```
|
||||||
|
Loading…
Reference in New Issue
Block a user