2 releases

0.1.0-alpha.2 Apr 24, 2022
0.1.0-alpha.1 Mar 20, 2022

#408 in HTTP client

36 downloads per month

Apache-2.0

18KB
303 lines

Hue Bridge API

Crates.io docs.rs

This crate provides async bindings for Hue Bridge API.

At the time of writing this, the Hue Bridge API is being migrated to API v2, but not all endpoints have been implemented. So this crate utilizes the implemented resources from v2 and plugs the rest with v1.


lib.rs:

This crate provides asynchronous API bindings for Hue Bridge CLIP API.
NOTE: You need to be registered and signed in to see the documentation.

In order to develop with this crate you need physical access to a Hue Bridge. The security of the Hue Bridge revolves around pressing the button on the device to register an "application" and get a unique application identifier back.

The client can be instantiated and used in two ways. By registering a new application with the hue bridge:

let client = HueBridge::new("https://hue-bridge.local")
    .with_ca_pem("/path/to/hue-bridge-ca.pem")
    .await?
    .register("hue-bindings")
    .await?;

Or by using an already registered application.

let client = HueBridge::new("https:://my-hue-bridge")
     .with_ca_pem("/path/to/hue-bridge-ca.pem")
     .with_username("my-randomly-generated-username")
     .await?;

Dependencies

~6–19MB
~279K SLoC