Skip to content

How to get Series information for a release #150

Answered by prcutler
VinylVault asked this question in General
Discussion options

You must be logged in to vote

Without knowing what you want to script, a basic Python program might look like this. You could wrap it in a try / except if a given release doesn't have a series, but you just want to make sure you account for the list and the dictionary inside it:

import discogs_client

d = discogs_client.Client('SeriesTest/0.1')

release = d.release(31125881)
series_info = release.fetch('series')
print(series_info)

series_id = series_info[0]['id']
series_name = series_info[0]['name']

print('Series name: ', series_name, 'Series ID: ', series_id)

And that returns:

[{'name': 'Now Yearbook', 'catno': "'93", 'entity_type': '2', 'entity_type_name': 'Series', 'id': 2583262, 'resource_url': 'https://api.disc…

Replies: 2 comments 7 replies

Comment options

You must be logged in to vote
7 replies
@VinylVault
Comment options

@JOJ0
Comment options

JOJ0 Aug 18, 2024
Maintainer

@VinylVault
Comment options

@JOJ0
Comment options

JOJ0 Aug 19, 2024
Maintainer

@VinylVault
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by JOJ0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants