I am trying to do an automation when a change in app is detected. But the autmoation is never triggered. Any idea why?
alias: Spotify Test
description: ""
triggers:
- trigger: state
entity_id:
- media_player.google_tv
attribute: app_id
to: CC32E753
conditions: []
actions:
- action: notify.mobile_app_iphone_van_ewald
metadata: {}
data:
message: Spotify Test
mode: single
I also tried with name:
alias: Spotify Test 2
description: ""
triggers:
- trigger: state
entity_id:
- media_player.google_tv
to: Spotify
attribute: Name
conditions: []
actions:
- action: notify.mobile_app_iphone_van_ewald
metadata: {}
data:
message: Spotify Test
mode: single
The end goal is to get this script working:
alias: Spotify
description: ""
triggers:
- trigger: state
entity_id:
- media_player.google_tv
attribute: app_id
to: CC32E753
- device_id: c3481901b139251a4249534245192e09
domain: media_player
entity_id: f10ca154efd39ab2dce5a72b899ef6d6
type: buffering
trigger: device
- device_id: c3481901b139251a4249534245192e09
domain: media_player
entity_id: f10ca154efd39ab2dce5a72b899ef6d6
type: playing
trigger: device
conditions:
- condition: or
conditions:
- condition: state
entity_id: media_player.google_tv
attribute: app_name
state: Spotify
- condition: state
entity_id: media_player.allemaal
attribute: app_name
state: Spotify
- condition: state
entity_id: media_player.google_tv
attribute: app_id
state: CC32E753
- condition: state
entity_id: media_player.allemaal
attribute: app_id
state: CC32E753
actions:
- type: turn_on
device_id: c903443960cce5162b5c813abfc89ef7
entity_id: 452cb4def55a6bcad746ec750977968c
domain: light
mode: single
tHANK YOU!