Weekday time condition

I am trying to test the time condition to only trigger on specific days.
right now I am testing with a simple trigger that sends an mqtt message when a wemo light switch is switched. I want it to only send the message on tuesday and wednesday. The config is valid when I check from the web interface but it triggers on all days.
Here is my config:

- action:
  - data:
      payload: weekday?
      topic: bell/test/1
    service: mqtt.publish
  alias: wemoo switch
  condition:
    condition: time
  - weekday:
    - tue
    - wed
  id: '1514078501286'
  trigger:
  - entity_id: switch.wemooo
    platform: state

Thanks in advance. :smiley:

I use AppDeamon so my YAML isn’t great I’m afraid. That said everything looks little jumbled up to me. Try this:

- alias: Wemoo Switch State Changed
  trigger:
    platform: state
    entity_id: switch.wemooo
  condition:
  - condition: time
    weekday:
      - tue
      - wed
  action:
    service: mqtt.publish
    data:
      topic: "bell/test/1"
      payload: "Value to send to topic"

I tried your version it is still sending the mqtt even though its not tue (or wed)…
It seems there is also a problem in the web console that reloading automations does not reload. I restarted homeassistant from commandline and now it is following the automation rules and only works on days specified.

thanks.
Now i would still like to know exactly whats different because I just added in the weekdays to the automatically (by homeassistant web console) configured automations file.

And also the automation as it is now does not show up in the web console. It seems that when I did everything from cli it worked much better. I was trying to move over to web console and test it out. It seems its not really ready yet. I will keep that in mind when try using it from now on.