pointfy
v2.0.0
Published
A spotify module
Maintainers
Readme
POINTFY
ABOUT
A simple, fast and non-dependant module to interact with the spotify API with NodeJS.
- OOP (Object-oriented programming) module
- Big coverage of the Spotify API (19/84 endpoints - 23%)
- Non-dependant
- Built in TypeScript
Installation
Note: NodeJS 18.0.0 or newer is required
npm install pointfy
git clone https://github.com/hbc-dev/pointfy.gitExample usage
Get an album track list
import { Client, AlbumFactory } from "pointfy";
(async () => {
const client = new Client({
clientId: "123",
clientSecret: "CLIENT_SUPER_SECRET"
});
const album = await AlbumFactory.findAlbumByName(client, "Whole Lotta Red", { artist: "Playboi Carti" });
const tracks = await album.fetchTracks(); // or (await album.fetch()).tracks
const list = tracks.map(t => `${t.track_number} ${t.name} - ${t.id}`).join('\n');
console.log(`Found ${tracks.total} tracks.\n\n${list}`);
});