Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatic Torrent Download API #159

Open
trymeouteh opened this issue Aug 9, 2024 · 0 comments
Open

Automatic Torrent Download API #159

trymeouteh opened this issue Aug 9, 2024 · 0 comments

Comments

@trymeouteh
Copy link

trymeouteh commented Aug 9, 2024

Many apps offer direct downloads inside of them, such as app stores like F-Droid, Scoop package manager to name a few. These apps could integrate P2P bittorrent downloads but will then need to build in a torrent client within these apps. To make adoption of P2P bittorrent for more things, include downloads from apps, allowing the user to install a bittorrent client on their choice and then having an API communicate between the app and bittorrent client to getting the bittorrent client to start downloading a file and to inform the app the progress of the download and when the download is complete.

The app using P2P torrent downloads will have to have a library that does the following...

  • Allow the user to generate a unique code which is copied and pasted into the bittorrent client settings. This code is designed to tell the bittorrent client that any download requests with this code are allowed to go through. This is a security measure to prevent malicious apps from telling the bittorrent client to start automatically downloading random files.
  • Be able to send a request to the installed bittorrent client to start a download. Essentially sending the magnet link of the torrent to the torrent client
  • Will be able to get the percentage of the download from the torrent client
  • Will be informed when the download is complete and the app can then proceed with the downloaded file
  • Can inform the bittorrent client to stop seeding and delete the torrent and will delete the file from the system

The bittorrent client will have to have the following, which means the bittorrent library will need to support the following...

  • A setting to insert unique codes into the client that come from the app in question. This code is designed to tell the bittorrent client that any download requests with this code are allowed to go through. This is a security measure to prevent malicious apps from telling the bittorrent client to start automatically downloading random files.
  • Be able to receive download requests from any app on the device and then proceed to start download the file without prompting the user on weather to download the file or not
  • Send the progress of the download to the app on the device
  • Inform the app on the device once the download is finished
  • Be able to receive request to stop seeding and delete the torrent and will delete the file from the system

The predefined directories will also be required for this to work for the bittorrent client to know where to download the files to on the system and to allow a standard in the magnet link and torrent files on a predefined directory.
#150

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant