Question

I want to use the CoverArtArchiveClient to load Album Images from MusicBrainz but it requires a MusicBrainz ID (MBID). Can someone provide info on how to get the MBID for a particular Album? Code samples would be much appreciated.

Thanks

No correct solution

OTHER TIPS

The details depend a lot on what representation you have of "a particular album".

In general MusicBrainz provides a web service (in XML and json format) where you can search for MusicBrainz entities, which will also give you the MBID. You want to get the MBID of release entities.

Since you seem to be developing on Android in Java you might be interested in musicbrainzws2-java the Java binding of the Web Service.

There are other language bindings/libraries available for the current version (WS/2 = "NGS") of the web service and you always have the option to use the web service directly.

If you have the album available in the form of tagged audio files, then you should try to extract the tags, since sometimes MBIDs are already available in the files and you don't have to search on MusicBrainz.

EDIT:
SO how-to-get-album-image-using-musicbrainz has an answer that tells how to use the web service directly. The MusicBrainz web service can also return links/urls to coverart directly (as described in that answer). So you save another call to the CoverArtArchive.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top