Asynchronous Python client for Unmanic.
Project description
Unmanic-API
Asynchronous Python client for Unmanic.
Please note that not all features of the v2 API have been implemented, rather a few key endpoints that most users should find useful for automation.
Installing
pip install unmanic-api
Quick-Start Example
"""
Pause resume example.
Connect to Unmanic instance, pause worker "W0", wait 5 seconds and resume worker "W0".
"""
import asyncio
from unmanic_api import Unmanic
async def main():
async with Unmanic('localhost') as unmanic:
print(await unmanic.pause_worker("W0"))
await asyncio.sleep(5)
print(await unmanic.resume_worker("W0"))
if __name__ == "__main__":
loop = asyncio.get_event_loop()
loop.run_until_complete(main())
See Also
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
unmanic_api-0.0.5.tar.gz
(20.1 kB
view hashes)
Built Distribution
Close
Hashes for unmanic_api-0.0.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | deff27081d5a23cd38c72d3f7adba8efc07febc156b96d28c1217b87898eaa72 |
|
MD5 | fe6fe8459ef89d3c971e2f1f97c44cdf |
|
BLAKE2b-256 | 7a4cf2a52a306fb33ba719301560c268c606b039336bfb30cecc53f3d4073b5c |