Skip to main content

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": "..."}

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


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

yap_torrent_web-0.1.0.tar.gz (8.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

yap_torrent_web-0.1.0-py3-none-any.whl (10.0 kB view details)

Uploaded Python 3

File details

Details for the file yap_torrent_web-0.1.0.tar.gz.

File metadata

  • Download URL: yap_torrent_web-0.1.0.tar.gz
  • Upload date:
  • Size: 8.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for yap_torrent_web-0.1.0.tar.gz
Algorithm Hash digest
SHA256 82221b97964a4c175f680869b7aaafc3c9226883659bd8c701e5ff1af01ed81c
MD5 ac25629a7709e21415398a9063c5ed27
BLAKE2b-256 d1eb89cbd57596e36fe31d8c2f96b8d5e58380d49165815fb251ed86c65014c5

See more details on using hashes here.

Provenance

The following attestation bundles were made for yap_torrent_web-0.1.0.tar.gz:

Publisher: python-publish-plugins-web.yml on Angel777d/yap_torrent

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file yap_torrent_web-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for yap_torrent_web-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 86a47f15b06a696216c7ac98416c0a91dabe6e973f469cae8db0330ebaa0d862
MD5 35bf5a61cf53818f7502d06697eff466
BLAKE2b-256 89239026a73b44df811fb1cae32d309fc3687ec3c9ec267d12a6b7c75bca05c6

See more details on using hashes here.

Provenance

The following attestation bundles were made for yap_torrent_web-0.1.0-py3-none-any.whl:

Publisher: python-publish-plugins-web.yml on Angel777d/yap_torrent

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page