spotifywebapipython.models.albumsimplified

@export
class AlbumSimplified:

Spotify Web API Simplified Album object.

AlbumSimplified(root: dict = None)

Initializes a new instance of the class.

Arguments:
  • root (dict): Spotify Web API JSON response in dictionary format, used to load object attributes; otherwise, None to not load attributes.
AlbumType: str

The type of the album.

Allowed values: album, single, compilation.

Example: album

The artists of the album.

Each artist object includes a link in href to more detailed information about the artist.

AvailableMarkets: list[str]

The markets in which the album is available: ISO 3166-1 alpha-2 country codes.

NOTE: an album is considered available in a market when at least 1 of its tracks is available in that market.

Example: ["CA","BR","IT"]

Known external URLs for the album.

Href: str

A link to the Web API endpoint providing full details of the album.

Id: str

The Spotify ID for the album.

Example: 2up3OPMp9Tb4dAKM2erWXQ

The cover art for the album in various sizes, widest first.

ImageUrl: str

Gets the first image url in the Images list, if images are defined; otherwise, null.

Name: str

The name of the album.

In case of an album takedown, the value may be an empty string.

ReleaseDate: str

The date the album was first released.

Example: 1981-12

ReleaseDatePrecision: str

The precision with which release_date value is known.
Allowed values: year, month, day.

Example: year

Included in the response when a content restriction is applied.

TotalTracks: int

The number of tracks in the album.

Type: str

The object type: album.

Uri: str

The Spotify URI for the album.

Example: spotify:album:2up3OPMp9Tb4dAKM2erWXQ

def ToDictionary(self) -> dict:

Returns a dictionary representation of the class.

def ToString(self, includeTitle: bool = True) -> str:

Returns a displayable string representation of the class.

Arguments:
  • includeTitle (str): True to include the class name title prefix.