Skip to main content

A Python module for the Philips Hue Lighting System API.

Project description

Installation

Using pip:

pip install beautifulhue

Using setuptools:

easy_install beautifulhue

Using source

python setup.py install

Example

"""Update light #3's state."""

from beautifulhue.api import Bridge

# Connect to a Philips Hue bridge.
bridge = Bridge(device={'ip':'bridge_ip_address'}, user={'name':'your_username'})
# Define the target resource, and its new related states.
resource = {
    'which':3,
    'data':{
        'state':{'on':True, 'ct':222}
    }
}
# Signal the bridge to execute your command when appropriate.
bridge.light.update(resource)

Features

  • Complete Philips Hue API v1.0 coverage.

  • Consistent method names.

  • Designed to get things done.

  • JSON/Pyton dictionary resource representation.

  • Default response structures are closely aligned with the official Philips Hue API response structures.

  • Extensible design.

  • Fine-grained system state control.

  • Complete Documentation

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

BeautifulHue-0.1.2.tar.gz (5.7 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page