A simple command-line interface to control Elgato Key Light devices using Babashka.
- Babashka
- An Elgato Key Light device on your network
- Clone this repository:
git clone https://github.com/versality/keylight-cli
cd keylight-cli- Make the script executable (optional):
chmod +x keylight.bbbb keylight.bb <ip-address> [on|off]Toggle the light (switch between on and off):
bb keylight.bb 192.168.1.123Turn the light on:
bb keylight.bb 192.168.1.123 onTurn the light off:
bb keylight.bb 192.168.1.123 offThe script communicates with the Elgato Key Light's HTTP API (port 9123) to control the device. It can:
- Query the current state of the light
- Turn the light on or off
- Toggle the light's state
- babashka.http-client
- cheshire (for JSON parsing)
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
- Elgato for providing the Key Light API
- Babashka project for making Clojure scripting accessible