DiscogsFeeds
For years I've wanted Discogs to add support for artist and label specific RSS feeds so I could be notified of new releases.
This was recently implemented with the new "recent releases" section on each artist page.
However I still found myself wanting more control over exactly what the feeds contain, or the option to see all new releases on a given label.
So I've built a web service that leverages the Discogs API to provide filterable feeds for any label, artist, release or search query.
It supports not only
Atom and
RSS, but also
JSON and
BSON, meaning it could be used as a more natural way to consume Discogs data from JavaScript.
Getting Started
To begin with you'll need a Discogs API key which you can get
here.
This key is used to access the Discogs API and is not stored in any way by my service.
Basic Usage
Once you have a key, you can request a feed, like so:
www.nathanbaulch.com/DiscogsFeeds/artist/Aphex+Twin?api_key=[API_Key]
The default format returned is Atom, a common standard understood by most feed readers.
Now let's say you only want to see full albums. You can use the $format filter parameter:
www.nathanbaulch.com/DiscogsFeeds/artist/Aphex+Twin?api_key=[API_Key]&$format=Album
All custom parameters have been prefixed with a dollar sign to prevent clashes with current and future Discogs API parameters.
If you want to request more than one format at a time you can simply add more $format parameters and they'll be logically OR-ed together:
www.nathanbaulch.com/DiscogsFeeds/artist/Aphex+Twin?api_key=[API_Key]&$format=Album&$format=CD
The filter values also support asterisks wildcards so that, for example, you can match multiple formats like CD, 2xCD, 3xCD, etc in one filter:
www.nathanbaulch.com/DiscogsFeeds/artist/Aphex+Twin?api_key=[API_Key]&$format=*CD
If you want to limit the results to actual release by the artist and not remixes they've done or track appearances, you can use the $type parameter:
www.nathanbaulch.com/DiscogsFeeds/artist/Aphex+Twin?api_key=[API_Key]&$type=Main
Advanced Features
A special value-less $distinct parameter can be used if you want to combine all releases with the same artist and title:
www.nathanbaulch.com/DiscogsFeeds/artist/Aphex+Twin?api_key=[API_Key]&$distinct
This helps to cut down on duplicate releases on different labels, just like Discogs does with "master" release pages.
Other content formats can be requested by assigning the "f" parameter values such as rss, json, bson or xml:
www.nathanbaulch.com/DiscogsFeeds/artist/Aphex+Twin?api_key=[API_Key]&f=json
Due to a limitation in the technology I've built this service with, non-ASCII characters are not allowed in URLs.
To work around this, a $name parameter can be used with standard Unicode escape codes when requesting artists or labels with non-ASCII characters:
www.nathanbaulch.com/DiscogsFeeds/artist?$name=Trentem%C3%B8ller&api_key=[API_Key]&$distinct
Labels, specific releases and search queries can also be requested and filtered using the conventions outlined in the official Discogs API documentation.
Please refer to this documentation for information on the available fields and their potential values.
Thanks To
Discogs - the best music database on the web!
Ekki - for his Discogs API XSD schema.
Argotic - a library that makes publishing syndication feeds really simple.
Json.NET - a library for working with Json in .net.
LinqBridge - a library that brings LINQ to Objects to .net 2.0 applications.