I have a Denon receiver hidden in a cabinet. I want to reflect it’s current state (power on/off, input source) to an external LCD powered by esphome or espeasy via an http call. The Denon receiver is instantiated as a media_player using the Denon AVR network receivers integration. I’ve tried many different ways to extract the state of the Denon and everything fails. Here is my non-working entry from automations.yaml (excuse any formatting issues, this is my first post)
- id: '1661665167001'
alias: Reflect_Fam_Denon_Status
trigger:
- platform: device
type: changed_states
entity_id: media_player.denon_fam_room
domain: media_player
condition: []
action:
- rest_command:
- url: "http://192.168.xx.xx/endpt?state={ states(media_player.denon_fam_room) }&source={ states(media_player.denon_fam_room.source) }"
I’m trying to get the on/off state from: { states(media_player.denon_fam_room) } and the source input state from: { states(media_player.denon_fam_room.source) }. I’m also not certain my trigger is correct.