Skip to content

Commit f6e1540

Browse files
committed
Enhance README with usage examples and installation instructions
1 parent 7dfd6c9 commit f6e1540

File tree

1 file changed

+94
-5
lines changed

1 file changed

+94
-5
lines changed

README.md

+94-5
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,108 @@
11
# PyLoadAPI
22

3-
<p align="center">
4-
<em>Simple wrapper for pyLoad's API.</em>
5-
</p>
3+
*Simple wrapper for pyLoad's API.*
4+
5+
This module provides a simplified interface (PyLoadAPI class) to interact with
6+
pyLoad's API using aiohttp for asynchronous HTTP requests. It handles login
7+
authentication and provides methods to perform various operations such as
8+
pausing downloads, restarting pyLoad, retrieving status information, and more.
69

710
[![build](https://github.com/tr4nt0r/pyloadapi/workflows/Build/badge.svg)](https://github.com/tr4nt0r/pyloadapi/actions)
811
[![codecov](https://codecov.io/gh/tr4nt0r/pyloadapi/graph/badge.svg?token=SZDBSZGZE7)](https://codecov.io/gh/tr4nt0r/pyloadapi)
912
[![PyPI version](https://badge.fury.io/py/PyLoadAPI.svg)](https://badge.fury.io/py/PyLoadAPI)
1013
[!["Buy Me A Coffee"](https://img.shields.io/badge/-buy_me_a%C2%A0coffee-gray?logo=buy-me-a-coffee)](https://www.buymeacoffee.com/tr4nt0r)
14+
[![GitHub Sponsor](https://img.shields.io/badge/GitHub-Sponsor-blue?logo=github)](https://github.com/sponsors/tr4nt0r)
15+
16+
---
17+
18+
## 📖 Documentation
19+
20+
- **Full Documentation**: [https://tr4nt0r.github.io/pyloadapi](https://tr4nt0r.github.io/pyloadapi)
21+
- **Source Code**: [https://github.com/tr4nt0r/pyloadapi](https://github.com/tr4nt0r/pyloadapi)
22+
23+
---
24+
25+
## 📦 Installation
26+
27+
You can install PyLoadAPI via pip:
28+
29+
```sh
30+
pip install PyLoadAPI
31+
```
32+
33+
---
34+
35+
## 🚀 Usage
36+
37+
### Basic Example
38+
39+
```python
40+
import asyncio
41+
from pyloadapi import PyLoadAPI
42+
43+
async def main():
44+
async with PyLoadAPI("http://localhost:8000", "username", "password") as api:
45+
status = await api.status()
46+
print(status)
47+
48+
asyncio.run(main())
49+
```
50+
51+
### More Examples
52+
53+
<details>
1154

55+
<summary>Pause Downloads</summary>
56+
57+
```python
58+
await api.pause(True) # Pause all downloads
59+
```
60+
61+
</details>
62+
63+
<details>
64+
65+
<summary>Resume Downloads</summary>
66+
67+
```python
68+
await api.pause(False) # Resume all downloads
69+
```
70+
71+
</details>
72+
73+
<details>
74+
75+
<summary>Restart pyLoad</summary>
76+
77+
```python
78+
await api.restart()
79+
```
80+
81+
</details>
82+
83+
For more advanced usage, refer to the [documentation](https://tr4nt0r.github.io/pyloadapi).
1284

1385
---
1486

15-
**Documentation**: <a href="https://tr4nt0r.github.io/pyloadapi" target="_blank">https://tr4nt0r.github.io/pyloadapi</a>
87+
## 🛠 Contributing
88+
89+
Contributions are welcome! To contribute:
90+
91+
1. Fork the repository.
92+
2. Create a new branch.
93+
3. Make your changes and commit them.
94+
4. Submit a pull request.
1695

17-
**Source Code**: <a href="https://github.com/tr4nt0r/pyloadapi" target="_blank">https://github.com/tr4nt0r/pyloadapi</a>
96+
Make sure to follow the [contributing guidelines](CONTRIBUTING.md).
1897

1998
---
99+
100+
## 📜 License
101+
102+
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
103+
104+
---
105+
106+
## ❤️ Support
107+
108+
If you find this project useful, consider [buying me a coffee ☕](https://www.buymeacoffee.com/tr4nt0r) or [sponsoring me on GitHub](https://github.com/sponsors/tr4nt0r)!

0 commit comments

Comments
 (0)