Web interface for yap torrent
Project description
YAP Torrent Web Interface Plugin
A web interface plugin for YAP Torrent built with aiohttp.
Features
- Web server using aiohttp
- Web dashboard with status and torrent information
- Selectable torrent list with click-to-select functionality
- Torrent control actions (start, stop, invalidate, remove, DHT peer discovery)
- RESTful API endpoints
- Auto-refresh functionality
- Separate HTML/CSS/JS files for easy customization
Installation
pip install yap_torrent_web
Usage
The plugin starts automatically when loaded. By default, it runs on http://0.0.0.0:8080.
Access the web interface at: http://localhost:8080
Web Interface
Status Section
- Displays current status: peer ID, IP, external IP
- Refresh button to update status
Torrents Section
- Click on any torrent to select it
- Control buttons apply to the selected torrent:
- Start – Start the selected torrent
- Stop – Stop the selected torrent
- Invalidate – Invalidate torrent data
- Remove – Remove the selected torrent
- DHT Ask Peers – Request peers via DHT
API Endpoints
GET Endpoints
GET /- Web dashboard (HTML interface)GET /api/status- Get current status (JSON)GET /api/torrents- Get list of torrents (JSON)GET /static/*- Static files (CSS, JS)
POST Endpoints
POST /api/torrent/action- Execute torrent action- Body:
{"action": "start|stop|invalidate|remove|dht_ask_peers", "hash": "torrent_hash"} - Returns:
{"success": true, "action": "...", "hash": "..."}
- Body:
Configuration
The server host and port can be configured by modifying the WebServer initialization in __init__.py:
self.server = WebServer(env, host='0.0.0.0', port=8080)
File Structure
plugins/web_interface/
├── src/yap_torrent_web_interface/
│ ├── __init__.py # Plugin initialization
│ ├── server.py # Web server implementation
│ └── static/ # Static web files
│ ├── index.html # Main HTML page
│ ├── style.css # Styles
│ └── app.js # JavaScript logic
├── pyproject.toml
├── README.md
└── LICENSE
Dependencies
- aiohttp - HTTP server and client library
- yap_torrent - Core torrent functionality
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file yap_torrent_web-0.0.2.tar.gz.
File metadata
- Download URL: yap_torrent_web-0.0.2.tar.gz
- Upload date:
- Size: 7.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a9fba73cd48f3e32382f1f9f0faead298bf18ae0e2e22c94dd49449d7e68657a
|
|
| MD5 |
e6751f1f5debea064f8e895920dcd86b
|
|
| BLAKE2b-256 |
16a118b13f13f7406719553a168a4c1c0da4f80ac35362dfe8c5c2b40453803e
|
Provenance
The following attestation bundles were made for yap_torrent_web-0.0.2.tar.gz:
Publisher:
python-publish-plugins-web.yml on Angel777d/yap_torrent
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
yap_torrent_web-0.0.2.tar.gz -
Subject digest:
a9fba73cd48f3e32382f1f9f0faead298bf18ae0e2e22c94dd49449d7e68657a - Sigstore transparency entry: 953198230
- Sigstore integration time:
-
Permalink:
Angel777d/yap_torrent@748a8241849545e5ac3662e26fc0ee45550f7f87 -
Branch / Tag:
refs/tags/plugins-web-v.0.0.2 - Owner: https://github.com/Angel777d
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish-plugins-web.yml@748a8241849545e5ac3662e26fc0ee45550f7f87 -
Trigger Event:
push
-
Statement type:
File details
Details for the file yap_torrent_web-0.0.2-py3-none-any.whl.
File metadata
- Download URL: yap_torrent_web-0.0.2-py3-none-any.whl
- Upload date:
- Size: 10.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
81bced5904c6df19a9340b022a1179927699aeb2ddca81503e51f02765b95d2f
|
|
| MD5 |
2f737ed07b61b1050f8cdf231fb6f7d7
|
|
| BLAKE2b-256 |
1ce47e67adfae9234d27a8fd9549150641fb395f4950cad64010369b60be876a
|
Provenance
The following attestation bundles were made for yap_torrent_web-0.0.2-py3-none-any.whl:
Publisher:
python-publish-plugins-web.yml on Angel777d/yap_torrent
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
yap_torrent_web-0.0.2-py3-none-any.whl -
Subject digest:
81bced5904c6df19a9340b022a1179927699aeb2ddca81503e51f02765b95d2f - Sigstore transparency entry: 953198231
- Sigstore integration time:
-
Permalink:
Angel777d/yap_torrent@748a8241849545e5ac3662e26fc0ee45550f7f87 -
Branch / Tag:
refs/tags/plugins-web-v.0.0.2 - Owner: https://github.com/Angel777d
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish-plugins-web.yml@748a8241849545e5ac3662e26fc0ee45550f7f87 -
Trigger Event:
push
-
Statement type: