# shellypy2
not to be confused with [pyShelly](https://github.com/StyraHem/pyShelly)
Python 3 Wrapper around the Shelly HTTP api forked from the
original [ShellyPy](https://pypi.org/project/ShellyPy/) project
that seems to be dead or at least sleeping at the moment.
## why
other packages like [pyShelly](https://github.com/StyraHem/pyShelly)
only support CoAP or MSQT, neither I am comfortable using in personal projects
## examples
#### relay
a simple working example for the Shelly 1 that turns a relay on
```python
import shellypy
device = shellypy.Shelly("192.168.0.5")
device.relay(0, turn=True)
```
[examples/toggle_relay.py](examples/toggle_relay.py)
#### monitor
a simple working example for the Shelly 1 that request monitor information
```python
import shellypy
device = shellypy.Shelly("192.168.68.121")
deviceMeter = device.meter(0) # request meter information
print(deviceMeter['power']) # print power information
print(deviceMeter['total']) # print total information
```
other examples are available as well [examples/meter.py](examples/meter.py)
## devices
#### supported
- Shelly1
- Shelly1PM
- Shelly2
- Shelly2PM
- Shelly2.5
- Shelly4Pro (untested)
- Shelly Plug (untested)
- Shelly PlugS
- Shelly Bulb (untested)
- Shelly H&T (Gen 1 and Gen 3)
- Shelly Smoke (untested)
- Shelly EM (untested)
- Shelly flood (untested)
#### unsupported
- Shelly Sense (documentation is inaccurate, incomplete)
- Shelly RGBW (documentation is incomplete)
## applicability
this wrapper is best used in closed networks where other solutions are either
not an option or not desired give your shelly devices static IP adresses for
best results
## license
this project is licensed under the [MIT License](LICENSE)
feel free to do whatever you want with it
Raw data
{
"_id": null,
"home_page": "https://github.com/SeRoWo83/ShellyPy",
"name": "shellypy2",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.10",
"maintainer_email": null,
"keywords": null,
"author": "Sebastian Wolf",
"author_email": "sebastian.wolf@pace-systems.de",
"download_url": "https://files.pythonhosted.org/packages/47/e6/0ee7fccffa13fca6a0f714aabfad229f3caeffaeedae7cdcdcc530317917/shellypy2-0.4.0.3.tar.gz",
"platform": null,
"description": "# shellypy2\r\nnot to be confused with [pyShelly](https://github.com/StyraHem/pyShelly) \r\nPython 3 Wrapper around the Shelly HTTP api forked from the \r\noriginal [ShellyPy](https://pypi.org/project/ShellyPy/) project \r\nthat seems to be dead or at least sleeping at the moment.\r\n\r\n\r\n## why\r\nother packages like [pyShelly](https://github.com/StyraHem/pyShelly) \r\nonly support CoAP or MSQT, neither I am comfortable using in personal projects\r\n\r\n\r\n## examples\r\n#### relay\r\na simple working example for the Shelly 1 that turns a relay on\r\n\r\n```python\r\nimport shellypy\r\n\r\ndevice = shellypy.Shelly(\"192.168.0.5\")\r\n\r\ndevice.relay(0, turn=True)\r\n```\r\n[examples/toggle_relay.py](examples/toggle_relay.py)\r\n\r\n#### monitor\r\na simple working example for the Shelly 1 that request monitor information\r\n\r\n```python\r\nimport shellypy\r\n\r\ndevice = shellypy.Shelly(\"192.168.68.121\")\r\n\r\ndeviceMeter = device.meter(0) # request meter information\r\nprint(deviceMeter['power']) # print power information\r\nprint(deviceMeter['total']) # print total information\r\n```\r\nother examples are available as well [examples/meter.py](examples/meter.py)\r\n\r\n## devices\r\n#### supported\r\n- Shelly1\r\n- Shelly1PM\r\n- Shelly2\r\n- Shelly2PM\r\n- Shelly2.5\r\n- Shelly4Pro (untested)\r\n- Shelly Plug (untested)\r\n- Shelly PlugS\r\n- Shelly Bulb (untested)\r\n- Shelly H&T (Gen 1 and Gen 3)\r\n- Shelly Smoke (untested)\r\n- Shelly EM (untested)\r\n- Shelly flood (untested)\r\n\r\n#### unsupported\r\n- Shelly Sense (documentation is inaccurate, incomplete)\r\n- Shelly RGBW (documentation is incomplete)\r\n\r\n## applicability\r\nthis wrapper is best used in closed networks where other solutions are either \r\nnot an option or not desired give your shelly devices static IP adresses for \r\nbest results\r\n\r\n\r\n## license\r\nthis project is licensed under the [MIT License](LICENSE) \r\nfeel free to do whatever you want with it\r\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Wrapper around the Shelly HTTP api forked from shellypy",
"version": "0.4.0.3",
"project_urls": {
"Homepage": "https://github.com/SeRoWo83/ShellyPy"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "47e60ee7fccffa13fca6a0f714aabfad229f3caeffaeedae7cdcdcc530317917",
"md5": "75069cfef71f90ec0daad6c1ba93d92e",
"sha256": "d219a55acac65703805992e0364849f69d56df1f7807eb67f8d2c44ff8fad89d"
},
"downloads": -1,
"filename": "shellypy2-0.4.0.3.tar.gz",
"has_sig": false,
"md5_digest": "75069cfef71f90ec0daad6c1ba93d92e",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.10",
"size": 8831,
"upload_time": "2024-10-13T17:35:03",
"upload_time_iso_8601": "2024-10-13T17:35:03.984605Z",
"url": "https://files.pythonhosted.org/packages/47/e6/0ee7fccffa13fca6a0f714aabfad229f3caeffaeedae7cdcdcc530317917/shellypy2-0.4.0.3.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-10-13 17:35:03",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "SeRoWo83",
"github_project": "ShellyPy",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"requirements": [],
"lcname": "shellypy2"
}