# Hue v0.2.0 - Table of Contents

> A client for the Philips Hue CLIP v2 local API — resources, eventstream, discovery, certificate pinning, and gamut-correct colour.

## Pages

- [hue](readme.md)

## Modules

- [Hue.Bridge.Body](Hue.Bridge.Body.md): Translates `set` options into a CLIP v2 request body, checking capabilities
against the cached resource first.
- [Hue.Bridge.Cache](Hue.Bridge.Cache.md): The ETS table behind `Hue.Bridge`, and every path that reads it.
- [Hue.Bridge.Graph](Hue.Bridge.Graph.md): Walks the resource graph to turn a target a human wrote into a resource this
library can act on.
- [Hue.Bridge.Merge](Hue.Bridge.Merge.md): Applies an eventstream delta to a cached resource.
- [Hue.Bridge.Names](Hue.Bridge.Names.md): Builds the two name indexes `Hue.Bridge` keeps beside its resources.
- [Hue.Bridge.Server](Hue.Bridge.Server.md): The process behind `Hue.Bridge`. Owns the ETS table; nothing else writes to it.
- [Hue.Bridge.Writes](Hue.Bridge.Writes.md): The pending-write queue: coalescing, and Hue's per-type rate limits.
- [Hue.Light](Hue.Light.md): Lights, addressed by the name you gave them in the Hue app.
- [Hue.Room](Hue.Room.md): Rooms, addressed by name.
- [Hue.Scene](Hue.Scene.md): Scenes, addressed by name.
- [Hue.Zone](Hue.Zone.md): Zones, addressed by name.

- Core
  - [Hue](Hue.md): A client for the local CLIP v2 API on Philips Hue bridges.
  - [Hue.Client](Hue.Client.md): A configured connection to one bridge.
  - [Hue.Error](Hue.Error.md): A normalised failure from a Hue bridge.
  - [Hue.Resource](Hue.Resource.md): Generic access to every CLIP v2 resource type.

- Setup
  - [Hue.Bridge](Hue.Bridge.md): A live model of one bridge: an ETS-backed cache seeded by a full fetch and
kept current by the eventstream.
  - [Hue.Bridge.Info](Hue.Bridge.Info.md): An identified bridge: where it is, which one it is, and the certificate that
was pinned when it was first trusted.
  - [Hue.Discovery](Hue.Discovery.md): Finds Hue bridges, by three methods, because no single one is sufficient.
  - [Hue.Pairing](Hue.Pairing.md): Obtains an application key from a bridge.
  - [Hue.Transport](Hue.Transport.md): TLS for Hue bridges, which cannot be verified the ordinary way.

- Events
  - [Hue.Event](Hue.Event.md): One resource change.
  - [Hue.Events](Hue.Events.md): Decodes the bridge's Server-Sent Events stream.

- Colour
  - [Hue.Color](Hue.Color.md): Colour conversion for Hue lights.
  - [Hue.Color.Gamut](Hue.Color.Gamut.md): The triangle of colours a particular light can actually produce.

