Convert Figma logo to code with AI

nathom logostreamrip

A scriptable music downloader for Qobuz, Tidal, SoundCloud, and Deezer

2,665
237
2,665
154

Top Related Projects

Download 'TIDAL' Music On Windows/Linux/MacOs (PYTHON/C#)

Download your Spotify playlists and songs along with album art and metadata (from YouTube if a match is found).

Quick Overview

Streamrip is a command-line tool for downloading music from various streaming services. It supports multiple platforms, including Qobuz, Tidal, Deezer, and SoundCloud, allowing users to download high-quality audio files and associated metadata.

Pros

  • Supports multiple streaming platforms in a single tool
  • Downloads high-quality audio files (up to lossless quality)
  • Includes metadata and cover art in downloads
  • Offers flexible configuration options for organizing downloads

Cons

  • Requires premium accounts for some streaming services
  • May raise legal and ethical concerns regarding music piracy
  • Command-line interface might be intimidating for less technical users
  • Depends on third-party APIs, which may change or become unavailable

Code Examples

# Initialize the Streamrip client
from streamrip import streamrip

client = streamrip.StreamripClient()

# Download a track by URL
client.download("https://www.deezer.com/track/3135556")
# Download an entire album
client.download("https://www.qobuz.com/us-en/album/nevermind-nirvana/5099962177023")
# Download multiple items with custom output format
client.download(
    ["https://tidal.com/browse/album/80216363", "https://soundcloud.com/user-123456789/track-title"],
    output_format="{artist}/{album}/{track_number} - {title}"
)

Getting Started

  1. Install Streamrip:

    pip install streamrip
    
  2. Configure your streaming service credentials:

    streamrip configure
    
  3. Download music:

    streamrip download <URL>
    

For more advanced usage and options, refer to the project's documentation on GitHub.

Competitor Comparisons

Download 'TIDAL' Music On Windows/Linux/MacOs (PYTHON/C#)

Pros of Tidal-Media-Downloader

  • Supports downloading videos from Tidal
  • Offers a graphical user interface (GUI) option
  • Provides more detailed download progress information

Cons of Tidal-Media-Downloader

  • Limited to Tidal platform only
  • Less frequent updates and maintenance
  • Lacks support for some advanced features like playlist conversion

Code Comparison

Streamrip (Python):

async def download_track(self, track: Track) -> None:
    stream_data = await self.client.get_stream_data(track.id)
    await self._download_track(track, stream_data)

Tidal-Media-Downloader (Python):

def downloadTrack(self, track, album=None, playlist=None):
    stream_info = self.getStreamInfo(track.id)
    path = self.getTrackPath(track, album, playlist)
    self.download_file(stream_info['url'], path)

Both projects use asynchronous programming for efficient downloads, but Streamrip's implementation appears more modular and potentially easier to extend. Tidal-Media-Downloader's code is more straightforward but may be less flexible for handling different scenarios.

Streamrip offers a more versatile solution with support for multiple streaming platforms, while Tidal-Media-Downloader focuses solely on Tidal. The choice between the two depends on the user's specific needs and preferred features.

Download your Spotify playlists and songs along with album art and metadata (from YouTube if a match is found).

Pros of spotify-downloader

  • Focuses specifically on Spotify, potentially offering more tailored features for that platform
  • Has a larger community and more contributors, which may lead to faster updates and bug fixes
  • Provides a web UI option for easier use by non-technical users

Cons of spotify-downloader

  • Limited to Spotify only, while streamrip supports multiple streaming services
  • May have slower download speeds compared to streamrip's multi-threaded approach
  • Less flexible in terms of audio format options and metadata customization

Code Comparison

spotify-downloader:

from spotdl import Spotdl

spotdl = Spotdl(client_id="your-client-id", client_secret="your-client-secret")
songs = spotdl.search(["song-link1", "song-link2"])
spotdl.download_songs(songs)

streamrip:

from streamrip import streamrip

rip = streamrip.StreamRipper()
rip.config.load_from_file()
rip.download("https://tidal.com/album/12345")

Both libraries offer straightforward APIs for downloading music, but streamrip's approach is more concise and supports multiple platforms out of the box. spotify-downloader requires separate authentication steps, while streamrip handles this internally through its configuration system.

Convert Figma logo designs to code with AI

Visual Copilot

Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.

Try Visual Copilot

README

streamrip logo

Downloads Code style: black

A scriptable stream downloader for Qobuz, Tidal, Deezer and SoundCloud.

downloading an album

Features

  • Fast, concurrent downloads powered by aiohttp
  • Downloads tracks, albums, playlists, discographies, and labels from Qobuz, Tidal, Deezer, and SoundCloud
  • Supports downloads of Spotify and Apple Music playlists through last.fm
  • Automatically converts files to a preferred format
  • Has a database that stores the downloaded tracks' IDs so that repeats are avoided
  • Concurrency and rate limiting
  • Interactive search for all sources
  • Highly customizable through the config file
  • Integration with youtube-dl

Installation

First, ensure Python (version 3.10 or greater) and pip are installed. Then install ffmpeg. You may choose not to install this, but some functionality will be limited.

pip3 install streamrip --upgrade

When you type

rip

it should show the main help page. If you have no idea what these mean, or are having other issues installing, check out the detailed installation instructions.

For Arch Linux users, an AUR package exists. Make sure to install required packages from the AUR before using makepkg or use an AUR helper to automatically resolve them.

git clone https://aur.archlinux.org/streamrip.git
cd streamrip
makepkg -si

or

paru -S streamrip

Streamrip beta

If you want to get access to the latest and greatest features without waiting for a new release, install from the dev branch with the following command

pip3 install git+https://github.com/nathom/streamrip.git@dev

Example Usage

For Tidal and Qobuz, you NEED a premium subscription.

Download an album from Qobuz

rip url https://www.qobuz.com/us-en/album/rumours-fleetwood-mac/0603497941032

Download multiple albums from Qobuz

rip url https://www.qobuz.com/us-en/album/back-in-black-ac-dc/0886444889841 https://www.qobuz.com/us-en/album/blue-train-john-coltrane/0060253764852

Download the album and convert it to mp3

rip --codec mp3 url https://open.qobuz.com/album/0060253780968

To set the maximum quality, use the --quality option to 0, 1, 2, 3, 4:

Quality IDAudio QualityAvailable Sources
0128 kbps MP3 or AACDeezer, Tidal, SoundCloud (most of the time)
1320 kbps MP3 or AACDeezer, Tidal, Qobuz, SoundCloud (rarely)
216 bit, 44.1 kHz (CD)Deezer, Tidal, Qobuz, SoundCloud (rarely)
324 bit, ≤ 96 kHzTidal (MQA), Qobuz, SoundCloud (rarely)
424 bit, ≤ 192 kHzQobuz
rip --quality 3 url https://tidal.com/browse/album/147569387

Using 4 is generally a waste of space. It is impossible for humans to perceive the difference between sampling rates higher than 44.1 kHz. It may be useful if you're processing/slowing down the audio.

Search for playlists matching rap on Tidal

rip search tidal playlist 'rap'

streamrip interactive search

Search for Rumours on Tidal, and download it

rip search tidal album 'fleetwood mac rumours'

Download a last.fm playlist using the lastfm command

rip lastfm https://www.last.fm/user/nathan3895/playlists/12126195

For more customization, see the config file

rip config open

If you're confused about anything, see the help pages. The main help pages can be accessed by typing rip by itself in the command line. The help pages for each command can be accessed with the --help flag. For example, to see the help page for the url command, type

rip url --help

example_help_page.png

Other information

For more in-depth information about streamrip, see the help pages and the wiki.

Contributions

All contributions are appreciated! You can help out the project by opening an issue or by submitting code.

Issues

If you're opening an issue use the Feature Request or Bug Report templates properly. This ensures that I have all of the information necessary to debug the issue. If you do not follow the templates, I will silently close the issue and you'll have to deal with it yourself.

Code

If you're new to Git, follow these steps to open your first Pull Request (PR):

  • Fork this repository
  • Clone the new repository
  • Commit your changes
  • Open a pull request to the dev branch

Please document any functions or obscure lines of code.

The Wiki

To help out streamrip users that may be having trouble, consider contributing some information to the wiki. Nothing is too obvious and everything is appreciated.

Acknowledgements

Thanks to Vitiko98, Sorrow446, and DashLt for their contributions to this project, and the previous projects that made this one possible.

streamrip was inspired by:

Disclaimer

I will not be responsible for how you use streamrip. By using streamrip, you agree to the terms and conditions of the Qobuz, Tidal, and Deezer APIs.

Sponsorship

Consider becoming a Github sponsor for me if you enjoy my open source software.