{ "info": { "author": "truedread", "author_email": "truedread11@gmail.com", "bugtrack_url": null, "classifiers": [ "Environment :: Console", "License :: OSI Approved :: GNU General Public License v3 (GPLv3)", "Operating System :: OS Independent", "Programming Language :: Python :: 3.3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Topic :: Utilities" ], "description": "# pyhulu\n[![Build Status](https://travis-ci.com/truedread/pyhulu.svg?branch=master)](https://travis-ci.com/truedread/pyhulu)\n[![License: GPL v3](https://img.shields.io/badge/License-GPL%20v3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0)\n\nPython library for interacting with the E2E encrypted Hulu API\n\n# Usage\n\nFirst, initialize the `HuluClient` class with a device code, device key, and cookies:\n\n```python\nclient = pyhulu.HuluClient(device_code, device_key, cookies)\n```\n\n`device_code` is a three-digit string or integer (doesn't matter) denoting the device you will make requests as.\n\n`device_key` is a 16-byte AES key that corresponds to the device code you're using. This is used to decrypt the device config response.\n\n`cookies` can either be a cookie jar object or a dict of cookie key / value pairs. This is passed to the `requests` library, so whatever it takes will work. Examples here: http://docs.python-requests.org/en/master/user/quickstart/#cookies.\n\nWith the initialized `client` object, you can use the `load_playlist()` method:\n\n```python\nclient.load_playlist(video_id)\n```\n\n`video_id` is either a string or integer denoting the video ID to request a playlist for. This is NOT the ID in the `/watch/` URL! If you view the page source of a `/watch/` page, you'll find `\\\"content_id\\\"` which has the actual video ID used by the API.\n\nThis method returns a dict of the playlist response, which contains stream and license URLs.\n\n# Device Codes and Keys\n\n### PC\n- Device code: `159`\n- Device key (hex): `6ebfc84f3c304217b20fd9a66cb5957f`\n\n# Example Code\n\n```python\nimport pyhulu\nfrom http.cookiejar import MozillaCookieJar\n\ncj = MozillaCookieJar('cookies.txt')\ncj.load()\n\nclient = pyhulu.HuluClient('159', bytes.fromhex('6ebfc84f3c304217b20fd9a66cb5957f'), cj)\nprint(client.load_playlist(61085964))\n```\n\n# Installation\n\nTo install, either clone the repository and run `python setup.py install` or run `pip install pyhulu`.\n\n# To-Do\n\n- [x] Add unit tests\n- [x] Add to PyPI\n- [x] Add documentation\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/truedread/pyhulu", "keywords": "", "license": "GNU GPLv3", "maintainer": "", "maintainer_email": "", "name": "pyhulu", "package_url": "https://pypi.org/project/pyhulu/", "platform": "", "project_url": "https://pypi.org/project/pyhulu/", "project_urls": { "Homepage": "https://github.com/truedread/pyhulu" }, "release_url": "https://pypi.org/project/pyhulu/1.1.0/", "requires_dist": [ "pycryptodomex", "requests" ], "requires_python": "", "summary": "Python library for interacting with the E2E encrypted Hulu API", "version": "1.1.0" }, "last_serial": 4172111, "releases": { "1.0.0": [ { "comment_text": "", "digests": { "md5": "5533a3c74ce1a337e610cd81810602cb", "sha256": "0cc4afe1f7263d7c3569528b0209f0c69405ad93876c74f49a39e383fbe329ff" }, "downloads": -1, "filename": "pyhulu-1.0.0-py3-none-any.whl", "has_sig": false, "md5_digest": "5533a3c74ce1a337e610cd81810602cb", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 4312, "upload_time": "2018-08-13T22:43:41", "url": "https://files.pythonhosted.org/packages/53/6b/a5640fc8346c932fbd9920c414cae3fe2c52f4dd72424ab9a8f73faa4c47/pyhulu-1.0.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "0e7dc4595315d133dd9bcc7a499a5d9a", "sha256": "3123ee84a8fd15d787945aa450b704b25e8e3c5cbec8198eaa74dfda59c54660" }, "downloads": -1, "filename": "pyhulu-1.0.0.tar.gz", "has_sig": false, "md5_digest": "0e7dc4595315d133dd9bcc7a499a5d9a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3602, "upload_time": "2018-08-13T22:43:43", "url": "https://files.pythonhosted.org/packages/ae/7d/b77d3cf5fc8f0471d4a6f65b2f2a77f96543df198d5d5760074dc79a1daf/pyhulu-1.0.0.tar.gz" } ], "1.1.0": [ { "comment_text": "", "digests": { "md5": "1fde20ea5b0c587b05f2d08d9f8ba3fe", "sha256": "832972b62d4e0d11be7d6862159992a2efd45e554c577aea6fe51f86db04f549" }, "downloads": -1, "filename": "pyhulu-1.1.0-py3-none-any.whl", "has_sig": false, "md5_digest": "1fde20ea5b0c587b05f2d08d9f8ba3fe", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 4789, "upload_time": "2018-08-15T07:24:19", "url": "https://files.pythonhosted.org/packages/2a/42/d9179cf50388fe826705d116cf9ea67123b3737f8a7765fed7f91532646c/pyhulu-1.1.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "23e2167c2971efa345daae93929b9e3a", "sha256": "699886160d1e3ccbd5e7a3205a16ed76f441a6118e2e3dd1b6620126746f120b" }, "downloads": -1, "filename": "pyhulu-1.1.0.tar.gz", "has_sig": false, "md5_digest": "23e2167c2971efa345daae93929b9e3a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3983, "upload_time": "2018-08-15T07:24:20", "url": "https://files.pythonhosted.org/packages/eb/b3/d0998a4d5af5009318c42b90ea68c45ff88f4fbdc2d5bbbc27b50b3d8e47/pyhulu-1.1.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "1fde20ea5b0c587b05f2d08d9f8ba3fe", "sha256": "832972b62d4e0d11be7d6862159992a2efd45e554c577aea6fe51f86db04f549" }, "downloads": -1, "filename": "pyhulu-1.1.0-py3-none-any.whl", "has_sig": false, "md5_digest": "1fde20ea5b0c587b05f2d08d9f8ba3fe", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 4789, "upload_time": "2018-08-15T07:24:19", "url": "https://files.pythonhosted.org/packages/2a/42/d9179cf50388fe826705d116cf9ea67123b3737f8a7765fed7f91532646c/pyhulu-1.1.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "23e2167c2971efa345daae93929b9e3a", "sha256": "699886160d1e3ccbd5e7a3205a16ed76f441a6118e2e3dd1b6620126746f120b" }, "downloads": -1, "filename": "pyhulu-1.1.0.tar.gz", "has_sig": false, "md5_digest": "23e2167c2971efa345daae93929b9e3a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3983, "upload_time": "2018-08-15T07:24:20", "url": "https://files.pythonhosted.org/packages/eb/b3/d0998a4d5af5009318c42b90ea68c45ff88f4fbdc2d5bbbc27b50b3d8e47/pyhulu-1.1.0.tar.gz" } ] }