My Spotify playlist takes pull requests
Description and use
A single text file in a GitHub repo holds the playlist; GitHub Actions and the Spotify API validate, sync, and publish changes, enabling collaborative song addition via pull requests.
Problem
Enabling collaborative song addition to a Spotify playlist via GitHub pull requests while ensuring validation, deduplication, and synchronization without a server or database.
Outcome
The workflow allows anyone with a GitHub account to propose songs, automatically validates and syncs them to a Spotify playlist, and tracks contributions via git history.
Workflow
- Open a "🎵 Add a song" issue with a Spotify link
- A workflow converts the issue into a PR, appends the track to the file, and comments the PR link
- CI validates the PR, checking ID format, duplicates, and Spotify lookup
- Reviewer listens to the track and merges, comments, or rejects the PR
- Merging pushes to main, triggering a sync workflow that replaces the Spotify playlist with the file’s contents
Evidence
A workflow turns the issue into a PR. It looks the song up on Spotify, appends <link> # Artist - Title to the file, and comments back on the issue with the PR link.
CI validates the PR. Malformed IDs and duplicates fail the check with an annotation on the exact line.
Merging is publishing. A push to main that touches playlists/ runs the sync, and the Spotify playlist now matches the file.
- Record date: 2026-10-17T19:56:18.511Z