Manual/Guide to Automation Creation via Front End?

Hi guys

Since the last update to allow automation creation via the front end, I want to learn how to use the “programing language” or how to structure it I am clueless right now and can only work by looking at existing example. How do you populate the service data? the formatting etc.

Is the below screenshot even correct?

Thanks!

Well, there are 3 areas of interest:

  • trigger
  • condition
  • action

This can be simplified to:

  • when this happens
  • if this
  • do that

Triggers are events, IE. When a device tracker leaves a zone

Conditions are well, conditional - of a device trackers state is not_home etc

And actions are what you’ve got in your screenshot - a good example would be notify you if the door opens and you’re not home, the trigger/condition/action for that would be:

  • the state of the door goes from closed to open
  • your device tracker is not at home
  • exactly your screenshot above

Does this help?

1 Like

To elaborate, yes your above post is correct, service data is JSON, check out https://jsonlint.com/ as a quick way to get started with JSON (the notation of the service data)

Hi @matchett808 I was looking for guide more specific on how to structure the JSON in the action field.