14 KiB
Change log
5.0.2 (Jan 2021)
- Fix: Make
transferMyPlaybacknot require theoptionsobject, since it should be optional. Thanks for the heads-up @Simber1!
5.0.1 (Jan 2021)
- Fix error handling in the HTTP client. Thanks @yamadapc!
- This package can currently not be built on Node 15 on Linux, due to a dependency not being available yet. Issue can be followed on the node-canvas issue tracker. In the mean time, Travis CI will run on earlier versions of Node.
5.0.0 (Oct 2020)
- BREAKING CHANGES.
-
Arguments for some API methods have changed, causing incorrect behaviour using argument order from version 4.x. See the
README.mdfor examples of how the methods can be used.- Create Playlist (
createPlaylist) method no longer accepts auserIdstring as its first argument. - Transfer A User's Playback (
transferMyPlayback) method takes adeviceIdsarray as its first argument. - Skip to Previous (
skipToPrevious) method takes anoptionsobject as its first argument. - Skip to Next (
skipToNext) method takes anoptionsobject as its first argument. - Set Repeat Mode on the Current User's Playback (
setRepeat) method takes astatestring as its first argument. - Set Shuffle Mode on the Current User's Playback (
setShuffle) method takes astatestring as its first argument.
Cheers @marinacrachi for the createPlaylist update.
- Create Playlist (
-
Removed legacy support for not passing an
optionsobject while providing a callback method. This was only supported on a few of the older endpoints, and could lead to tricky bugs. The affected endpoints aregetTrack,getTracks,getAlbum,getAlbums, andcreatePlaylist. Again, check theREADME.mdfor examples on how these methods can be used if needed. -
Removed
optionsargument for retrieving an access token using the Client Credentials flow,clientCredentialsGrant. -
API errors come in five different flavours.
- WebapiRegularError - For errors returned by most API endpoints.
- WebapiPlayerError - For errors returned by the Player API. These contain a bit more information.
- WebapiAuthenticationError - For errors related to authentication.
- WebapiError - For errors that come from the Web API that didn't fit into one of the above.
- TimeoutError - For network timeout errors.
More importantly, errors now contain the response body, headers, and status code. One side-effect of this is that rate limited requests can be handled by checking the
Retry-Afterheader. Thanks for the PRs @kauffecup, @lantelyes, @dkliemsch, and @erezny.Much appreciated @konstantinjdobler for updates to the Player API errors.
-
- Added support for Implicit Grant flow - Thanks @gaganza, @reblws and @noahp78!
- Starts or Resumes the Current User's Playback (
play) method now supports theposition_msoption. Thanks @alqubo, @koflin, @DoctorFishy. Thanks @carmilso for general improvements to the Player API methods. - Binding for Add an Item to the User's Playback Queue endpoint added. Thanks @thattomperson and @AriciducaZagaria!
- Binding for all Shows and Episodes endpoints. Thanks a lot @andyruwruw!
- Documentation updates to keep up to date with ES6, thanks @dandv! Other documentation improvements by @terensu-desu, and examples by @dersimn. Thanks!
- Bumped dependencies to resolve critical security issues.
- Finally, hat off to @dersimn. Thanks for collecting all of the lingering PRs and merging them into a working and up-to-date fork. You really stepped up.
Likely more changes coming before release to npm, which will happen shortly.
4.0.0 (14 Sep 2018)
- Modified functions that operate on playlists to drop the user id parameter. This is a breaking change. PR
- Updated superagent to fix a security warning PR
- Fixed a bug by which an empty user was not handled properly in getUserPlaylists(). PR
3.1.1 (29 Apr 2018)
- Modernized stack for a better developer experience. Integrated prettier and jest. This simplifies the amount of dev dependencies.
- Improved calls to save and remove saved tracks by adding a key as specified in the Spotify docs (See PR). Thanks to @yanniz0r and @adcar for bringing it up.
3.1.0 (26 Apr 2018)
- Added support for seeking and setting volume. Thanks to @isokar, @jamesemwallis, @ashthespy, and @vanderlin for your PRs.
3.0.0 (8 Mar 2018)
- @DalerAsrorov added support for uploading a custom image to a playlist in this PR.
- You can now pass a
device_idwhen playing and pausing playback. @pfftdammitchris started a PR to add device_id to the play() method. The changes served to another PR where we included the functionality. Thanks! - Added documentation in the README for
getMyCurrentPlaybackState(). Thanks @PanMan for your PR! - @brodin realized we there was a lot of duplicated code and refactored it in a great PR.
2.5.0 (4 Sep 2017)
- Change README to reflect new authorization. Thanks @arirawr for the PR.
- Add support for 'show_dialog' parameter when creating authorization url. Thanks @ajhaupt7 for the PR.
- Add support for playback control (play, pause, prev, next), shuffle and repeat. Thanks @JoseMCO for the PR.
- Add support for currently playing. Thanks @dustinblackman for the PR.
- Fix to remove unnecessary deviceIds parameter from request to transfer playback. Thanks @philnash for the PR.
2.4.0 (2 May 2017)
- Change
addTracksToPlaylistto pass the data in the body, preventing an issue with a long URL when passing many tracks. Thanks @dolcalmi for the PR - Add support for fetching recently played tracks. Thanks @jeremyboles for the PR.
2.3.6 (15 October 2016)
- Add language bindings for the Get Audio Analysis for a Track endpoint.
2.3.5 (20 July 2016)
- Use
encodeURIComponentinstead ofencodeURIto encode the user's id. 'encodeURI' wasn't encoding characters like/or#that were generating an invalid endpoint url. Thanks @jgranstrom for the PR.
2.3.4 (18 July 2016)
- Fixed a bug in
clientCredentialsGrant().
2.3.3 (18 July 2016)
- Migrated to the
superagentrequest library to support Node.JS and browsers. Thanks @SomeoneWeird for the PR to add it, and @erezny for reporting bugs.
2.3.2 (10 July 2016)
- Add language bindings for Get a List of Current User's Playlists. Thanks @JMPerez and @vinialbano.
2.3.1 (3 July 2016)
- Fix for
getRecomendationsmethod causing client error response from the API when making the request. Thanks @kyv for reporting, and @Boberober and @JMPerez for providing fixes.
2.3.0 (2 April 2016)
- Add language bindings for Get Recommendations Based on Seeds, Get a User's Top Artists and Tracks, Get Audio Features for a Track, and Get Audio Features for Several Tracks. Read more about the endpoints in the links above or in this blog post.
- Add generic search method enabling searches for several types at once, e.g. search for both tracks and albums in a single request, instead of one request for track results and one request for album results.
2.2.0 (23 November 2015)
- Add language bindings for Get User's Saved Albums and other endpoints related to the user's saved albums.
2.1.1 (23 November 2015)
- Username encoding bugfix.
2.1.0 (16 July 2015)
- Add language binding for Get Followed Artists
2.0.2 (11 May 2015)
- Bugfix for retrieving an access token through the Client Credentials flow. (Thanks Nate Wilkins!)
- Add test coverage and Travis CI.
2.0.1 (2 Mar 2015)
- Return WebApiError objects if error occurs during authentication.
2.0.0 (27 Feb 2015)
- Breaking change: Response object changed. Add headers and status code to all responses to enable users to implement caching.
1.3.13 (26 Feb 2015)
- Add language binding for Reorder tracks in a Playlist
1.3.12 (22 Feb 2015)
- Add language binding for Remove tracks in a Playlist by Position
1.3.11
- Add Search for Playlists endpoint.
1.3.10
- Add market parameter to endpoints supporting Track Relinking.
- Improve SEO by adding keywords to the package.json file. ;-)
1.3.8
- Add Get a List of Categories, Get a Category, and Get A Category's Playlists endpoints.
1.3.7
- Add Check if Users are Following Playlist endpoint.
1.3.5
- Add missing options parameter in createPlaylist (issue #19). Thanks for raising this allinallin.
1.3.4
- Add Follow Playlist and Unfollow Playlist endpoints.
1.3.3
1.3.2
- Add ability to use callback methods instead of promise.
1.2.2
- Bugfix. api.addTracksToPlaylist tracks parameter can be a string or an array. Thanks ofagbemi!
1.2.1
- Add Follow endpoints. Great work JMPerez.
1.1.0
- Add Browse endpoints. Thanks fsahin.
1.0.2
- Specify module's git repository. Thanks vincentorback.
1.0.1
- Allow options to be set when retrieving a user's playlists. Thanks EaterOfCode.
1.0.0
- Add Replace tracks in a Playlist endpoint
- Add Remove tracks in a Playlist endpoint
- Return errors as Error objects instead of unparsed JSON. Thanks niftylettuce.
0.0.11
- Add Change Playlist details endpoint (change published status and name). Gracias JMPerez.
0.0.10
- Add Your Music Endpoints (Add tracks, Remove tracks, Contains tracks, Get tracks).
- Documentation updates (change scope name of playlist-modify to playlist-modify-public, and a fix to a parameter type). Thanks JMPerez and matiassingers.
0.0.9
- Add Related artists endpoint