Skip to content

Latest commit

 

History

History
31 lines (22 loc) · 498 Bytes

README.md

File metadata and controls

31 lines (22 loc) · 498 Bytes

SwitchBot CLI

example

~/.switch_bot/config
├── devices
│   ├── desk_light ... device_id
│   └── room_light ... device_id
└── token ... get from SwitchBot app!
# show your devices
$ my_room devices

# setup device ID
$ echo 'desk-light-device-id' > devices/desk_light

# custom main.rs
"desk_light_on" => client::post_turn_on_command("desk_light"),

# build
$ cargo build

# light on!
$ my_room desk_light_on

Try to customize src/main.rs!