dsdl

3.1.0 • Public • Published

dsdl

Build Status QGate Coverage TecDebt

DiskStation Downloader (formerly photostationtagdownloader / pstd)

Downloads files from Synology DiskStation Manager. Supports downloading

Table of contents

Features

Photos

  • Set tags (i.e. IPTC keywords) for photos, grouping them into "smart albums" (DS photo)
  • dsdl downloads those for you. For some reasons this cannot be achieved using the Photo Station web app, nor native Android or Windows apps.

Audio

  • Group your songs into playlists
  • dsdl downloads those for you. You can also do this via the web UI (where the playlist is zipped) or with DS audio but it does not seem to work reliably, and it cannot be scripted 😉

Installation

npm

You can install it as global package from npm

npm install -g dsdl

dsdl --version

Note that, ff running on android via termux and want to trigger dsdl from a termux widget, you need to perform the following once after installation/upgrade:

termux-fix-shebang $(which dsdl)

Prebuilt binaries

Get the binary for your specific OS from the release page.

DSDL_VERSION=2.00
sudo wget -O /usr/local/bin dsdl \
  https://github.com/schnatterer/dsdl/releases/download/${DSDL_VERSION}/dsdl-linux-x64
sudo chmod +x /usr/local/bin/dsdl

dsdl --version

Docker

See quay.io

docker run --rm -ti -v $(pwd):/dsdl quay.io/schnatterer/dsdl \
  audio --user your-photostation-user --output /dsdl http://diskstation/photo

Make sure uid/gid 1000 are allowed to write into current folder.

Clone repo

Of course, you can also run the latest version by cloning this repo.

git clone https://github.com/schnatterer/dsdl && cd dsdl
yarn install

node src/cli/dsdl.js photo --version

Usage

  • DS Audio
dsdl audio --user your-user --output music/ http://diskstation:5000/
  • Synology Photos (DSM 7+) -
dsdl photos --user your-user --output music/ http://diskstation:5000/
  • DS Photo (DSM < 7)
dsdl photo --user your-diskstsation-user --output photos/ http://diskstation/photo

You will be prompted for the password.

General parameters

  • --folder-structure
    • Default: list - creates subdirs for each list.
    • flat - writes all photos to a single folders.
    • server - creates same folder structure as on server (Works only for audio).
      Or is there a way to get the album for a photo via the Synology Photo Station / Foto API?

DS Audio

  • --playlists - downloads specific playlists. Note that playlists containing spaces must be quoted. Multiple playlists can either be specified
    • comma separated (e.g. --playlists "tag one",numberTwo) or
    • by using multiple parameters (e.g --playlists "tag one" --playlists numberTwo)
  • --m3u - Create m3u playlist files for each downloaded playlist

Synology Photos

Note that for synology photos right now a maximum of 5000 photos can be downloaded for a single tag

  • --tags - downloads specific tags. Note that tags containing spaces must be quoted. Multiple tags can either be specified
    • comma separated (e.g. --tags "tag one",numberTwo) or
    • by using multiple parameters (e.g --tags "tag one" --tags numberTwo)

DS Photo

  • --tags - downloads specific tags. Note that tags containing spaces must be quoted. Multiple tags can either be specified
    • comma separated (e.g. --tags "tag one",numberTwo) or
    • by using multiple parameters (e.g --tags "tag one" --tags numberTwo)

Non-interactive password

If running in batch/non-interactive/headless mode, you you can just pipe it to dsdl. Note that passwords showing up in the shell history or log files are a potential security risk.

echo "PW" | dsdl photo -u ...

Readme

Keywords

none

Package Sidebar

Install

npm i dsdl

Weekly Downloads

4

Version

3.1.0

License

MIT

Unpacked Size

32.3 kB

Total Files

9

Last publish

Collaborators

  • schnatterer