I can send a Telegram command called /status where it will return statuses of certain devices (lock, certain lights, etc.). I have a few questions:
- How can I include the device’s name along with the status?
- Is there a way to format the Telegram message so that each device’s name and status is returned on a separate line?
Here’s my automation:
- id: telegramstatusinquiry
alias: Telegram - Status inquiry
trigger:
- event_data:
command: /status
event_type: telegram_command
platform: event
condition: []
action:
- service: telegram_bot.send_message
data_template:
message: >
{{ states.lock.schlage_be468_touchscreen_deadbolt_locked.state }},
{{ states.group.family.state }}
Here’s what the automation is currently returning in Telegram: https://imgur.com/kZ4OtVm