A command-line app for downloading songs, podcasts and videos from Spotify with smart environment management.
Project description
๐ต Dotify - Spotify Music Downloader
A powerful, self-aware CLI tool for downloading songs, podcasts, and videos from Spotify
Installation โข Quick Start โข Features โข Documentation
โจ Features
๐ง Content Support
- ๐ต Songs - Download in AAC 128kbps or AAC 256kbps (Premium)
- ๐ป Podcasts - Download in Vorbis or AAC format
- ๐ฌ Videos - Download music videos and podcast videos (Premium)
- ๐ Lyrics - Download synced lyrics in
.lrcformat - ๐จโ๐ค Artists - Download entire discographies
- ๐ Playlists - Download complete playlists with metadata
๐ ๏ธ Smart Environment Management
- ๐ง Auto Setup - One-command environment preparation
- ๐ฉบ Health Checks - Comprehensive system diagnostics
- ๐ Error Detection - Clear, actionable error messages
- ๐ Configuration - Automated config file management
- ๐ฏ Preflight Validation - Checks before every operation
๐จ Advanced Features
- ๐ท๏ธ Metadata - Complete tag preservation and customization
- ๐ Organization - Flexible folder/file naming templates
- โก Performance - Multiple download modes (ytdlp, aria2c)
- ๐ Remuxing - Support for FFmpeg, MP4Box, mp4decrypt
- ๐ Quality Control - Multiple audio quality options
๐ Quick Start
Prerequisites
- Python 3.10+ installed
- FFmpeg in system PATH
- Spotify cookies (Netscape format)
- Widevine key (
.wvdfile) for AAC decryption
Installation
# Install Dotify
pip install dotify-cli
# Run automatic setup
dotify env setup
# Verify your environment
dotify env doctor
First-Time Setup
# 1. Create placeholder files for reference
dotify env setup --create-placeholders
# 2. Get your Spotify cookies
# - Install "Get cookies.txt LOCALLY" extension
# - Go to open.spotify.com and log in
# - Export cookies to ~/.dotify/cookies.txt
# 3. Get your Widevine key (for AAC decryption)
# - Use KeyDive on an Android device
# - Extract device.wvd
# - Place it in ~/.dotify/keys/device.wvd
# 4. Verify everything is ready
dotify env doctor
Download Your First Track
# Download a single track
dotify "https://open.spotify.com/track/18gqCQzqYb0zvurQPlRkpo"
# Download an entire album
dotify "https://open.spotify.com/album/0r8D5N674HbTXlR3zNxeU1"
# Download a playlist
dotify "https://open.spotify.com/playlist/37i9dQZF1DXcBWIGoYBM5M"
๐ Environment Commands
Dotify includes powerful environment management tools:
๐ง Setup
dotify env setup
Automatically creates:
- Configuration directory (
~/.dotify/) - Keys directory (
~/.dotify/keys/) - Temp directory (
~/.dotify/temp/) - Logs directory (
~/.dotify/logs/) - Default configuration file
Options:
--create-placeholders- Create example files for cookies and WVD
๐ฉบ Doctor
dotify env doctor
Comprehensive health check that verifies:
- โ Configuration directory
- โ Cookies file
- โ Widevine key
- โ FFmpeg installation
- โ Python version
- โ Optional dependencies
Options:
--verbose- Show detailed output including optional checks--json- Output results in JSON format
๐ Paths
dotify env paths
Displays all Dotify-related paths:
- Config directory and file
- Keys directory
- Default cookies and WVD paths
- Temp and logs directories
- Database file location
๐ Check
dotify env check [check_name]
Run specific health checks:
config- Configuration directorycookies- Cookies filewvd- Widevine keyffmpeg- FFmpeg installationpython- Python version
๐ฏ Usage Examples
Basic Downloads
# Download a song
dotify "https://open.spotify.com/track/..."
# Download an album
dotify "https://open.spotify.com/album/..."
# Download a playlist
dotify "https://open.spotify.com/playlist/..."
# Download an artist's discography
dotify "https://open.spotify.com/artist/..."
Advanced Options
# Download with custom quality
dotify "URL" --audio-quality aac-high
# Download to specific directory
dotify "URL" --output "/path/to/music"
# Download with custom template
dotify "URL" --album-folder-template "{artist}/{album} - {year}"
# Download only lyrics
dotify "URL" --synced-lyrics-only
# Download with verbose logging
dotify "URL" --log-level DEBUG
Video Downloads
# Download music video
dotify "URL" --download-music-videos
# Download podcast video
dotify "URL" --download-podcast-videos
# Choose video format
dotify "URL" --video-format webm
Batch Operations
# Download from text file
dotify --read-urls-as-txt urls.txt
# Download multiple URLs
dotify "URL1" "URL2" "URL3"
# Download with custom wait interval
dotify "URL" --wait-interval 10
โ๏ธ Configuration
Config File Location
- Linux/macOS:
~/.dotify/config.ini - Windows:
%USERPROFILE%\.dotify\config.ini
Common Configuration Options
| Option | Description | Default |
|---|---|---|
cookies_path |
Path to cookies file | ~/.dotify/cookies.txt |
wvd_path |
Path to Widevine key | ~/.dotify/keys/device.wvd |
output_path |
Output directory | Spotify |
audio_quality |
Audio quality priority | aac-medium |
wait_interval |
Wait between downloads (seconds) | 5 |
log_level |
Logging level | INFO |
Template Variables
Customize your file organization with these variables:
- Album:
{album},{album_artist},{year},{label} - Track:
{title},{track},{disc},{artist} - Metadata:
{isrc},{composer},{copyright},{genre} - Playlist:
{playlist_title},{playlist_artist},{playlist_track}
Example Templates
# Album organization
album_folder_template = {album_artist}/{album} [{year}]
single_disc_file_template = {track:02d} - {title}
multi_disc_file_template = {disc}-{track:02d} - {title}
# Podcast organization
podcast_folder_template = Podcasts/{album}
podcast_file_template = {track:02d} - {title}
# Playlist organization
playlist_file_template = Playlists/{playlist_artist}/{playlist_title}
๐ง Troubleshooting
Common Issues
โ "Cookies file not found"
Solution:
# Check where Dotify expects cookies
dotify env paths
# Verify cookies file exists
ls ~/.dotify/cookies.txt
# Run diagnostics
dotify env doctor
โ "Widevine key not found"
Solution:
# Check WVD location
dotify env check wvd
# For Vorbis downloads (no WVD needed)
dotify "URL" --disable-wvd
โ "FFmpeg not found"
Solution:
# Check FFmpeg installation
dotify env check ffmpeg
# Install FFmpeg:
# Windows: https://www.animemusic.info/2024/02/ffmpeg-builds-static-shared.html
# Linux: https://johnvansickle.com/ffmpeg/
โ "Authentication failed"
Solution:
# Export fresh cookies from open.spotify.com
# Replace old cookies.txt
dotify env doctor
Getting Help
# Full diagnostic
dotify env doctor --verbose
# JSON output for automation
dotify env doctor --json
# Check specific component
dotify env check ffmpeg
# View all paths
dotify env paths
๐ Advanced Usage
Preflight Checks
Dotify automatically runs preflight checks before downloads:
# Automatic checks (default)
dotify "URL"
# Skip preflight checks (advanced users)
dotify "URL" --skip-preflight
Error Handling
Dotify provides helpful error messages with fix suggestions:
# Example error output:
# [X] Cookies File: Cookies file not found
# Fix: Place cookies.txt in ~/.dotify or use --cookies-path
#
# Run 'dotify env doctor' for details
Quality Options
# AAC qualities (Premium)
--audio-quality aac-medium # 128kbps
--audio-quality aac-high # 256kbps
# Vorbis qualities
--audio-quality vorbis-high # 320kbps
--audio-quality vorbis-medium # 160kbps
--audio-quality vorbis-low # 96kbps
Download Modes
# ytdlp (default)
--download-mode ytdlp
# aria2c (faster, requires aria2c)
--download-mode aria2c
Remux Modes
# FFmpeg (default)
--audio-remux-mode ffmpeg
--video-remux-mode ffmpeg
# MP4Box
--audio-remux-mode mp4box
# mp4decrypt
--audio-remux-mode mp4decrypt
๐ What's New
Environment Layer (v1.9.8+)
- ๐ง Auto Setup - One-command environment preparation
- ๐ฉบ Health Checks - Comprehensive system diagnostics
- ๐ Smart Configuration - Automated config management
- ๐ฏ Preflight Validation - Checks before every operation
- ๐ก Better Errors - Clear, actionable error messages
- ๐ Path Management - Centralized path handling
Key Improvements
- Self-Aware - Dotify knows its own structure and requirements
- User-Friendly - Clear guidance for setup and troubleshooting
- Professional - Production-ready error handling and diagnostics
- Maintainable - Clean separation of concerns
๐ Supported Content
| Type | Formats | Quality | Notes |
|---|---|---|---|
| Songs | AAC, Vorbis | 96-320kbps | AAC requires Premium + WVD |
| Podcasts | AAC, Vorbis | 96-320kbps | Vorbis works without Premium |
| Music Videos | MP4, WebM | Up to 1080p | Requires Premium |
| Podcast Videos | MP4, WebM | Up to 1080p | Requires Premium |
| Lyrics | LRC | Synced | Automatic with tracks |
๐ค Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
๐ License
This project is licensed under the MIT License - see the LICENSE file for details.
๐ Acknowledgments
- Spotify for the amazing music platform
- KeyDive for Widevine key extraction
- yt-dlp for download functionality
- FFmpeg for media processing
- All contributors and users of Dotify
๐ Support
- Email: salahin0ashfi@gmail.com
- Discord: Join our Discord
- Issues: Report bugs on GitHub
โญ If you find this project helpful, consider giving it a star! โญ
Made with โค๏ธ by @AsHfIEXE
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file dotify_cli-2.0.0.tar.gz.
File metadata
- Download URL: dotify_cli-2.0.0.tar.gz
- Upload date:
- Size: 84.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2c9683798f7da31e00182d910d8bdfb441a7028e20986fc3b0aef7cea0e33ad6
|
|
| MD5 |
cb4cebb30e3ea8a1d35c7a53946e77b2
|
|
| BLAKE2b-256 |
8580e2862204000594147a5282ccb7c1bce8633f28880e1ee3c5500a889d8634
|
File details
Details for the file dotify_cli-2.0.0-py3-none-any.whl.
File metadata
- Download URL: dotify_cli-2.0.0-py3-none-any.whl
- Upload date:
- Size: 96.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
775793a71aa720fbb93e59ef49e8bb5380af86b912ddfc8096ce934589f11899
|
|
| MD5 |
88dd46b64b027562f481bf596fe6dc6c
|
|
| BLAKE2b-256 |
ceb032f2e8cdf059b2134bfd3853933f374576010a548395cae97363c26127cc
|