Track src/structures/Track.ts#L116
Spotify api's track object.
Properties:
album artists availableMarkets discNumber duration explicit externalID externalURL id isLocal isPlayable linkedFrom name popularity previewURL restrictions trackNumber type uriMethods:
makeCodeImageconstructor(data, client) src/structures/Track.ts#L116
No documentation found.
Name | Type | Description |
---|---|---|
data | SimplifiedTrack | Track | The raw data received from the api. |
client | Client | The spotify client. |
.artists src/structures/Track.ts#L17
Type:
The artists who performed the track. Each artist object includes a link in href to more detailed information about the artist.
.availableMarkets src/structures/Track.ts#L22
Type:
A list of the countries in which the track can be played.
.discNumber src/structures/Track.ts#L27
Type:
The disc number (usually 1 unless the album consists of more than one disc).
.explicit src/structures/Track.ts#L37
Type:
Whether or not the track has explicit lyrics ( true = yes it does; false = no it does not OR unknown).
.isPlayable src/structures/Track.ts#L57 OPTIONAL
Type:
Part of the response when Track Relinking is applied. If true , the track is playable in the given market. Otherwise false.
.linkedFrom src/structures/Track.ts#L62 OPTIONAL
Type:
Part of the response when Track Relinking is applied and is only part of the response if the track linking, in fact, exists.
.popularity src/structures/Track.ts#L107 OPTIONAL
Type:
The popularity of the track. The value will be between 0 and 100, with 100 being the most popular. \
.previewURL src/structures/Track.ts#L72
Type:
A URL to a 30 second preview (MP3 format) of the track.
.restrictions src/structures/Track.ts#L77
Type:
Included in the response when a content restriction is applied.
.trackNumber src/structures/Track.ts#L82
Type:
The number of the track. If an album has several discs, the track number is the number on the specified disc.
.makeCodeImage(color) src/structures/Track.ts#L153
Returns a code image url from the spotify uri.
Returns:
Parameters:
Name | Type | Description |
---|---|---|
color | string | The color code in hex. |