PrivateAlbumsAPI

class minim.api.qobuz.PrivateAlbumsAPI(client: APIClient, /)[source]

Bases: PrivateQobuzResourceAPI

Albums API endpoints for the private Qobuz API.

Important

This class is managed by PrivateQobuzAPIClient and should not be instantiated directly.

Parameters:
clientminim.api._shared.APIClient

API client instance used to make HTTP requests.

Methods

get_album

Get Qobuz catalog information for an album.

get_featured_albums

Get Qobuz catalog information for featured albums.

get_my_saved_albums

Get the current user's favorite albums.

is_album_saved

Check whether the current user has an album favorited.

remove_saved_albums

Unfavorite one or more albums.

save_albums

Favorite one or more albums.

search_albums

Search for albums in the Qobuz catalog.

toggle_album_saved

Toggle the favorite status of an album.

get_album(album_id: str, /, *, expand: str | Collection[str] | None = None, limit: int | None = None, offset: int | None = None) dict[str, Any][source]

Get Qobuz catalog information for an album.

Parameters:
album_idstr; positional-only

Qobuz ID of the album.

Examples: "0075679933652", "aaxy9wirwgn2a".

expandstr or Collection[str]; keyword-only; optional

Related resources to include metadata for in the response.

Valid values: "albumsFromSameArtist", "focus", "focusAll".

Examples: "albumsFromSameArtist", "focus,focusAll", ["focus", "focusAll"].

limitint; keyword-only; optional

Maximum number of tracks to return.

Valid range: 1 to 500.

API default: 500.

offsetint; keyword-only; optional

Index of the first track to return. Use with limit to get the next batch of tracks.

Minimum value: 0.

API default: 0.

Returns:
albumdict[str, Any]

Qobuz metadata for the album.

Get Qobuz catalog information for featured albums.

Parameters:
featured_typestr; positional-only

Type of featured albums to return.

Valid values: "most-streamed", "best-sellers", "new-releases", "press-awards", "editors-picks", "most-featured", "harmonia-mundi", "universal-classic", "universal-jazz", "universal-jeunesse", "universal-chanson", "new-releases-full", "recent-releases", "ideal-discography", "qobuzissims", "album-of-the-week", "re-release-of-the-week".

genre_idsint, str, or Collection[int | str]; optional

Qobuz IDs of the genres used to filter the featured albums to return.

Examples: 10, "64", "10,64", [10, "64"].

limitint; keyword-only; optional

Maximum number of albums to return.

Valid range: 1 to 500.

API default: 25.

offsetint; keyword-only; optional

Index of the first album to return. Use with limit to get the next batch of albums.

Minimum value: 0.

API default: 0.

Returns:
albumsdict[str, Any]

Page of Qobuz metadata for the featured albums.

get_my_saved_albums(*, limit: int | None = None, offset: int | None = None) dict[str, Any][source]

Get the current user’s favorite albums.

User authentication

User authentication

Access and manage your library.

Parameters:
limitint; keyword-only; optional

Maximum number of artists to return.

Valid range: 1 to 500.

API default: 50.

offsetint; keyword-only; optional

Index of the first artist to return. Use with limit to get the next batch of artists.

Minimum value: 0.

API default: 0.

Returns:
albumsdict[str, Any]

Page of Qobuz metadata for the current user’s favorite albums.

is_album_saved(album_id: str, /) dict[str, bool][source]

Check whether the current user has an album favorited.

User authentication

User authentication

Access and manage your library.

Parameters:
album_idstr; positional-only

Qobuz ID of the album.

Examples: "0075679933652", "aaxy9wirwgn2a".

Returns:
saveddict[str, bool]

Whether the current user has the album favorited.

Sample response: {"status": <bool>}.

remove_saved_albums(album_ids: str | Collection[str] | None = None, /) dict[str, str][source]

Unfavorite one or more albums.

User authentication

User authentication

Access and manage your library.

Parameters:
album_idsstr or Collection[str]; positional-only; optional

Qobuz IDs of the albums.

Examples: "0075679933652", "0075679933652,aaxy9wirwgn2a".

Returns:
statusdict[str, str]

Whether the albums were unfavorited successfully.

Sample response: {"status": "success"}.

save_albums(album_ids: str | Collection[str] | None = None, /) dict[str, str][source]

Favorite one or more albums.

User authentication

User authentication

Access and manage your library.

Parameters:
album_idsstr or Collection[str]; positional-only; optional

Qobuz IDs of the albums.

Examples: "0075679933652", "0075679933652,aaxy9wirwgn2a".

Returns:
statusdict[str, str]

Whether the albums were favorited successfully.

Sample response: {"status": "success"}.

search_albums(query: str, /, *, limit: int | None = None, offset: int | None = None) dict[str, Any][source]

Search for albums in the Qobuz catalog.

Parameters:
querystr; positional-only

Search query.

Tip

Searches can be narrowed using tags, such as #ByMainArtist, #ByComposer, #ByPerformer, #ByReleaseName, #ByLabel, #NewRelease, and #HiRes.

Use strict matching instead of fuzzy search by wrapping the keyword string in double quotes.

Example: "Galantis" #ByMainArtist #HiRes.

limitint; keyword-only; optional

Maximum number of albums to return.

Valid range: 1 to 500.

API default: 50.

offsetint; keyword-only; optional

Index of the first album to return. Use with limit to get the next batch of albums.

Minimum value: 0.

API default: 0.

Returns:
albumsdict[str, Any]

Page of Qobuz metadata for the matching albums.

toggle_album_saved(album_id: str, /) dict[str, str][source]

Toggle the favorite status of an album.

User authentication

User authentication

Access and manage your library.

Parameters:
album_idstr; positional-only

Qobuz ID of the album.

Examples: "0075679933652", "aaxy9wirwgn2a".

Returns:
statusdict[str, bool]

Whether the album is now favorited.

Sample response: {"status": <bool>}.