I am not familiair with the command line switch, but one way to get it working is by combining an input_boolean and a template switch:
input_boolean:
toggle_switch:
name: Hue
switch:
- platform: template
switches:
bedtime_onoff:
value_template: "{{ is_state('input_booelan.toggle_switch', 'on') }}"
turn_on:
service: script.turn_on
entity_id: script.bedtime_on
turn_off:
service: script.turn_on
entity_id: script.bedtime_off