Hi, I’m playing around with creating a blueprint. So far I got an automation that works, which I’d like to convert to bp. When using something like this:
service: telegram_bot.send_photo
data:
caption: Motion detected in your absence!
url: https://[REDACTED].ui.nabu.casa{{ states.camera.inside.attributes.entity_picture }}
is there a template I could replace hardcoding the instance address with? So I could use something like {{ nabu.casa.address }}{{ states.camera.inside.attributes.entity_picture }} ?
Alternatively perhaps even better would be to use file: [some base path?]{{ states.camera.inside.attributes.entity_picture }} to send the photo from local file instead from url:, as {{ states.camera.inside.attributes.entity_picture }} returns a path like /api/whatever but passing that to file: fails the telegram service so there’s some “base” path I need to prepend I can’t figure out.
I take it you never solved this. I would love to do this because different than this is, file: would never work if you have multiple Home Assistant installations.
My case … I have HA installed at my gate and also in my winery.
They are 1 mile apart.
I want a notification sent out that a vehicle arrived at the gate.
Recipient phone is 99% guaranteed not to be pointed at Home Assistant gate, they are pointed to Home Assistant winery.
Thus, the path to the image in the notification must be absolute and via Nabu Casa.
This I would like the script to not hardcode the address, but use some sensor value to get the address. The reason is, I am installing a whole new system another mile away as a second entrance. I would love to copy the script over and not copy it over and change the hardcoded references.