Expand description
RustifyDL library API
High-level helpers to resolve Spotify URLs to tracks, fetch audio from YouTube, and write clean tags to files.
Key items:
DownloadOptions
input optionsdownload_spotify
to drive the whole flow asynchronously
Examples
use rustifydl::{download_spotify, DownloadOptions};
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error + Send + Sync>> {
let opts = DownloadOptions {
url: "https://open.spotify.com/album/xxxxxxxx".into(),
client_id: "<client_id>".into(),
client_secret: "<client_secret>".into(),
output_dir: "./output".into(),
concurrent_downloads: 6,
no_dupes: true,
bitrate: "192k".into(),
format: "mp3".into(),
verbosity: "info".into(),
no_tag: false,
timeout: 180,
};
download_spotify(opts).await
}
Modules§
- metadata
- Metadata tagging utilities for RustifyDL.
- spotify
- Spotify helpers for resolving tracks, albums, and playlists.
- youtube
- YouTube search and download helpers.
Structs§
- Download
Options - Options used to control how downloads are performed.
Functions§
- download_
spotify - Resolve a Spotify URL and download all corresponding tracks.
- extract_
id_ from_ url - Extract a Spotify ID from a typical Spotify URL.