new TrackManager( spotify )

Description

Manages spotify tracks.

Parameters
Name Type Description
spotify Spotify

The spotify client.

Details

Members


spotify :Spotify

Description

The spotify client.

Details

audio :Audio

Description

The audio features.

Details

Methods


get( id ) → {Promise.<(Track|HTTPError|ApiError)>}

Description

Get Spotify catalog information for a single track identified by its unique Spotify ID.

Parameters
Name Type Description
id string

The Spotify ID for the track.

Returns
Details

saved( options ) → {Promise.<(Array.<Track>|HTTPError|ApiError)>}

Description

Get a list of the songs saved in the current Spotify user's 'Your Music' library.

Parameters
Name Type Description
options LimitOptions
Returns
Details

save( ids ) → {Promise.<(Status|HTTPError|ApiError)>}

Description

Save one or more tracks to the current user's 'Your Music' library.

Parameters
Name Type Description
ids string | Array.<string>

A list of the Spotify IDs.

Returns
Details

remove( ids ) → {Promise.<(Status|HTTPError|ApiError)>}

Description

Remove one or more tracks from the current user's 'Your Music' library.

Parameters
Name Type Description
ids string | Array.<string>

A list of the Spotify IDs.

Returns
Details

starred( ids ) → {Promise.<(Array.<boolean>|HTTPError|ApiError)>}

Description

Check if one or more tracks is already saved in the current Spotify user's 'Your Music' library.

Parameters
Name Type Description
ids string | Array.<string>
Returns
Details

Description

Get Spotify catalog information about tracks.

Parameters
Name Type Description
query string

Your search query.

options SearchOptions
Returns
Details

recommendations( options ) → {Promise.<(Array.<Tracks>|HTTPError|ApiError)>}

Description

Recommendations are generated based on the available information for a given seed entity and matched against similar artists and tracks.

Parameters
Name Type Description
options RecommendedOptions
Returns
Details