A Bun-based proxy API server for downloading Spotify tracks using spotidown.app. This project uses Puppeteer to automate form submission and fetch MP3 download links, and the spotify-web-api-node for ISRC-based track lookup.
- Spotify Track Download: Get direct MP3 download links for Spotify tracks by their track ID.
- ISRC Lookup: Search for Spotify tracks using ISRC codes and fetch their download links.
- Automated Session Management: The server uses Puppeteer to keep an active session with Spotidown and refreshes it periodically.
- REST API: Simple HTTP endpoints for integration.
GET /track/:id
Redirects to the MP3 download URL for the given Spotify track ID.
Example:
GET /track/1VdLGQ8r0fA2QzjWbJf2G7Response: HTTP 302 Redirect to download URL.
GET /isrc/:isrc
Searches Spotify for a track matching the given ISRC, then redirects to the MP3 download URL.
Example:
GET /isrc/USUM71703861Response: HTTP 302 Redirect to download URL.
- Uses Puppeteer to interact with spotidown.app in a headless browser.
- Submits the Spotify track URL, runs the reCAPTCHA, and collects form data needed for download.
- Extracts the final MP3 download link from Spotidown's server response.
- For ISRC lookups, uses Spotify's API to resolve the track ID.
- Bun (v1.0+)
- Node.js (for Puppeteer and Spotify API)
- Puppeteer
- spotify-web-api-node
bun installbun run index.tsServer will start at http://localhost:3045.
No API keys required for Spotidown, but your server will use Bun, Puppeteer, and Spotify's public API credentials.
- ReCAPTCHA Handling: The server uses Spotidown's public reCAPTCHA site key and executes the challenge automatically.
- Session Refresh: The Spotidown page is refreshed every 5 minutes to maintain a valid session.
- Rate Limits: Excessive usage may trigger Spotidown or Spotify rate limits.
MIT
This repository is for educational purposes only. Downloading copyrighted material without permission may violate Spotify's Terms of Service and/or local laws. Use responsibly.