sidoh / esp8266_milight_hub

Replacement for a Milight/LimitlessLED hub hosted on an ESP8266
MIT License
931 stars 219 forks source link

REST API fields in color/white mode #748

Closed kovapatrik closed 2 years ago

kovapatrik commented 2 years ago

I'm using this hub in my smart home, and I want to do an initialization, when the smart home system boots up. But the REST API only returns 'color_temp', when the light is in white mode, and 'saturation' and 'hue' when it's in color mode. Is there a way, to get these properties even if the light isn't in the corresponding mode?

sidoh commented 2 years ago

Fields specific to a particular bulb mode (i.e., "color" or "white") are only available when the bulb is in that mode. There is presently not a great way to get these properties.

I'm going to close this because it's expected behavior. If you want to take a stab at a PR which optionally changes this behavior, I'm happy to review it.