Creates a Deezer album from the data in an API response
the data to use to create the album
Whether the album should be partial
The artist of the album
Whether the album is available
undefined
for partial albums
The contributors to the album
undefined
for partial albums
The album cover available in four sizes
The duration of the album in seconds
undefined
for partial albums
true
if the album contains any explicit lyrics
The list of genres present in this album
undefined
for partial albums
The id of the album
The number of fans the album has
undefined
for partial albums
Signifies that some properties are not populated
Partial albums can be populated by calling DeezerAlbum.fetch.
true
for albums in search results and false
if the album was fetched directly or expanded.
The record type of the album (e.g. EP, ALBUM, etc ...)
The release date of the album
undefined
for partial albums
The title of the album
The list of tracks in the album
empty (length === 0) for partial albums
Use DeezerAlbum.fetch to populate the tracks and other properties
The number of tracks in the album
The type, always 'album'
, useful to determine what the deezer function returned
The universal product code of the album
undefined
for partial albums
The URL to the album on Deezer
Fetches all the tracks in the album and returns them
const album = await play.deezer('album url')
const tracks = await album.all_tracks()
An array of DeezerTrack
Fetches and populates the missing fields including all tracks.
The property DeezerAlbum.partial will be false
if this method finishes successfully.
A promise with the same album this method was called on.
Converts instances of this class to JSON data
JSON data.
Generated using TypeDoc
Class for Deezer Albums