um-pmag
um-pmag submits a magnet link to the premiumize transfer API, prints live
transfer progress, and opens um-pmdl when the transfer finishes so the new
content can be browsed and downloaded.
Setup
curlfor the transfer API calls.jqfor parsing the API responses.-
A credentials file
~/.config/premiumize/credscontaining one line: -
wl-paste(Wayland) orxclip(X11), only when no magnet link is passed as an argument.
The credentials line:
apikey=...
The key comes from the premiumize control panel, API section, key type
"api key". Keep the file readable only by you (chmod 600).
Usage
um-pmag "magnet:?xt=urn:btih:..." # explicit link
um-pmag # link from the clipboard
An argument always wins over the clipboard. A value that does not start with
magnet: is rejected before anything is sent.
Behavior
- The transfer is created first;
um-pmagthen polls the transfer list every two seconds and prints status, percentage and name on one line. - When the transfer finishes,
um-pmdlopens for browsing and downloading. - Exiting
um-pmagearly never cancels the transfer; it keeps running on the server. Re-runningum-pmagwith the same link creates a second transfer — use the premiumize web panel to remove duplicates.
Statuses
The progress line shows the API status verbatim: waiting while queued,
downloading with a percentage, finished on success, error on failure.