I looked at using Dark Sky with cloud cover as a trigger, but for example today we have 100% cloud cover but it was still bright… then it went dark as hell, no rain but still 100% cloud cover. I don’t see this as a viable option, for me anyway. pity.
Thanks for all the help. My code was good it’s just that this only triggers if the binary sensor changes to on and not if if HASS starts up with it set to on.
I agree a light sensor is probably the better option but it was fun to get this working anyway!