localsend / localsend/protocol

Proposal: Default to Resumable Download Endpoint

Open
#31 1 comment 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Mermaid
Stars
571
Forks
42
PR merge metrics
No merged PRs in 30d

Description

Hi,
I saw that over on the LocalSend GitHub repository some protocol version 3 stuff is being uploaded. I haven’t looked at it in detail yet, but here are some changes I propose:

Download Endpoint
I propose changing the default behavior from upload to download instead.

Endpoint

GET /api/localsend/v3/download/{session_id}/{file_id}/
Authorization: Bearer <token>

Problems with POST-based uploads:

  • Large requests can trigger server or proxy timeouts.
  • Some servers buffer the whole body in memory -> Out-Of-Memory risk
  • Resuming uploads is hard without a resumable protocol.

Benefits:

  • Native Range/Content-Range support -> easy resumable downloads.
  • Client-driven retries/resume - simpler recovery after connection loss.
  • Server can stream from disk - lower memory use.
  • Works with many existing tools/libraries (curl, aria2, OkHttp, NSURLSession, requests).

The existing upload-to-receiver can remain as a fallback.

We could also consider supporting the TUS protocol (open-source protocol for resumable uploads using HTTP): https://tus.io/

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the LocalSend protocol v3 material and the existing upload-to-receiver behavior described in this issue. Define the download endpoint, resumable transfer behavior, authentication, and fallback semantics, then verify the protocol proposal against the listed client and server use cases.

Written by the indexing model from the issue text.

Assessment

Domain
api, backend-api-design
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.