1.1.2 • Published 11 months ago

spotify-dl v1.1.2

Weekly downloads
148
License
ISC
Repository
github
Last release
11 months ago

Spotify Downloader

 

Required

Get FFMPEG

(Node.js 14)https://nodejs.org/en/download/package-manager/

Note: if you run into issues related to puppeteer chromium download please try PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true npm install -g spotify-dl

spotifydl

A simple commandline utility that allows you to download Spotify Songs, Shows, Episodes, Playlists and Albums from Youtube.

PLEASE NOTE:

  • The ability to find a video is dependent on the fact it is hosted on youtube, and even then there is a chance it is still incorrectly matched
  • Some items may only be available to spotify premium users, please be sure to provide a username and password when this is the case

Installation

NPM

Install from npm registry

npm install -g spotify-dl

or You can do manually

git clone https://github.com/SwapnilSoni1999/spotify-dl
cd spotify-dl
npm install
npm link

Android (Termux)

PS: You may need to type termux-setup-storage first and allow storage permission

sh -c "$(curl -fsSL https://raw.githubusercontent.com/SwapnilSoni1999/spotify-dl/master/tools/termux.sh)"

Docker

Build docker image:

git clone https://github.com/SwapnilSoni1999/spotify-dl
cd spotify-dl
docker build -t spotify-dl .

Usage

To download highest quality audio file

spotifydl <spotify track/album/playlist link> ...

 

Example

$ spotifydl https://open.spotify.com/track/xyz

Options

FlagLong FlagUsage
--o--outputtakes valid output path argument
--es--extra-searchtakes extra search string/term to be used for youtube search
--oo--output-onlyenforces all downloaded songs in the output dir
--sf--search-formatprovide template for youtube api, supports albumName, artistName,itemName
"something {itemName} - {albumName} anyrandomextrastring"
--ef--exclusion-filterscomma separated string of exclusion filters
each filter will be checked against the description and title if found the link will be ignored
--st--saved-tracksdownload spotify saved tracks
--ss--saved-songsdownload spotify saved shows
--sp--saved-playlistsdownload spotify saved playlists
--sa--saved-albumsdownload spotify saved albums
--l--loginRequests a login in an external window (non tty should use --u and --p) (Docker without -it is non tty)
--u--usernamespotify username for headless long (Note: you must use --login once to grant access)
--p--passwordspotify password
--cf--cache-filetakes valid output file name path argument
--dr--download-reportoutput a download report of what files failed
--cof--cookie-filetakes valid file name path argument to a txt file for youtube cookies
--v--versionreturns current version
--h--helpoutputs help text
--dl--download-lyricsenables downloading of lyrics

Notes

To use --u and --p (headless login) you must do a --l once first to grant required permissions (playlists, saved songs ect.)

if you receive 'Got a spotify api error WebapiRegularError: An error occurred while communicating with Spotify's Web API Details: non existing id' you may need to provide auth either use --l for manual login prompt or --u username --p password for headless login

If you receive a 429 error please provide a cookies file given the --cof flag, to generate a cookies file please refer to Chrome or Firefox

Docker

docker run -it --user=$(id -u):$(id -g) -v $(pwd):/download --rm spotify-dl <options-to-spotify-dl defaults to --help>
docker run -it --user=$(id -u):$(id -g) -v $(pwd):/download --rm spotify-dl "https://open.spotify.com/...."

Acknowledgements

thanks to icons8 for icons in hero image and all the contributors for PR, suggestions and testing :love:

 

License

MIT © Swapnil Soni

1.1.2

11 months ago

1.1.0

1 year ago

1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago

0.5.2

3 years ago

0.5.0

3 years ago

0.4.9

3 years ago

0.4.8

3 years ago

0.4.7

3 years ago

0.4.6

3 years ago

0.4.5

3 years ago

0.4.4

4 years ago

0.4.3

4 years ago

0.4.1

4 years ago

0.4.2

4 years ago

0.4.0

4 years ago

0.3.1

4 years ago

0.3.0

4 years ago

0.2.1

4 years ago

0.2.2

4 years ago

0.2.0

4 years ago

0.1.8

4 years ago

0.1.7

4 years ago

0.1.6

4 years ago

0.1.4

4 years ago

0.1.3

5 years ago

0.1.2

5 years ago

0.1.1

5 years ago

0.1.0

5 years ago

0.0.9

5 years ago

0.0.8

5 years ago

0.0.7

5 years ago

0.0.6

5 years ago