connectlife-cloud


Nameconnectlife-cloud JSON
Version 0.1.0 PyPI version JSON
download
home_pagehttps://github.com/Connectlife-LLC/connectlife-cloud
SummaryConnectLife Cloud API client library for Home Assistant integrations
upload_time2025-09-10 06:24:47
maintainerNone
docs_urlNone
authorConnectLife LLC
requires_python>=3.8
licenseMIT
keywords homeassistant connectlife api client iot
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # ConnectLife Cloud API Client

A Python client library for the ConnectLife Cloud API, designed for Home Assistant integrations.

## Features

- Async/await support
- Full type hints
- Comprehensive error handling
- Device management
- Real-time status updates
- Power consumption tracking
- Self-check diagnostics

## Installation

```bash
pip install connectlife-cloud
```

## Usage

```python
import asyncio
from connectlife_cloud import ConnectLifeCloudClient

async def main():
    client = ConnectLifeCloudClient(
        client_id="your_client_id",
        client_secret="your_client_secret"
    )
    
    try:
        # Get devices
        devices = await client.get_devices(access_token="your_token")
        print(f"Found {len(devices)} devices")
        
        # Control a device
        result = await client.control_device(
            puid="device_puid",
            properties={"power": True, "mode": "cool"},
            access_token="your_token"
        )
        print(f"Control result: {result}")
        
    finally:
        await client.close()

asyncio.run(main())
```

## API Reference

### ConnectLifeCloudClient

The main client class for interacting with the ConnectLife Cloud API.

#### Methods

- `get_devices(access_token)`: Get list of devices
- `control_device(puid, properties, access_token)`: Control a device
- `get_property_list(device_type_code, device_feature_code, access_token)`: Get device properties
- `query_static_data(puid, access_token)`: Query static device data
- `get_hour_power(date, puid, access_token)`: Get hourly power consumption
- `get_self_check(no_record, puid, access_token)`: Get device self-check info

## License

MIT License

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/Connectlife-LLC/connectlife-cloud",
    "name": "connectlife-cloud",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "homeassistant, connectlife, api, client, iot",
    "author": "ConnectLife LLC",
    "author_email": "ConnectLife LLC <support@connectlife.com>",
    "download_url": "https://files.pythonhosted.org/packages/74/bf/cca8e185f4de82987f15f55182b15fcfa9334226d86ae62ca1cbcd45bfbb/connectlife_cloud-0.1.0.tar.gz",
    "platform": null,
    "description": "# ConnectLife Cloud API Client\r\n\r\nA Python client library for the ConnectLife Cloud API, designed for Home Assistant integrations.\r\n\r\n## Features\r\n\r\n- Async/await support\r\n- Full type hints\r\n- Comprehensive error handling\r\n- Device management\r\n- Real-time status updates\r\n- Power consumption tracking\r\n- Self-check diagnostics\r\n\r\n## Installation\r\n\r\n```bash\r\npip install connectlife-cloud\r\n```\r\n\r\n## Usage\r\n\r\n```python\r\nimport asyncio\r\nfrom connectlife_cloud import ConnectLifeCloudClient\r\n\r\nasync def main():\r\n    client = ConnectLifeCloudClient(\r\n        client_id=\"your_client_id\",\r\n        client_secret=\"your_client_secret\"\r\n    )\r\n    \r\n    try:\r\n        # Get devices\r\n        devices = await client.get_devices(access_token=\"your_token\")\r\n        print(f\"Found {len(devices)} devices\")\r\n        \r\n        # Control a device\r\n        result = await client.control_device(\r\n            puid=\"device_puid\",\r\n            properties={\"power\": True, \"mode\": \"cool\"},\r\n            access_token=\"your_token\"\r\n        )\r\n        print(f\"Control result: {result}\")\r\n        \r\n    finally:\r\n        await client.close()\r\n\r\nasyncio.run(main())\r\n```\r\n\r\n## API Reference\r\n\r\n### ConnectLifeCloudClient\r\n\r\nThe main client class for interacting with the ConnectLife Cloud API.\r\n\r\n#### Methods\r\n\r\n- `get_devices(access_token)`: Get list of devices\r\n- `control_device(puid, properties, access_token)`: Control a device\r\n- `get_property_list(device_type_code, device_feature_code, access_token)`: Get device properties\r\n- `query_static_data(puid, access_token)`: Query static device data\r\n- `get_hour_power(date, puid, access_token)`: Get hourly power consumption\r\n- `get_self_check(no_record, puid, access_token)`: Get device self-check info\r\n\r\n## License\r\n\r\nMIT License\r\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "ConnectLife Cloud API client library for Home Assistant integrations",
    "version": "0.1.0",
    "project_urls": {
        "Homepage": "https://github.com/Connectlife-LLC/connectlife-cloud",
        "Issues": "https://github.com/Connectlife-LLC/connectlife-cloud/issues",
        "Repository": "https://github.com/Connectlife-LLC/connectlife-cloud"
    },
    "split_keywords": [
        "homeassistant",
        " connectlife",
        " api",
        " client",
        " iot"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "795413d30f1e8a1e2353bb2f80b5949455b14bd59984289cbef40ee762d74ad2",
                "md5": "0f8bedcf9a17d4373013e18f906c79d8",
                "sha256": "39d71126e5fdbe2bc1c4c965282c03231164f5bff8f454d0f3be5e4b92fd0845"
            },
            "downloads": -1,
            "filename": "connectlife_cloud-0.1.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "0f8bedcf9a17d4373013e18f906c79d8",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 10597,
            "upload_time": "2025-09-10T06:24:46",
            "upload_time_iso_8601": "2025-09-10T06:24:46.458818Z",
            "url": "https://files.pythonhosted.org/packages/79/54/13d30f1e8a1e2353bb2f80b5949455b14bd59984289cbef40ee762d74ad2/connectlife_cloud-0.1.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "74bfcca8e185f4de82987f15f55182b15fcfa9334226d86ae62ca1cbcd45bfbb",
                "md5": "a4dd21ba5abec0d68874b4b6b4f150b7",
                "sha256": "597c547266f96a3d7a18e588629686ffe76e45bf867e7b75f73051daa5518667"
            },
            "downloads": -1,
            "filename": "connectlife_cloud-0.1.0.tar.gz",
            "has_sig": false,
            "md5_digest": "a4dd21ba5abec0d68874b4b6b4f150b7",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 7475,
            "upload_time": "2025-09-10T06:24:47",
            "upload_time_iso_8601": "2025-09-10T06:24:47.781742Z",
            "url": "https://files.pythonhosted.org/packages/74/bf/cca8e185f4de82987f15f55182b15fcfa9334226d86ae62ca1cbcd45bfbb/connectlife_cloud-0.1.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-09-10 06:24:47",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "Connectlife-LLC",
    "github_project": "connectlife-cloud",
    "github_not_found": true,
    "lcname": "connectlife-cloud"
}
        
Elapsed time: 3.44026s