jordao76/hello-lights ? reverse-engineered prompt

Reverse engineered prompt

Build me a small Node.js app that can control a Cleware USB traffic light from the command line and from a simple local web server.

I want a CLI where I can run commands like turning lights on and off, making them blink or twinkle, running a sequence from a file, and opening an interactive prompt. It should also be able to talk to a remote server instead of the local device when needed.

Please also add a web server mode that exposes the same controls through a few simple HTTP endpoints, plus a basic browser page at the root so I can try it out in a browser. It should be able to list the available commands, show help for one command, report connected devices, and cancel a running action.

Make sure it includes tests, documentation comments, and a clean setup so it can be used both as a library in another Node project and as a standalone command line tool. If you need to check current docs for the hardware or Node APIs, look them up online.

Are you gonna build this?

make sure you review the code using coderabbit

Try freeSponsored — opens CodeRabbit in a new tab