2.6.5 • Published 3 years ago

billboard-top-100 v2.6.5

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

Node.js API to retrieve top songs, albums, and artists from Billboard's charts

npm.io contributions welcome npm.io

install

npm install billboard-top-100

example

getChart

const { getChart } = require('billboard-top-100');

// date format YYYY-MM-DD
getChart('hot-100', '2016-08-27', (err, chart) => {
  if (err) console.log(err);
  // week of the chart in the date format YYYY-MM-DD
  console.log(chart.week);
  // URL of the previous week's chart
  console.log(chart.previousWeek.url);
  // date of the previous week's chart in the date format YYYY-MM-DD
  console.log(chart.previousWeek.date);
  // URL of the next week's chart
  console.log(chart.nextWeek.url);
  // date of the next week's chart in the date format YYYY-MM-DD
  console.log(chart.nextWeek.date);
  // array of top 100 songs for week of August 27, 2016
  console.log(chart.songs);
  // song with rank: 4 for week of August 27, 2016
  console.log(chart.songs[3]);
  // title of top song for week of August 27, 2016
  console.log(chart.songs[0].title);
  // artist of top songs for week of August 27, 2016
  console.log(chart.songs[0].artist);
  // rank of top song (1) for week of August 27, 2016
  console.log(chart.songs[0].rank);
  // URL for Billboard cover image of top song for week of August 27, 2016
  console.log(chart.songs[0].cover);
  // position info of top song
  console.log(chart.songs[0].position.positionLastWeek);
  console.log(chart.songs[0].position.peakPosition);
  console.log(chart.songs[0].position.weeksOnChart);
});

// chartName defaults to hot-100
// date defaults to Saturday of this week
getChart((err, chart) => {
  if (err) console.log(err);
  console.log(chart);
});

// date defaults to Saturday of this week
getChart('rock-digital-song-sales', (err, chart) => {
  if (err) console.log(err);
  console.log(chart);
});

listCharts

// list all charts
const { listCharts } = require('billboard-top-100');

listCharts((err, charts) => {
  if (err) console.log(err);
  // array of all charts
  console.log(charts);
});

license

MIT © Rishi Masand

donation

If you find billboard-top-100 useful and would like to support the developer, please consider donating. Thank you.

paypal

2.6.3

3 years ago

2.6.5

3 years ago

2.6.4

3 years ago

2.6.1

3 years ago

2.6.0

3 years ago

2.6.2

3 years ago

2.5.9

5 years ago

2.5.8

5 years ago

2.5.7

6 years ago

2.5.6

6 years ago

2.5.5

6 years ago

2.5.4

6 years ago

2.5.2

6 years ago

2.5.0

6 years ago

2.4.19

6 years ago

2.4.18

6 years ago

2.4.17

6 years ago

2.4.16

6 years ago

2.4.15

6 years ago

2.4.14

6 years ago

2.4.13

6 years ago

2.4.12

6 years ago

2.4.11

6 years ago

2.4.10

6 years ago

2.4.8

6 years ago

2.4.7

6 years ago

2.4.6

6 years ago

2.4.5

6 years ago

2.4.4

6 years ago

2.4.3

6 years ago

2.4.2

6 years ago

2.4.1

6 years ago

2.4.0

6 years ago

2.3.0

6 years ago

2.2.0

7 years ago

2.1.3

7 years ago

2.1.2

7 years ago

2.1.1

7 years ago

2.1.0

7 years ago

2.0.9

7 years ago

2.0.8

8 years ago

2.0.7

8 years ago

2.0.6

9 years ago

2.0.5

9 years ago

2.0.4

9 years ago

2.0.3

9 years ago

2.0.2

9 years ago

2.0.0

9 years ago

1.1.0

9 years ago

1.0.9

9 years ago

1.0.8

9 years ago

1.0.7

9 years ago

1.0.6

9 years ago

1.0.5

9 years ago

1.0.4

9 years ago

1.0.3

9 years ago

1.0.2

9 years ago

1.0.1

9 years ago

1.0.0

9 years ago