shrupl/notes.md

1.8 KiB

Outline of sharry upload API

  1. POST to "new" route

  2. POST to "tus" route

  3. (multi) PATCH to "$patch_uri"

    • hdr: Sharry-Alias, Sharry-File-Length, Sharry-File-Name, Sharry-File-Type, Tus-Resumable
    • hdr: Upload-Offset: 10485760 * (n-1) for nth chunk
    • body: up to 10 MiB of binary data
    • res.status == 204
    • better use res_hdr.Upload-Offset
  4. (opt) POST to "notify" route

Links

Ideas

  • cli functions

    • "continue" and "new" flags to avoid user interaction
    • "quiet" flag to disable output entirely
    • some switch to change log to "pretty-print"
  • hashing

    • store file hashes with all file::* variants
    • check hashes on "continue"