I would like to use secrets in my (telegram bot send photo) automation action, but whatever I try it fails. Does this mean that secrets are not supported (yet) in this case?
I saved 3 secrets like this
reolink_user: "admin"
reolink_password: "xxx"
reolink_url: "http://192.168.2.30/cgi-bin/api.cgi?cmd=Snap&channel=0&rs=xxx&user=admin&password=xxx"
and try to use them in this automation:
- action: telegram_bot.send_photo
data:
authentication: digest
url: !secret reolink_url
username: !secret reolink_user
password: !secret reolink_password
caption: "Ring doorbel at {{ now().strftime('%H:%M') }}."
entity_id: notify.telegram_bot_xxx
config_entry_id: xxx
I can't save the automation because of:
Error parsing YAML: unknown tag !<!secret> (line: 33, column: 31)
and
Error: Failed to load URL: Request URL is missing an '[http://'](http://'/) or '[https://'](https://'/) protocol.
the full automation without secrets works:
alias: Doorbel
description: ""
triggers:
- entity_id:
- binary_sensor.deurbel_visitor
to: "on"
trigger: state
conditions: []
actions:
- data:
authentication: digest
url: http://192.168.2.30/cgi-bin/api.cgi?cmd=Snap&channel=0&rs=xxx&user=admin&password=xxx
caption: Ring doorbel at {{now().strftime('%H:%M')}}.
entity_id: notify.telegram_bot_xxx
username: admin
password: xxx
config_entry_id: xxx
action: telegram_bot.send_photo
mode: queued
max: 10