https://github.com/schnatterer/dsdl
DiskStation DownLoader - gets files from Synology DiskStation Manager
https://github.com/schnatterer/dsdl
audio-station diskstation dsaudio dsm dsphoto photo-station photostation synology synology-api synology-disk-station synology-dsm-api synology-nas synology-photos termux
Last synced: 2 months ago
JSON representation
DiskStation DownLoader - gets files from Synology DiskStation Manager
- Host: GitHub
- URL: https://github.com/schnatterer/dsdl
- Owner: schnatterer
- License: mit
- Created: 2018-04-25T22:40:14.000Z (about 7 years ago)
- Default Branch: main
- Last Pushed: 2023-07-12T19:18:54.000Z (almost 2 years ago)
- Last Synced: 2025-03-11T04:39:55.714Z (3 months ago)
- Topics: audio-station, diskstation, dsaudio, dsm, dsphoto, photo-station, photostation, synology, synology-api, synology-disk-station, synology-dsm-api, synology-nas, synology-photos, termux
- Language: JavaScript
- Homepage:
- Size: 1.54 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
dsdl
====[](https://github.com/schnatterer/dsdl/actions/workflows/build.yaml)
[](https://www.npmjs.org/package/dsdl)
[](https://sonarcloud.io/dashboard?id=info.schnatterer.dsdl)
[](https://sonarcloud.io/dashboard?id=info.schnatterer.dsdl)
[](https://sonarcloud.io/dashboard?id=info.schnatterer.dsdl)DiskStation Downloader (formerly photostationtagdownloader / pstd)
Downloads files from [Synology DiskStation Manager](https://www.synology.com/dsm). Supports downloading
* photos (all photos of a tag / "smart album") via [Synology Photos](https://www.synology.com/dsm/feature/photos) / [Photo Station](https://www.synology.com/dsm/feature/photo_station) and
* audio (all songs of a playlist) via [Audio Station](https://www.synology.com/dsm/feature/audio_station)# Table of contents
- [Features](#features)
- [Photos](#photos)
- [Audio](#audio)
- [Installation](#installation)
- [npm](#npm)
- [Prebuilt binaries](#prebuilt-binaries)
- [Docker](#docker)
- [Clone repo](#clone-repo)
- [Usage](#usage)
- [General parameters](#general-parameters)
- [DS Audio](#ds-audio)
- [Synology Photos](#synology-photos)
- [DS Photo](#ds-photo)
- [Non-interactive password](#non-interactive-password)# Features
## Photos
* Set tags (i.e. [IPTC keywords](http://www.iptc.org/std/photometadata/documentation/userguide/index.htm#!Documents/generalimagecontent.htm)) 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](https://www.synology.com/dsm/feature/audio_station#download) but it does not seem to work reliably, and it cannot be scripted 😉# Installation
## npm
You can install it as global package [from npm](https://www.npmjs.com/package/dsdl)
```shell
npm install -g dsdldsdl --version
```Note that, ff running on android via [termux](https://termux.com/) and want to trigger dsdl from a termux widget,
you need to perform the following once after installation/upgrade:```shell
termux-fix-shebang $(which dsdl)
```## Prebuilt binaries
Get the binary for your specific OS from the [release page](https://github.com/schnatterer/dsdl/releases).
```bash
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/dsdldsdl --version
```## Docker
[See quay.io](https://quay.io/repository/schnatterer/dsdl)
```bash
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.
```bash
git clone https://github.com/schnatterer/dsdl && cd dsdl
yarn installnode src/cli/dsdl.js photo --version
```# Usage
* DS Audio
```shell
dsdl audio --user your-user --output music/ http://diskstation:5000/
```
* Synology Photos (DSM 7+) -
```shell
dsdl photos --user your-user --output music/ http://diskstation:5000/
```
* DS Photo (DSM < 7)
```shell
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.```bash
echo "PW" | dsdl photo -u ...
```