Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Media tracks #77

Closed
lukehedger opened this issue Aug 22, 2018 · 3 comments
Closed

Media tracks #77

lukehedger opened this issue Aug 22, 2018 · 3 comments

Comments

@lukehedger
Copy link

Is it possible to retrieve all of the tracks on a Release? Looking at the MusicBrainz API it should be possible to do this:

{
  lookup {
    release(mbid: "617908f2-7a0b-3aad-ae02-5a5c125fa1a7") {
      media {
        trackCount
        position
        tracks # Cannot query field "tracks" on type "Medium"
        formatID
        format
      }
    }
  }
}

This is the equivalent request on the JSON web service: http://musicbrainz.org/ws/2/release/617908f2-7a0b-3aad-ae02-5a5c125fa1a7?inc=recordings&fmt=json

{
  "id": "617908f2-7a0b-3aad-ae02-5a5c125fa1a7",
  "media": [
    {
      "track-count": 12,
      "position": 1,
      "track-offset": 0,
      "tracks": [{}],
      "format-id": "9712d52a-4509-3d4b-a1a2-67c88c643e31",
      "format": "CD"
    }
  ]
}
@exogen
Copy link
Owner

exogen commented Aug 23, 2018

Not presently, but that is a great TODO item. I don't know much about tracks – I assume it always returns all tracks, and not a subset where you have to use browse somehow to get the full list? Trying to decide if it should be a Connection or not.

@lukehedger
Copy link
Author

Yep - it just returns all tracks, as far as I can tell. As for pagination, reckon that would make sense and I guess that is the purpose of the track-offset field?

@exogen exogen mentioned this issue Sep 17, 2018
@exogen
Copy link
Owner

exogen commented Sep 17, 2018

Released in v8.1.0!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants