UsersAPI¶
- class minim.api.tidal.UsersAPI(client: APIClient, /)[source]¶
Bases:
TIDALResourceAPIUser Collections, User Recommendations, and Users API endpoints for the TIDAL API.
Important
This class is managed by
TIDALAPIClientand should not be instantiated directly.- Parameters:
- clientminim.api._shared.APIClient
API client instance used to make HTTP requests.
Methods
User Collection Artists > Add to Items Relationship: Add artists to a user collection․ User Collections > Add to Artists Relationship: Add artists to a user's collection.
User Collection Playlists > Add to Items Relationship: Add playlists to a user collection․ User Collections > Add Playlists to User's Collection: Add playlists to a user's collection.
User Collection Albums > Get User Album Collection: Get TIDAL catalog information for a user album collection.
User Collection Artists > Get User Artist Collection: Get TIDAL catalog information for a user artist collection.
User Recommendations > Get Discovery Mixes Relationship: Get TIDAL catalog information for a user's Discovery Mixes.
User Recommendations > Get New Arrival Mixes Relationship: Get TIDAL catalog information for the user's New Arrival Mixes.
User Recommendations > Get Single User Recommendation: Get TIDAL catalog information for mixes curated for a user.
User Collection Playlists > Get User Playlist Collection: Get TIDAL catalog information for a user playlist collection.
Users > Get Single User: Get TIDAL profile information for a user.
User Collections > Get Single User Collection: Get TIDAL catalog information for a user's collection.
User Collections > Get Owners Relationship: Get TIDAL profile information for the owners of a user collection resource.
User Collection Artists > Get Items Relationship: Get TIDAL catalog information for artists in a user collection․ User Collections > Get Artists Relationship: Get TIDAL catalog information for artists in a user's collection.
User Collection Playlists > Get Items Relationship: Get TIDAL catalog information for playlists in a user collection․ User Collections > Get Playlists Relationship: Get TIDAL catalog information for playlists in a user's collection.
User Recommendations > Get My Mixes Relationship: Get TIDAL catalog information for a user's mixes.
User Collection Albums > Get Items Relationship: Get TIDAL catalog information for albums in a user collection․ User Collections > Get Albums Relationship: Get TIDAL catalog information for albums in a user's collection.
User Collection Tracks > Get Items Relationship: Get TIDAL catalog information for tracks in a user collection․ User Collections > Get Tracks Relationship: Get TIDAL catalog information for tracks in a user's collection.
User Collection Videos > Get Items Relationship: Get TIDAL catalog information for videos in a user collection․ User Collections > Get Videos Relationship: Get TIDAL catalog information for videos in a user's collection.
User Collection Albums > Delete from Items Relationship: Remove albums from a user collection․ User Collections > Delete from Albums Relationship: Remove albums from a user's collection.
User Collection Tracks > Delete from Items Relationship: Remove tracks from a user collection․ User Collections > Delete from Tracks Relationship: Remove tracks from a user's collection.
User Collection Videos > Delete from Items Relationship: Remove videos from a user collection․ User Collections > Delete from Videos Relationship: Remove videos from a user's collection.
User Collection Albums > Add to Items Relationship: Add albums to a user collection․ User Collections > Add to Albums Relationship: Add albums to a user's collection.
User Collection Tracks > Add to Items Relationship: Add tracks to a user collection․ User Collections > Add to Tracks Relationship: Add tracks to a user's collection.
User Collection Videos > Add to Items Relationship: Add videos to a user collection․ User Collections > Add to Videos Relationship: Add videos to a user's collection.
User Collection Artists > Delete from Items Relationship: Remove artists from a user collection․ User Collections > Delete from Items Relationship: Remove artists from a user's collection.
User Collection Playlists > Delete from Items Relationship: Remove playlists from a user collection․ User Collections > Remove Playlists from User's Collection: Remove playlists from a user's collection.
- follow_artists(artist_ids: int | str | dict[str, int | str] | Collection[int | str | dict[str, int | str]], /, *, collection_id: str | None = None, user_id: int | str | None = None, country_code: str | None = None) None[source]¶
User Collection Artists > Add to Items Relationship: Add artists to a user collection․ User Collections > Add to Artists Relationship: Add artists to a user’s collection.
Authorization scope
collection.writescopeWrite access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
POST /userCollections/{user_id}/relationships/artistsendpoint is used.- Parameters:
- artist_idsint, str, dict[str, int | str], or Collection[int | str | dict[str, int | str]]; positional-only
TIDAL IDs and/or resource identifiers of the artists.
Examples:
1566"4676988"{"id": "1566", "types": "artists"}["4676988", {"id": "46369321", "types": "artists"}]
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- country_codestr; keyword-only; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".
- follow_playlists(playlist_uuids: str | dict[str, str] | Collection[str | dict[str, str]], /, *, collection_id: str | None = None, user_id: int | str | None = None) None[source]¶
User Collection Playlists > Add to Items Relationship: Add playlists to a user collection․ User Collections > Add Playlists to User’s Collection: Add playlists to a user’s collection.
Authorization scope
collection.writescopeWrite access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
POST /userCollections/{user_id}/relationships /playlistsendpoint is used.- Parameters:
- playlist_uuidsstr, dict[str, str], or Collection[str | dict[str, str]]; positional-only
UUIDs and/or resource identifiers of the playlists.
Examples:
"f0d6f5c4-081f-4348-9b65-ae677d92767b"{ "id": "1e4c73df-b805-47cd-9e44-9a8721c5cb45", "types": "playlists" }
[ "f0d6f5c4-081f-4348-9b65-ae677d92767b", { "id": "1e4c73df-b805-47cd-9e44-9a8721c5cb45", "types": "playlists" } ]
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- get_album_collection(collection_id: str | None = None, /, *, country_code: str | None = None, locale: str | None = None, expand: str | Collection[str] | None = None) dict[str, Any][source]¶
User Collection Albums > Get User Album Collection: Get TIDAL catalog information for a user album collection.
Authorization scope
collection.readscopeRead access to a user’s collection.
- Parameters:
- collection_idstr; positional-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- country_codestr; keyword-only; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".- localestr; keyword-only; optional
IETF BCP 47 language tag.
- expandstr or Collection[str]; keyword-only; optional
Related resources to include metadata for in the response.
Valid values:
"items","owners".Examples:
"items",["items", "owners"].
- Returns:
- collectiondict[str, Any]
TIDAL metadata for the user album collection.
Sample response
{ "data": { "attributes": {}, "id": <str>, "relationships": { "items": { "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "albums" } ], "links": { "self": <str> } }, "owners": { "data": [ { "id": <str>, "type": "users" } ], "links": { "self": <str> } } }, "type": "userCollectionAlbums" }, "included": [ { "attributes": { "accessType": <str>, "albumType": <str>, "availability": <list[str]>, "barcodeId": <str>, "copyright": { "text": <str> }, "duration": <str>, "explicit": <bool>, "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "mediaTags": <list[str]>, "numberOfItems": <int>, "numberOfVolumes": <int>, "popularity": <float>, "releaseDate": <str>, "title": <str>, "type": <str> }, "id": <str>, "relationships": { "artists": { "links": { "self": <str> } }, "coverArt": { "links": { "self": <str> } }, "genres": { "links": { "self": <str> } }, "items": { "links": { "self": <str> } }, "owners": { "links": { "self": <str> } }, "providers": { "links": { "self": <str> } }, "similarAlbums": { "links": { "self": <str> } }, "suggestedCoverArts": { "links": { "self": <str> } } }, "type": "albums" }, { "attributes": { "country": <str>, "email": <str>, "emailVerified": <bool>, "firstName": <str>, "username": <str> }, "id": <str>, "type": "users" } ], "links": { "self": <str> } }
- get_artist_collection(collection_id: str | None = None, /, *, country_code: str | None = None, locale: str | None = None, expand: str | Collection[str] | None = None) dict[str, Any][source]¶
User Collection Artists > Get User Artist Collection: Get TIDAL catalog information for a user artist collection.
Authorization scope
collection.readscopeRead access to a user’s collection.
- Parameters:
- collection_idstr; positional-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- country_codestr; keyword-only; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".- localestr; keyword-only; optional
IETF BCP 47 language tag.
- expandstr or Collection[str]; keyword-only; optional
Related resources to include metadata for in the response.
Valid values:
"items","owners".Examples:
"items",["items", "owners"].
- Returns:
- collectiondict[str, Any]
TIDAL metadata for the user artist collection.
Sample response
{ "data": { "attributes": {}, "id": <str>, "relationships": { "items": { "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "artists" } ], "links": { "self": <str> } }, "owners": { "data": [ { "id": <str>, "type": "users" } ], "links": { "self": <str> } } }, "type": "userCollectionArtists" }, "included": [ { "attributes": { "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "name": <str>, "popularity": <float> }, "id": <str>, "relationships": { "albums": { "links": { "self": <str> } }, "biography": { "links": { "self": <str> } }, "followers": { "links": { "self": <str> } }, "following": { "links": { "self": <str> } }, "owners": { "links": { "self": <str> } }, "profileArt": { "links": { "self": <str> } }, "radio": { "links": { "self": <str> } }, "roles": { "links": { "self": <str> } }, "similarArtists": { "links": { "self": <str> } }, "trackProviders": { "links": { "self": <str> } }, "tracks": { "links": { "self": <str> } }, "videos": { "links": { "self": <str> } } }, "type": "artists" }, { "attributes": { "country": <str>, "email": <str>, "emailVerified": <bool>, "firstName": <str>, "username": <str> }, "id": <str>, "type": "users" } ], "links": { "self": <str> } }
- get_discovery_mixes(*, user_id: str | None = None, country_code: str | None = None, locale: str | None = None, include_metadata: bool = False, cursor: int | None = None) dict[str, Any][source]¶
User Recommendations > Get Discovery Mixes Relationship: Get TIDAL catalog information for a user’s Discovery Mixes.
Authorization scope
recommendations.readscopeRead access to a user’s personal recommendations.
- Parameters:
- user_idint or str; keyword-only; optional
TIDAL ID of the user. If not specified, the current user’s TIDAL ID is used.
- country_codestr; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".- localestr; keyword-only; optional
IETF BCP 47 language tag.
- include_metadatabool; keyword-only; default:
False Whether to include metadata for the user’s Discovery Mixes.
- cursorstr; keyword-only; optional
Cursor for fetching the next page of results.
Example:
"3nI1Esi".
- Returns:
- mixesdict[str, Any]
Page of TIDAL catalog information for the user’s Discovery Mixes.
Sample response
{ "data": [], "included": [], "links": { "meta": { "nextCursor": <str> }, "next": <str>, "self": <str> } }
- get_new_arrival_mixes(*, user_id: str | None = None, country_code: str | None = None, locale: str | None = None, include_metadata: bool = False, cursor: int | None = None) dict[str, Any][source]¶
User Recommendations > Get New Arrival Mixes Relationship: Get TIDAL catalog information for the user’s New Arrival Mixes.
Authorization scope
recommendations.readscopeRead access to a user’s personal recommendations.
- Parameters:
- user_idint or str; keyword-only; optional
TIDAL ID of the user. If not specified, the current user’s TIDAL ID is used.
- country_codestr; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".- localestr; keyword-only; optional
IETF BCP 47 language tag.
- include_metadatabool; keyword-only; default:
False Whether to include metadata for the user’s New Arrival Mixes.
- cursorstr; keyword-only; optional
Cursor for fetching the next page of results.
Example:
"3nI1Esi".
- Returns:
- mixesdict[str, Any]
Page of TIDAL catalog information for the user’s New Arrival Mixes.
Sample response
{ "data": [], "included": [], "links": { "meta": { "nextCursor": <str> }, "next": <str>, "self": <str> } }
- get_personalized_mixes(*, user_id: str | None = None, country_code: str | None = None, locale: str | None = None, expand: str | Collection[str] | None = None) dict[str, Any][source]¶
User Recommendations > Get Single User Recommendation: Get TIDAL catalog information for mixes curated for a user.
Authorization scope
recommendations.readscopeRead access to a user’s personal recommendations.
- Parameters:
- user_idint or str; keyword-only; optional
TIDAL ID of the user. If not specified, the current user’s TIDAL ID is used.
- country_codestr; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".- localestr; keyword-only; optional
IETF BCP 47 language tag.
- expandstr or Collection[str]; keyword-only; optional
Related resources to include in the response.
Valid values:
"discoveryMixes","myMixes","newArrivalMixes".Examples:
"myMixes",["discoveryMixes", "newArrivalMixes"].
- Returns:
- recommendationsdict[str, Any]
TIDAL metadata for the curated mixes.
Sample response
{ "data": { "attributes": {}, "id": <str>, "relationships": { "discoveryMixes": { "data": [], "links": { "self": <str> } }, "myMixes": { "data": [], "links": { "self": <str> } }, "newArrivalMixes": { "data": [], "links": { "self": <str> } } }, "type": "userRecommendations" }, "included": [], "links": { "self": <str> } }
- get_playlist_collection(collection_id: str | None = None, /, *, country_code: str | None = None, locale: str | None = None, expand: str | Collection[str] | None = None) dict[str, Any][source]¶
User Collection Playlists > Get User Playlist Collection: Get TIDAL catalog information for a user playlist collection.
Authorization scope
collection.readscopeRead access to a user’s collection.
- Parameters:
- collection_idstr; positional-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- country_codestr; keyword-only; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".- localestr; keyword-only; optional
IETF BCP 47 language tag.
- expandstr or Collection[str]; keyword-only; optional
Related resources to include metadata for in the response.
Valid values:
"items","owners".Examples:
"items",["items", "owners"].
- Returns:
- collectiondict[str, Any]
TIDAL metadata for the user playlist collection.
Sample response
{ "data": { "attributes": {}, "id": <str>, "relationships": { "items": { "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "playlists" } ], "links": { "self": <str> } }, "owners": { "data": [ { "id": <str>, "type": "users" } ], "links": { "self": <str> } } }, "type": "userCollectionPlaylists" }, "included": [ { "attributes": { "accessType": <str>, "bounded": <bool>, "createdAt": <str>, "description": <str>, "duration": "PT3H16M5S", "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "lastModifiedAt": <str>, "name": <str>, "numberOfFollowers": <int>, "numberOfItems": <int>, "playlistType": <str> }, "id": <str>, "relationships": { "coverArt": { "links": { "self": <str> } }, "items": { "links": { "self": <str> } }, "ownerProfiles": { "links": { "self": <str> } }, "owners": { "links": { "self": <str> } } }, "type": "playlists" } ], "links": { "self": <str> } }
- get_user(user_id: int | str | None = None, /) dict[str, Any][source]¶
Users > Get Single User: Get TIDAL profile information for a user.
Authorization scope
user.readscopeRead access to a user’s account information, such as country and email address.
- Parameters:
- user_idint or str; keyword-only; optional
TIDAL ID of the user. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user. If not specified,"me"is used.
- Returns:
- profiledict[str, Any]
TIDAL profile information for the user.
Sample response
{ "data": { "attributes": { "country": <str>, "email": <str>, "emailVerified": <bool>, "firstName": <str>, "username": <str> }, "id": <str>, "type": "users", }, "links": { "self": "/users/me" } }
- get_user_collection(user_id: int | str | None = None, /, *, country_code: str | None = None, locale: str | None = None, expand: str | Collection[str] | None = None) dict[str, Any][source]¶
User Collections > Get Single User Collection: Get TIDAL catalog information for a user’s collection.
Authorization scope
collection.readscopeRead access to a user’s collection.
- Parameters:
- user_idint or str; positional-only; optional
TIDAL ID of the user. If not specified, the TIDAL ID of current user is used.
- country_codestr; keyword-only; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".- localestr; keyword-only; optional
IETF BCP 47 language tag.
- expandstr or Collection[str]; keyword-only; optional
Related resources to include metadata for in the response.
Valid values:
"albums","artists","owners","playlists","tracks","videos".Examples:
"albums",["tracks", "videos"].
- Returns:
- collectiondict[str, Any]
TIDAL metadata for the user collection.
Sample response
{ "data": { "attributes": {}, "id": <str>, "relationships": { "albums": { "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "albums" } ], "links": { "self": <str> } }, "artists": { "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "artists" } ], "links": { "self": <str> } }, "owners": { "data": [ { "id": <str>, "type": "users" } ], "links": { "self": <str> } }, "playlists": { "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "playlists" } ], "links": { "self": <str> } }, "tracks": { "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "tracks" } ], "links": { "self": <str> } }, "videos": { "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "videos" } ], "links": { "self": <str> } } }, "type": "userCollections" }, "included": [ { "attributes": { "accessType": <str>, "availability": <list[str]>, "barcodeId": <str>, "copyright": { "text": <str> }, "duration": <str>, "explicit": <bool>, "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "mediaTags": <list[str]>, "numberOfItems": <int>, "numberOfVolumes": <int>, "popularity": <float>, "releaseDate": <str>, "title": <str>, "type": "ALBUM" }, "id": <str>, "relationships": { "artists": { "links": { "self": <str> } }, "coverArt": { "links": { "self": <str> } }, "genres": { "links": { "self": <str> } }, "items": { "links": { "self": <str> } }, "owners": { "links": { "self": <str> } }, "providers": { "links": { "self": <str> } }, "similarAlbums": { "links": { "self": <str> } }, "suggestedCoverArts" : { "links": { "self": <str> } } }, "type": "albums" }, { "attributes": { "contributionsEnabled": <bool>, "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "name": <str>, "popularity": <float>, "spotlighted": <bool> }, "id": <str>, "relationships": { "albums": { "links": { "self": <str> } }, "biography": { "links": { "self": <str> } }, "followers": { "links": { "self": <str> } }, "following": { "links": { "self": <str> } }, "owners": { "links": { "self": <str> } }, "profileArt": { "links": { "self": <str> } }, "radio": { "links": { "self": <str> } }, "roles": { "links": { "self": <str> } }, "similarArtists": { "links": { "self": <str> } }, "trackProviders": { "links": { "self": <str> } }, "tracks": { "links": { "self": <str> } }, "videos": { "links": { "self": <str> } } }, "type": "artists" }, { "attributes": { "accessType": <str>, "bounded": <bool>, "createdAt": <str>, "description": <str>, "duration": <str>, "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "lastModifiedAt": <str>, "name": <str>, "numberOfItems": <int>, "playlistType": "USER" }, "id": <str>, "relationships": { "coverArt": { "links": { "self": <str> } }, "items": { "links": { "self": <str> } }, "owners": { "links": { "self": <str> } } }, "type": "playlists" }, { "attributes": { "accessType": <str>, "availability": <list[str]>, "bpm": <float>, "copyright": { "text": <str> }, "duration": <str>, "explicit": <bool>, "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "isrc": <str>, "key": <str>, "keyScale": <str>, "mediaTags": <list[str]>, "popularity": <float>, "spotlighted": <bool>, "title": <str>, "toneTags": <list[str]>, "version": <str> }, "id": <str>, "relationships": { "albums": { "links": { "self": <str> } }, "artists": { "links": { "self": <str> } }, "genres": { "links": { "self": <str> } }, "lyrics": { "links": { "self": <str> } }, "owners": { "links": { "self": <str> } }, "providers": { "links": { "self": <str> } }, "radio": { "links": { "self": <str> } }, "shares": { "links": { "self": <str> } }, "similarTracks": { "links": { "self": <str> } }, "sourceFile": { "links": { "self": <str> } }, "trackStatistics": { "links": { "self": <str> } } }, "type": "tracks" }, { "attributes": { "country": <str>, "email": <str>, "emailVerified": <bool>, "firstName": <str>, "username": <str> }, "id": <str>, "type": "users" }, { "attributes": { "availability": <list[str]>, "copyright": { "text": <str> }, "duration": <str>, "explicit": <bool>, "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "isrc": <str>, "popularity": <float> "releaseDate": <str>, "title": <str> }, "id": <str>, "relationships": { "albums": { "links": { "self": <str> } }, "artists": { "links": { "self": <str> } }, "providers": { "links": { "self": <str> } }, "thumbnailArt": { "links": { "self": <str> } } }, "type": "videos" } ], "links": { "self": <str> } }
- get_user_collection_owners(user_id: int | str | None = None, /, *, include_metadata: bool = False, cursor: str | None = None) dict[str, Any][source]¶
User Collections > Get Owners Relationship: Get TIDAL profile information for the owners of a user collection resource.
Authorization scope
collection.readscopeRead access to a user’s collection.
- Parameters:
- user_idint or str; positional-only; optional
TIDAL ID of the user. If not specified, the TIDAL ID of current user is used.
- include_metadatabool; keyword-only; default:
False Whether to include metadata for the owners.
- cursorstr; keyword-only; optional
Cursor for fetching the next page of results.
Example:
"3nI1Esi".
- Returns:
- ownersdict[str, Any]
Page of TIDAL profile information for the user collection resource’s owners.
Sample response
{ "data": { "id": <str>, "type": "users" }, "included": [ { "attributes": { "country": <str>, "email": <str>, "emailVerified": <bool>, "firstName": <str>, "username": <str> }, "id": <str>, "type": "users" } ], "links": { "self": <str> } }
- get_user_followed_artists(*, collection_id: str | None = None, user_id: int | str | None = None, country_code: str | None = None, locale: str | None = None, include_metadata: bool = False, cursor: str | None = None, sort_by: str | None = None, descending: bool | None = None) dict[str, Any][source]¶
User Collection Artists > Get Items Relationship: Get TIDAL catalog information for artists in a user collection․ User Collections > Get Artists Relationship: Get TIDAL catalog information for artists in a user’s collection.
Authorization scope
collection.readscopeRead access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
GET /userCollections/{user_id}/relationships/artistsendpoint is used.- Parameters:
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- country_codestr; keyword-only; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".- localestr; keyword-only; optional
IETF BCP 47 language tag.
- include_metadatabool; keyword-only; default:
False Whether to include metadata for the artists in the user’s collection.
- cursorstr; keyword-only; optional
Cursor for fetching the next page of results.
Example:
"3nI1Esi".- sort_bystr; keyword-only; optional
Field to sort the artists by.
Valid values:
"addedAt","name".- descendingbool; keyword-only; optional
Whether to sort in descending order.
API default:
False.
- Returns:
- artistsdict[str, Any]
Page of TIDAL metadata for the artists in the user’s collection.
Sample response
{ "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "artists" } ], "included": [ { "attributes": { "contributionsEnabled": <bool>, "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "name": <str>, "popularity": <float>, "spotlighted": <bool> }, "id": <str>, "relationships": { "albums": { "links": { "self": <str> } }, "biography": { "links": { "self": <str> } }, "followers": { "links": { "self": <str> } }, "following": { "links": { "self": <str> } }, "owners": { "links": { "self": <str> } }, "profileArt": { "links": { "self": <str> } }, "radio": { "links": { "self": <str> } }, "roles": { "links": { "self": <str> } }, "similarArtists": { "links": { "self": <str> } }, "trackProviders": { "links": { "self": <str> } }, "tracks": { "links": { "self": <str> } }, "videos": { "links": { "self": <str> } } }, "type": "artists" } ], "links": { "meta": { "nextCursor": <str> }, "next": <str>, "self": <str> } }
- get_user_followed_playlists(*, collection_id: str | None = None, user_id: int | str | None = None, include_folders: bool = False, include_metadata: bool = False, cursor: str | None = None, sort_by: str | None = None, descending: bool | None = None) dict[str, Any][source]¶
User Collection Playlists > Get Items Relationship: Get TIDAL catalog information for playlists in a user collection․ User Collections > Get Playlists Relationship: Get TIDAL catalog information for playlists in a user’s collection.
Authorization scope
collection.readscopeRead access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
GET /userCollections/{user_id}/relationships /playlistsendpoint is used.- Parameters:
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- include_foldersbool; keyword-only; default:
False Whether to include metadata for playlist folders in the user’s collection.
- include_metadatabool; keyword-only; default:
False Whether to include metadata for the playlists in the user’s collection.
- cursorstr; keyword-only; optional
Cursor for fetching the next page of results.
Example:
"3nI1Esi".- sort_bystr; keyword-only; optional
Field to sort the playlists by.
Valid values:
"addedAt","lastUpdatedAt","name".- descendingbool; keyword-only; optional
Whether to sort in descending order.
API default:
False.
- Returns:
- playlistsdict[str, Any]
Page of TIDAL metadata for the playlists (and playlist folders) in the user’s collection.
Sample response
{ "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "playlists" }, { "id": <str>, "meta": { "addedAt": <str> }, "type": "userCollectionFolders" } ], "included": [ { "attributes": { "accessType": <str>, "bounded": <bool>, "createdAt": <str>, "description": <str>, "duration": <str>, "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "lastModifiedAt": <str>, "name": <str>, "numberOfItems": <int>, "playlistType": "USER" }, "id": <str>, "relationships": { "coverArt": { "links": { "self": <str> } }, "items": { "links": { "self": <str> } }, "owners": { "links": { "self": <str> } } }, "type": "playlists" } ], "links": { "meta": { "nextCursor": <str> }, "next": <str>, "self": <str> } }
- get_user_mixes(*, user_id: str | None = None, country_code: str | None = None, locale: str | None = None, include_metadata: bool = False, cursor: int | None = None) dict[str, Any][source]¶
User Recommendations > Get My Mixes Relationship: Get TIDAL catalog information for a user’s mixes.
Authorization scope
recommendations.readscopeRead access to a user’s personal recommendations.
- Parameters:
- user_idint or str; keyword-only; optional
TIDAL ID of the user. If not specified, the current user’s TIDAL ID is used.
- country_codestr; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".- localestr; keyword-only; optional
IETF BCP 47 language tag.
- include_metadatabool; keyword-only; default:
False Whether to include metadata for the user’s mixes.
- cursorstr; keyword-only; optional
Cursor for fetching the next page of results.
Example:
"3nI1Esi".
- Returns:
- mixesdict[str, Any]
Page of TIDAL catalog information for the user’s mixes.
Sample response
{ "data": [], "included": [], "links": { "meta": { "nextCursor": <str> }, "next": <str>, "self": <str> } }
- get_user_saved_albums(*, collection_id: str | None = None, user_id: int | str | None = None, country_code: str | None = None, locale: str | None = None, include_metadata: bool = False, cursor: str | None = None, sort_by: str | None = None, descending: bool | None = None) dict[str, Any][source]¶
User Collection Albums > Get Items Relationship: Get TIDAL catalog information for albums in a user collection․ User Collections > Get Albums Relationship: Get TIDAL catalog information for albums in a user’s collection.
Authorization scope
collection.readscopeRead access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
GET /userCollections/{user_id}/relationships/albumsendpoint is used.- Parameters:
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- country_codestr; keyword-only; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".- localestr; keyword-only; optional
IETF BCP 47 language tag.
- include_metadatabool; keyword-only; default:
False Whether to include metadata for the albums in the user’s collection.
- cursorstr; keyword-only; optional
Cursor for fetching the next page of results.
Example:
"3nI1Esi".- sort_bystr; keyword-only; optional
Field to sort the albums by.
Valid values:
"addedAt","artists.name,"releaseDate","title".- descendingbool; keyword-only; optional
Whether to sort in descending order.
API default:
False.
- Returns:
- albumsdict[str, Any]
Page of TIDAL metadata for the albums in the user’s collection.
Sample response
{ "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "albums" } ], "included": [ { "attributes": { "accessType": <str>, "availability": <list[str]>, "barcodeId": <str>, "copyright": { "text": <str> }, "duration": <str>, "explicit": <bool>, "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "mediaTags": <list[str]>, "numberOfItems": <int>, "numberOfVolumes": <int>, "popularity": <float>, "releaseDate": <str>, "title": <str>, "type": "ALBUM" }, "id": <str>, "relationships": { "artists": { "links": { "self": <str> } }, "coverArt": { "links": { "self": <str> } }, "genres": { "links": { "self": <str> } }, "items": { "links": { "self": <str> } }, "owners": { "links": { "self": <str> } }, "providers": { "links": { "self": <str> } }, "similarAlbums": { "links": { "self": <str> } }, "suggestedCoverArts" : { "links": { "self": <str> } } }, "type": "albums" } ], "links": { "meta": { "nextCursor": <str> }, "next": <str>, "self": <str> } }
- get_user_saved_tracks(*, collection_id: str | None = None, user_id: int | str | None = None, country_code: str | None = None, locale: str | None = None, include_metadata: bool = False, cursor: str | None = None, sort_by: str | None = None, descending: bool | None = None) dict[str, Any][source]¶
User Collection Tracks > Get Items Relationship: Get TIDAL catalog information for tracks in a user collection․ User Collections > Get Tracks Relationship: Get TIDAL catalog information for tracks in a user’s collection.
Authorization scope
collection.readscopeRead access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
GET /userCollections/{user_id}/relationships/tracksendpoint is used.- Parameters:
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- country_codestr; keyword-only; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".- localestr; keyword-only; optional
IETF BCP 47 language tag.
- include_metadatabool; keyword-only; default:
False Whether to include metadata for the tracks in the user’s collection.
- cursorstr; keyword-only; optional
Cursor for fetching the next page of results.
Example:
"3nI1Esi".- sort_bystr; keyword-only; optional
Field to sort the tracks by.
Valid values:
"addedAt","albums.title","artists.name","duration","title".- descendingbool; keyword-only; optional
Whether to sort in descending order.
API default:
False.
- Returns:
- tracksdict[str, Any]
Page of TIDAL metadata for the tracks in the user’s collection.
Sample response
{ "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "tracks" } ], "included": [ { "attributes": { "accessType": <str>, "availability": <list[str]>, "bpm": <float>, "copyright": { "text": <str> }, "duration": <str>, "explicit": <bool>, "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "isrc": <str>, "key": <str>, "keyScale": <str>, "mediaTags": <list[str]>, "popularity": <float>, "spotlighted": <bool>, "title": <str>, "toneTags": <list[str]>, "version": <str> }, "id": <str>, "relationships": { "albums": { "links": { "self": <str> } }, "artists": { "links": { "self": <str> } }, "genres": { "links": { "self": <str> } }, "lyrics": { "links": { "self": <str> } }, "owners": { "links": { "self": <str> } }, "providers": { "links": { "self": <str> } }, "radio": { "links": { "self": <str> } }, "shares": { "links": { "self": <str> } }, "similarTracks": { "links": { "self": <str> } }, "sourceFile": { "links": { "self": <str> } }, "trackStatistics": { "links": { "self": <str> } } }, "type": "tracks" } ], "links": { "meta": { "nextCursor": <str> }, "next": <str>, "self": <str> } }
- get_user_saved_videos(*, collection_id: str | None = None, user_id: int | str | None = None, country_code: str | None = None, locale: str | None = None, include_metadata: bool = False, cursor: str | None = None, sort_by: str | None = None, descending: bool | None = None) dict[str, Any][source]¶
User Collection Videos > Get Items Relationship: Get TIDAL catalog information for videos in a user collection․ User Collections > Get Videos Relationship: Get TIDAL catalog information for videos in a user’s collection.
Authorization scope
collection.readscopeRead access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
GET /userCollections/{user_id}/relationships/videosendpoint is used.- Parameters:
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- country_codestr; keyword-only; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".- localestr; keyword-only; optional
IETF BCP 47 language tag.
- include_metadatabool; keyword-only; default:
False Whether to include metadata for the videos in the user’s collection.
- cursorstr; keyword-only; optional
Cursor for fetching the next page of results.
Example:
"3nI1Esi".- sort_bystr; keyword-only; optional
Field to sort the videos by.
Valid values:
"addedAt","artists.name","duration","title".- descendingbool; keyword-only; optional
Whether to sort in descending order.
API default:
False.
- Returns:
- videosdict[str, Any]
Page of TIDAL metadata for the videos in the user’s collection.
Sample response
{ "data": [ { "id": <str>, "meta": { "addedAt": <str> }, "type": "videos" } ], "included": [ { "attributes": { "availability": <list[str]>, "copyright": { "text": <str> }, "duration": <str>, "explicit": <bool>, "externalLinks": [ { "href": <str>, "meta": { "type": <str> } } ], "isrc": <str>, "popularity": <float> "releaseDate": <str>, "title": <str> }, "id": <str>, "relationships": { "albums": { "links": { "self": <str> } }, "artists": { "links": { "self": <str> } }, "providers": { "links": { "self": <str> } }, "thumbnailArt": { "links": { "self": <str> } } }, "type": "videos" } ], "links": { "meta": { "nextCursor": <str> }, "next": <str>, "self": <str> } }
- remove_saved_albums(album_ids: int | str | dict[str, int | str] | Collection[int | str | dict[str, int | str]], /, *, collection_id: str | None = None, user_id: int | str | None = None) None[source]¶
User Collection Albums > Delete from Items Relationship: Remove albums from a user collection․ User Collections > Delete from Albums Relationship: Remove albums from a user’s collection.
Authorization scope
collection.writescopeWrite access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
DELETE /userCollections/{user_id}/relationships /albumsendpoint is used.- Parameters:
- album_idsint, str, dict[str, int | str], or Collection[int | str | dict[str, int | str]]; positional-only
TIDAL IDs and/or resource identifiers of the albums.
Examples:
46369321"251380836"{"id": "46369321", "types": "albums"}["251380836", {"id": "46369321", "types": "albums"}]
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- remove_saved_tracks(track_ids: int | str | dict[str, int | str] | Collection[int | str | dict[str, int | str]], /, *, collection_id: str | None = None, user_id: int | str | None = None) None[source]¶
User Collection Tracks > Delete from Items Relationship: Remove tracks from a user collection․ User Collections > Delete from Tracks Relationship: Remove tracks from a user’s collection.
Authorization scope
collection.writescopeWrite access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
DELETE /userCollections/{user_id}/relationships /tracksendpoint is used.- Parameters:
- track_idsint, str, dict[str, int | str], or Collection[int | str | dict[str, int | str]]; positional-only
TIDAL IDs and/or resource identifiers of the tracks.
Examples:
46369325"75413016"{"id": "46369325", "types": "tracks"}["75413016", {"id": "46369325", "types": "tracks"}]
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- remove_saved_videos(video_ids: str | dict[str, int | str] | Collection[int | str | dict[str, int | str]], /, *, collection_id: str | None = None, user_id: int | str | None = None) None[source]¶
User Collection Videos > Delete from Items Relationship: Remove videos from a user collection․ User Collections > Delete from Videos Relationship: Remove videos from a user’s collection.
Authorization scope
collection.writescopeWrite access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
DELETE /userCollections/{user_id}/relationships /videosendpoint is used.- Parameters:
- video_idsint, str, dict[str, int | str], or Collection[int | str | dict[str, int | str]]; positional-only
TIDAL IDs and/or resource identifiers of the videos.
Examples:
53315642"75623239"{"id": "75623239", "types": "videos"}["53315642", {"id": "75623239", "types": "videos"}]
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- save_albums(album_ids: int | str | dict[str, int | str] | Collection[int | str | dict[str, int | str]], /, *, collection_id: str | None = None, user_id: int | str | None = None, country_code: str | None = None) None[source]¶
User Collection Albums > Add to Items Relationship: Add albums to a user collection․ User Collections > Add to Albums Relationship: Add albums to a user’s collection.
Authorization scope
collection.writescopeWrite access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
POST /userCollections/{user_id}/relationships/albumsendpoint is used.- Parameters:
- album_idsint, str, dict[str, int | str], or Collection[int | str | dict[str, int | str]]; positional-only
TIDAL IDs and/or resource identifiers of the albums.
Examples:
46369321"251380836"{"id": "46369321", "types": "albums"}["251380836", {"id": "46369321", "types": "albums"}]
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- country_codestr; keyword-only; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".
- save_tracks(track_ids: int | str | dict[str, int | str] | Collection[int | str | dict[str, int | str]], /, *, collection_id: str | None = None, user_id: int | str | None = None, country_code: str | None = None) None[source]¶
User Collection Tracks > Add to Items Relationship: Add tracks to a user collection․ User Collections > Add to Tracks Relationship: Add tracks to a user’s collection.
Authorization scope
collection.writescopeWrite access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
POST /userCollections/{user_id}/relationships/tracksendpoint is used.- Parameters:
- track_idsint, str, dict[str, int | str], or Collection[int | str | dict[str, int | str]]; positional-only
TIDAL IDs and/or resource identifiers of the tracks.
Examples:
46369325"75413016"{"id": "46369325", "types": "tracks"}["75413016", {"id": "46369325", "types": "tracks"}]
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- country_codestr; keyword-only; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".
- save_videos(video_ids: str | dict[str, int | str] | Collection[int | str | dict[str, int | str]], /, *, collection_id: str | None = None, user_id: int | str | None = None, country_code: str | None = None) None[source]¶
User Collection Videos > Add to Items Relationship: Add videos to a user collection․ User Collections > Add to Videos Relationship: Add videos to a user’s collection.
Authorization scope
collection.writescopeWrite access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
POST /userCollections/{user_id}/relationships/videosendpoint is used.- Parameters:
- video_idsint, str, dict[str, int | str], or Collection[int | str | dict[str, int | str]]; positional-only
TIDAL IDs and/or resource identifiers of the videos.
Examples:
53315642"75623239"{"id": "75623239", "types": "videos"}["53315642", {"id": "75623239", "types": "videos"}]
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- country_codestr; keyword-only; optional
ISO 3166-1 alpha-2 country code.
Example:
"US".
- unfollow_artists(artist_ids: int | str | dict[str, int | str] | Collection[int | str | dict[str, int | str]], /, *, collection_id: str | None = None, user_id: int | str | None = None) None[source]¶
User Collection Artists > Delete from Items Relationship: Remove artists from a user collection․ User Collections > Delete from Items Relationship: Remove artists from a user’s collection.
Authorization scope
collection.writescopeWrite access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
DELETE /userCollections/{user_id}/relationships /artistsendpoint is used.- Parameters:
- artist_idsint, str, dict[str, int | str], or Collection[int | str | dict[str, int | str]]; positional-only
TIDAL IDs and/or resource identifiers of the artists.
Examples:
1566"4676988"{"id": "1566", "types": "artists"}["4676988", {"id": "46369321", "types": "artists"}]
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.
- unfollow_playlists(playlist_uuids: str | dict[str, str] | Collection[str | dict[str, str]], /, *, collection_id: str | None = None, user_id: int | str | None = None) None[source]¶
User Collection Playlists > Delete from Items Relationship: Remove playlists from a user collection․ User Collections > Remove Playlists from User’s Collection: Remove playlists from a user’s collection.
Authorization scope
collection.writescopeWrite access to a user’s collection.
Important
At most one of collection_id or user_id must be provided. If user_id is provided, the legacy
DELETE /userCollections/{user_id}/relationships /playlistsendpoint is used.- Parameters:
- playlist_uuidsstr, dict[str, str], or Collection[str | dict[str, str]]; positional-only
UUIDs and/or resource identifiers of the playlists.
Examples:
"f0d6f5c4-081f-4348-9b65-ae677d92767b"{ "id": "1e4c73df-b805-47cd-9e44-9a8721c5cb45", "types": "playlists" }
[ "f0d6f5c4-081f-4348-9b65-ae677d92767b", { "id": "1e4c73df-b805-47cd-9e44-9a8721c5cb45", "types": "playlists" } ]
- collection_idstr; keyword-only; optional
TIDAL ID of the user collection. If authenticated,
"me"can be used in lieu of a TIDAL ID for the current user’s collection. If not specified,"me"is used.- user_idint or str; keyword-only; optional
TIDAL ID of the user.