Track class

Json representation of a track

Implemented types
Annotations
  • @JsonSerializable(createToJson: false)

Constructors

Track()
Track.fromJson(Map<String, dynamic> json)
factory

Properties

album AlbumSimple?
The album on which the track appears. The album object includes a link in href to full information about the album.
getter/setter pair
artists List<Artist>?
The artists who performed the track. Each artist object includes a link in href to more detailed information about the artist.
getter/setter pairoverride
availableMarkets List<Market>?
A list of the countries in which the track can be played, identified by their ISO 3166-1 alpha-2 code.
getter/setter pairoverride
discNumber int?
The disc number (usually 1 unless the album consists of more than one disc)
getter/setter pairoverride
duration Duration?
The track length
no setteroverride
durationMs int?
The track length in milliseconds.
getter/setter pairoverride
explicit bool?
Whether or not the track has explicit lyrics (true = yes it does; false = no it does not OR unknown).
getter/setter pairoverride
externalIds ExternalIds?
Known external IDs for this track.
getter/setter pair
externalUrls ExternalUrls?
Known external URLs for this track.
getter/setter pairoverride
hashCode int
The hash code for this object.
no setterinherited
href String?
A link to the Web API endpoint providing full details of the track.
getter/setter pairoverride
id String?
The Spotify ID for the track.
getter/setter pairoverride
isPlayable bool?
Part of the response when Track Relinking is applied. If true, the track is playable in the given market. Otherwise false.
getter/setter pairoverride
linkedFrom TrackLink?
Part of the response when Track Relinking is applied and is only part of the response if the track linking, in fact, exists. The requested track has been replaced with a different track. The track in the linked_from object contains information about the originally requested track.
getter/setter pairoverride
name String?
The name of the track.
getter/setter pairoverride
popularity int?
The popularity of the track. The value will be between 0 and 100, with 100 being the most popular.
getter/setter pair
previewUrl String?
A URL to a 30 second preview (MP3 format) of the track. null if not available.
getter/setter pairoverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
trackNumber int?
The number of the track. If an album has several discs, the track number is the number on the specified disc.
getter/setter pairoverride
type String?
The object type: "track".
getter/setter pairoverride
uri String?
The Spotify URI for the track.
getter/setter pairoverride

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited