A service that controls Hue devices and emits information about them to NATS.
Author: Carl Danley
Last Updated: 16/03/20 21:02:03
A project focused on exposing information about Philips Hue devices to an event bus.
It’s recommended to run a single instance of alfred-hue.
alfred-hue uses an in-memory cache which limits the number of instances that should be run at a given time. Each instance of
alfred-hue is capped at a maximum of 12 cache updates per second (1 cache update request per 83.3 ms). In my testing, I’ve found that each cache update usually takes ~150-160 ms (~6 requests per second). Adding multiple instances of
alfred-hue will add additional stress to the Hue bridge in your infrastructure which may potentially cause the bridge to become less responsive (which in turn, inhibits the request latency for interacting with lights).
To get started, you’ll need at least the following hardware:
- Philips Hue Bridge (version 3+ is preferable) – Amazon Link
I’ve tested all of the following Philips Hue Accessories with success:
- Philips Hue Indoor Motion Sensor – Amazon Link
- Philips Hue Smart Bulb – Amazon Link
- Philips Hue LightStrip Plus – Amazon Link
- Philips Hue Smart Spot Lights – Amazon Link
- Philips Hue Outdoor Motion Sensor – Amazon Link
||The NATS connection URL used when connecting to the NATS cluster/server.||
||The event prefix that will be used when publishing or subscribing to events.||
||The queue name that
||The host or IP address of the Philips Hue Bridge you’re configured alfred-hue to connect to||
||The generated Philips Hue User ID you acquire when pairing your application with the Philips Hue Bridge||
||The port that will be used for hosting the Prometheus metrics endpoint||
NATS Events Published
Here is a list of the events published to the event bus on state change:
NATS Requests Available
Here is a list of the request events that
alfred-hue listens for: