# automation for everything that has to be switched by the Spotswitch virtual switches
# in this example the closein_boiler is switched by Spotswitch condition 5

- id: FolowupSpotswitch5
  alias: ActionsOnSpotswitch5
  description: defines what happens if Spotswitch5 changes
  trigger:
  - platform: state
    entity_id:
      - switch.spotswitch5
    to:
  action:
  - service: "switch.turn_{{ trigger.to_state.state }}"
    target:
      entity_id:
        - switch.closein_boiler_plug_mini
  - delay: 1
  mode: single
  max_exceeded: silent

