Are Command_line switches with an input_slider value possible?

I wasn’t expecting them to work really, but before I come up with something else - is there a way to insert the values here?

my example:

- platform: command_line
  switches:
    mote_custom_switch_rgb:
      command_on: curl -s http://[IP]/larsonloop_rgb/1234/1/{{ states.input_slider.mote_value_red.state | int }}/{{ states.input_slider.mote_value_green.state | int }}/{{ states.input_slider.mote_value_blue.state | int }}'/0.1/0/2
      command_off: curl -s http://[IP]/larsonloop/1200/0/ee7600/0.1/1/1
      friendly_name: Mote Custom Switch rgb

I’ve tried combinations with & without quotes both single & double.

Here is a working example. Not command_line but shell_command.

1 Like

Thanks! Very handy!