Im not great at templating and Im sure I did something wrong. Could anyone please explain to me how to fix it? My broadcast notification works but they are coming through twice for one event.
The second half of your template isn’t doing anything… what was you goal for the if/then statement?
If this automation is just for motion being detected, you should set a to: on in the trigger so that only a state change to “on” fires the automation. When you use a state trigger without assigning a to or from, the automation will also trigger on changes to any attribute of the binary sensor.