Getting all tracks by Classical Composer through Web Service

Hi,
I’m trying to get a track level data set, clean it up and remove duplicates, then submit to another API in order to play the tracks.
My goal is basically to get the entire oeuvre of a composer.
I’ve got a reasonably good understanding of SQL, and I could replicate the database, but I’d rather work through the MusicBrainz API.
Unfortunately, I really don’t understand how to frame the “classical composer as artist” aspect in the API

Does anyone have a sample query that I could look at? I’ve been looking online for samples for quite a while, found it difficult to find the specific case.

1 Like

Hi,

are you looking for a list of recordings, or a list of works?

1 Like

Doing this through the webservice probably implies getting all works by the composer/artist, then calling to each work to get all their recordings, then also possibly getting all the recordings with the composer as recording artist. Unless I’m missing some easier option, I’d really suggest to just use the database directly.

As you guessed, works-recordings.
I was able to get a query working just getting records with Mozart as artist., but I actually think you might be right re the database.
I may set it up in AWS as a slave.
Thanks for your input

To build on reosarevok’s response, you can get part of the way there with this web service query:

http://musicbrainz.org/ws/2/work?artist=24f1766e-9635-4d58-a4d4-9413f9f98a4c&inc=artist-rels+recording-rels&limit=25

You’d need to know a little about how browse requests and paging works, and you’d need to filter the results to only include works that are associated with the artist by the “composer of” relaitonship type.

One downside is that there are a lot of recordings that haven’t been properly linked to works (yet!), and finding them with the web service is not so straightforward (as far as I can tell).