As usual, I’ve spent the last 30 minutes trying various configurations of YAML code to get something very simple working, and that’s changing the temperature of my Nest thermostat. The documentation has no examples for automation and I couldn’t find anything relevant in the forums or on Reddit. I’ve tried inspecting the network tab to see what data is being passed from the web interface when using ‘developer-tools/state’.
Using http://hassio.local:8123/developer-tools/service to set the temperature works with the following key value pairs:
entity_id: climate.kitchen_nest
temperature: 19
… but doesn’t show how this might be added to an automations.yaml file.
When trying to validate my automations.yaml
I get:
Error loading /config/configuration.yaml: mapping values are not allowed here
in "/config/automations.yaml", line 133, column 13
The current version is:
- id: '10000202'
alias: My Phone AWAY (Bluetooth)
trigger:
entity_id: device_tracker.samsung_galaxy_s10plus_bt
platform: state
from: 'home'
to: 'not_home'
condition:
condition: state
entity_id: device_tracker.samsung_galaxy_s10plus
state: 'not_home'
action:
- service: homeassistant.turn_off
entity_id: switch.hall_lights,group.all_lights
- service: notify.pushover
data:
title: My Phone Offline (Bluetooth and Wifi)
message: 'Turned all lights off and set temperature.'
- service: climate.set_temperature
entity_id: climate.kitchen_nest
data:
operation_mode: heat
temperature: 16
Line 133 is the data
line. I’ve nested this in so many different ways I’ve lost track now.
Any help appreciated. Thank you.