1.1.9 • Published 3 years ago

enhanced-spotify-api v1.1.9

Weekly downloads
4
License
MIT
Repository
github
Last release
3 years ago

Overview

enhanced-spotify-api is an Object-Oriented API Wrapper aimed to make Spotify's API development fun and painless.

Spend more of your time coding something cool, and less time scouring over documentation.

Table of Contents

Official Website / Documentation

Features

Object oriented wrapper with classes for tracks, artists, playlists, and more

  • Member functions for all relevant endpoints
  • Automatic retrieval of data when needed
  • Minimizing requests made

Providing all the original functionality of spotify-web-api-node.

  • Added missing endpoints for shows and episodes (Just released 3/2020)
  • Fixed known bugs

Add and Override methods

  • Customize to your hearts content
  • I don't know what you need it for, so do your thing my dude.

Quick Start

Via command line

$ npm i enhanced-spotify-api

Import either the entire library

var EnhancedSpotifyAPI = require('enhanced-spotify-api');
EnhancedSpotifyAPI.setAccessToken( myAccessToken );

Or deconstruct what you need

var { Track } = require('enhanced-spotify-api');
Track.setAccessToken( myAccessToken );

All classes have the same authorization methods.

Applying a Spotify access token to one class will authorize the entire library and will not need to be called again.

Instantiate and play!

var playlistID = '6Ibg2aBUp5NP0lAujEGa6p';
var playlist = new Playlist( playlistID );

var tracks = playlist.getTracks();
tracks.play();

var size = playlist.size();

See the official website for more information.

Example

var { Track } = require('enhanced-spotify-api');
Track.setAccessToken( myAccessToken );

var trackID = '3HKpZgez8S4TS2F0sWLvAR';
var track = new Track( trackID );

console.log('My favorite song is', ( await track.getFullObject() ).name);

track.play();

var artists = track.getArtists();

var artist = artists.get(0);

var topTracks = artist.getTopTracks();

Available Classes

Instance and static methods for all endpoints relevent to each item

  • Track
  • Artist
  • Album
  • Playlist
  • Show
  • Episode
  • User
  • Playback
  • Tracks
  • Artists
  • Albums
  • Playlists
  • Shows
  • Episodes
  • Categories
1.1.9

3 years ago

1.1.7

4 years ago

1.1.6

4 years ago

1.1.4

4 years ago

1.1.3

4 years ago

1.1.2

4 years ago

1.1.1

4 years ago

1.1.0

4 years ago

1.0.7

4 years ago

1.0.6

4 years ago

1.0.5

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago

0.1.1

4 years ago

0.1.0

4 years ago

0.0.9

4 years ago

0.0.8

4 years ago

0.0.7

4 years ago

0.0.6

4 years ago

0.0.5

4 years ago

0.0.4

4 years ago

0.0.3

4 years ago

0.0.2

4 years ago

0.0.1

4 years ago