@salvobee/discogs-tagger
v0.0.1
Published
Utility for automatic tagging of MP3 files using Discogs API to fetch release data.
Downloads
62
Readme
Discogs MP3 Tagger
Core library for automatic MP3 tagging using the Discogs API.
This package contains all the business logic required to analyze MP3 files, match them against Discogs releases, compute tag updates, and apply those updates to the files.
It is designed to be UI-agnostic and can be reused in:
- CLI tools
- Electron desktop applications
- Web or server-side applications
No CLI parsing or UI code is included in this package.
Features
- Scan files and directories to collect MP3 files
- Read existing ID3 tags and audio metadata (duration, embedded artwork)
- Search Discogs using an heuristic, multi-step strategy:
- Prefer
masterreleases - Automatic fallback to single
releasesearch when no master exists
- Prefer
- Resolve the most suitable release and track using:
- Duration matching (preferred)
- Title similarity (fallback)
- Compute a snapshot containing all proposed tag and artwork changes
- Let consumers review, modify, or override proposed changes before applying
- Apply tags and cover artwork to MP3 files
- Progress reporting via a reusable reporter callback API
Requirements
- Node.js >= 18
- A Discogs API token
(create one at https://www.discogs.com/settings/developers)
Installation
npm install @salvobee/discogs-tagger