{ "info": { "author": "Adam Charnock", "author_email": "adam@adamcharnock.com", "bugtrack_url": null, "classifiers": [], "description": "Python Hue Client\n=================\n\n.. image:: https://img.shields.io/pypi/v/python-hue-client.svg\n :target: https://badge.fury.io/py/python-hue-client\n\n.. image:: https://img.shields.io/pypi/dm/python-hue-client.svg\n :target: https://pypi.python.org/pypi/python-hue-client\n\n.. image:: https://img.shields.io/github/license/adamcharnock/python-hue-client.svg\n :target: https://pypi.python.org/pypi/python-hue-client/\n\n\nA full-featured Python client for the Philips Hue lighting system.\n\nInstallation\n------------\n\nInstallation using pip (recommended)::\n\n pip install python-hue-client\n\nInstallation using easy_install::\n\n easy_install python-hue-client\n\nDocumentation\n-------------\n\nDocumentation can be found at http://python-hue-client.readthedocs.org\n\nQuick Start\n-----------\n\nThis library is modelled roughly on concepts borrowed from Django's ORM.\nThere are some `examples`_ available in GitHub, but let's dive in\nwith an example that list all the available lights::\n\n from pprint import pprint\n from hueclient.api import hue_api\n from hueclient.models.light import Light\n\n if __name__ == '__main__':\n hue_api.authenticate_interactive(app_name='List Lights Example')\n\n for light in Light.objects.all():\n print(\n \"Light {id} is named '{name}' and is {onoff} (brightness: {brightness})\".format(\n id=light.id,\n name=light.name,\n onoff='on' if light.state.on else 'off',\n brightness=light.state.brightness,\n )\n )\n\nHere is an example which blinks a specific light::\n\n from time import sleep\n from hueclient.api import hue_api\n from hueclient.models.light import Light\n\n # examples/blink_light.py\n if __name__ == '__main__':\n # Make sure we are authenticated with the hue bridge.\n # You will be prompted if no username is found in ~/.python_hue\n hue_api.authenticate_interactive(app_name='Blink Light Example')\n\n # Get light ID 1\n light = Light.objects.get(id=1)\n\n # Loop forever\n while True:\n # Flip the on state from on -> off / off -> on\n light.state.on = not light.state.on\n\n # Save the state back to the bridge\n # (Note: required in order for your changes to take effect)\n\n light.state.save()\n\n # Pause here for a couple of seconds to create a slow blink\n # (Note: It is important to sleep here at least a little to\n # avoid overloading the bridge with API requests)\n sleep(2)\n\nFor more information see the `full documentation `_.\n\nCredits\n-------\n\nDeveloped by `Adam Charnock`_, contributions very welcome!\n\npython-hue-client is packaged using seed_.\n\n.. _seed: https://github.com/adamcharnock/seed/\n.. _examples: https://github.com/adamcharnock/python-hue-client/tree/master/examples\n.. _Adam Charnock: https://adamcharnock.com", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://github.com/adamcharnock/python-hue-client", "keywords": null, "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "python-hue-client", "package_url": "https://pypi.org/project/python-hue-client/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/python-hue-client/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://github.com/adamcharnock/python-hue-client" }, "release_url": "https://pypi.org/project/python-hue-client/0.1.0/", "requires_dist": null, "requires_python": null, "summary": "UNKNOWN", "version": "0.1.0" }, "last_serial": 1724453, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "cc78bd01bd2a8fdffa8f599a1dad7340", "sha256": "0aa4ed069ad61864e4e5cd33a4e1dc0af9e347fdbe9f57394f6e982df88734f5" }, "downloads": -1, "filename": "python_hue_client-0.1.0-cp27-none-macosx_10_10_x86_64.whl", "has_sig": false, "md5_digest": "cc78bd01bd2a8fdffa8f599a1dad7340", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 4555, "upload_time": "2015-09-15T23:24:52", "url": "https://files.pythonhosted.org/packages/a0/e2/e838bee8de038456d5377e7cc9c739e5d509b9e28458f833df63278eb902/python_hue_client-0.1.0-cp27-none-macosx_10_10_x86_64.whl" }, { "comment_text": "", "digests": { "md5": "ed4c545e6ce01935e00b23919ba13502", "sha256": "16d7de2fe0ca1594d56bb06f06eed3a5f627eb6f45dcfdb19e7422a6af0a7e1b" }, "downloads": -1, "filename": "python-hue-client-0.1.0.tar.gz", "has_sig": false, "md5_digest": "ed4c545e6ce01935e00b23919ba13502", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 916994, "upload_time": "2015-09-15T23:24:45", "url": "https://files.pythonhosted.org/packages/be/9a/1e6438910cbba3f0a320b475eff74d28aa738eb49887cab006f20764605b/python-hue-client-0.1.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "cc78bd01bd2a8fdffa8f599a1dad7340", "sha256": "0aa4ed069ad61864e4e5cd33a4e1dc0af9e347fdbe9f57394f6e982df88734f5" }, "downloads": -1, "filename": "python_hue_client-0.1.0-cp27-none-macosx_10_10_x86_64.whl", "has_sig": false, "md5_digest": "cc78bd01bd2a8fdffa8f599a1dad7340", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 4555, "upload_time": "2015-09-15T23:24:52", "url": "https://files.pythonhosted.org/packages/a0/e2/e838bee8de038456d5377e7cc9c739e5d509b9e28458f833df63278eb902/python_hue_client-0.1.0-cp27-none-macosx_10_10_x86_64.whl" }, { "comment_text": "", "digests": { "md5": "ed4c545e6ce01935e00b23919ba13502", "sha256": "16d7de2fe0ca1594d56bb06f06eed3a5f627eb6f45dcfdb19e7422a6af0a7e1b" }, "downloads": -1, "filename": "python-hue-client-0.1.0.tar.gz", "has_sig": false, "md5_digest": "ed4c545e6ce01935e00b23919ba13502", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 916994, "upload_time": "2015-09-15T23:24:45", "url": "https://files.pythonhosted.org/packages/be/9a/1e6438910cbba3f0a320b475eff74d28aa738eb49887cab006f20764605b/python-hue-client-0.1.0.tar.gz" } ] }