Not sure why, it is the correct url for the api. the inclusion of the camera name is extra information but the url still functions in my testing just now.
try a fresh automation rather than changing an existing one as there are a lot of changes. I’m here for a little while so PM me and we can sort it out.
Great work on the updates!
Would it be possible to have a few extra Android notification options added in your next revision? They should be quite simple to add.
Android:
channel - this will let the user setup custom sounds, override Do Not Disturb, etc…
sticky - makes it so the notification can’t be swiped away without interacting with it.
Both are simple to implement.
sticky:
name: (Optional) Sticky - Android Specific
description: When enabled, the notification will stay active on the device after interacting with it and remain there until cleared.
default: false
selector:
boolean: {}
channel:
name: (Optional) Channel - Android Specific
description: Create a new channel for notifications to allow custom notification sounds, vibration patterns and overide of Do Not Disturb mode. Configured directly on the device.
default: ''
Then under the data field in the notification, or set it as a variable to continue the same style as the rest.
channel: !input 'channel'
sticky: !input 'sticky'
The other thing that would be awesome is the ability to trigger an action completely unrelated to the notification. I’m thinking something like being able to call a script or trigger another automation that will turn on the outside lights for X number of mins, etc…
blueprint:
name: Frigate - Telegram Notification
description: Create automations to receive Snapshots and Clips from Frigate
domain: automation
input:
camera:
name: Frigate Camera
description: The name of the camera as defined in your frigate configuration (/conf.yml).
target_chat:
name: Target
description: "The chat_id to be used by the Telegram bot.
!secret chat_id is not allowed on Blueprint, you will need the chat_id code.
"
notification:
name: Notification
description:
'Select "true" to disable notification, lave "false" to receive
notification.
'
selector:
select:
options:
- "true"
- "false"
default: "false"
base_url:
name: (Optional) Base URL
description:
The external url for your Home Assistant instance. This will default
to a relative URL and will open the clips in the app instead of the browser,
which may cause issues on some devices.
default: ""
zone_filter:
name: (Optional) Zone Filter
description: Only notify if object has entered a defined zone.
default: false
selector:
boolean: {}
zones:
name: (Optional) Trigger Zones
description: A list (-) of zones you wish to recieve notifications for.
default: []
selector:
object: {}
labels:
name: (Optional) Trigger Objects
description: A list (-) of objects you wish to recieve notifications for.
default: []
selector:
object: {}
presence_filter:
name: (Optional) Presence Filter
description: Only notify if selected presence entity is not "home".
default: ""
selector:
entity: {}
source_url: https://gist.github.com/NdR91/5486a1e55101e062c48545395b7dd9a3
mode: single
max_exceeded: silent
trigger:
platform: mqtt
topic: frigate/events
payload: !input "camera"
value_template: "{{ value_json['after']['camera'] }}"
variables:
id: "{{ trigger.payload_json['after']['id'] }}"
camera: "{{ trigger.payload_json['after']['camera'] }}"
camera_name: "{{ camera | replace('_', ' ') | title }}"
target_chat: !input "target_chat"
object: "{{ trigger.payload_json['after']['label'] }}"
label: "{{ object | title }}"
entered_zones: "{{ trigger.payload_json['after']['entered_zones'] }}"
type: "{{ trigger.payload_json['type'] }}"
base_url: !input "base_url"
zone_only: !input "zone_filter"
input_zones: !input "zones"
zones: "{{ input_zones | list }}"
input_labels: !input "labels"
labels: "{{ input_labels | list }}"
presence_entity: !input "presence_filter"
notification: !input "notification"
condition:
- "{{ type != 'end' }}"
- "{{ not zone_only or entered_zones|length > 0 }}"
- "{{ not zones|length or zones|select('in', entered_zones)|list|length > 0 }}"
- "{{ not labels|length or object in labels }}"
- "{{ not presence_entity or not is_state(presence_entity, 'home') }}"
action:
- service: telegram_bot.send_photo
data:
target: "{{ target_chat }}"
disable_notification: "{{ notification }}"
caption: |
Person Detected. Camera: {{ camera_name }}
url: >-
{{base_url}}/api/frigate/notifications/{{id}}/snapshot.jpg
- repeat:
sequence:
- wait_for_trigger:
- platform: mqtt
topic: frigate/events
payload: "{{ id }}"
value_template: "{{ value_json['after']['id'] }}"
timeout:
minutes: 2
continue_on_timeout: false
- condition: template
value_template: "{{ wait.trigger.payload_json['type'] == 'end' }}"
- service: telegram_bot.send_video
data:
target: "{{ target_chat }}"
disable_notification: "{{ notification }}"
caption: "Person Detected. Camera: {{ camera_name }}"
url: >-
{{base_url}}/api/frigate/notifications/{{id}}/{{camera}}/clip.mp4
until: "{{ wait.trigger.payload_json['type'] == 'end' }}"
Hmm, does seem odd. The clips link was working back on Frigate 0.10 and the old blueprint, but as you say the URL looks correct under 0.11 and your blueprint, so not sure why my Frigate instance doesn’t like it.
I’m hoping to move over to 0.12 as soon as it’s available anyway, so for now I’ve just tweaked the URL’s in your blueprint to suit my purpose which is working just fine, so I’ll have to remember not to update it willy nilly!
Hello everyone. I’m needing some help. Im running the latest HAOS, Frigate Proxy addon go2rtc addon, and frigate integration. Im trying to get video and image messages sent through the app as the blueprint above is suppose to help us do. However, I download the blueprint, create the automation, and when I test it to try and run it (even if I try to trigger it by standing in front of the camera) nothing happens. No trigger, no nothing. What is the prequasite if there is any before using this blueprint? There should be no reason not to be able to get this working. My HAOS is on VM via Synology and Frigate is on a separate server. Any help would be appreciated.