Skip to content

LackyPal/hungama-music

Repository files navigation

NPM stats Version NPM downloads License npm bundle size NPM collaborators GitHub contributors GitHub stars GitHub last commit (by committer) GitHub issues

hungama-music

Get info and download music from https://hungama.com.

Examples

install

npm i hungama-music

Download audio

const fs = require("fs");
const https = require("https");

(async () => {
  const hungama = require("hungama-music");
  const url = "https://www.hungama.com/song/once-upon-a-time/87546214/";

  const info = await hungama.getInfo(url);
  const streamURL = await hungama.download(info.stream);
  const stream = fs.createWriteStream(`./test/${info.name.replace(/ /g, "_")}.mp3`);

  https.get(streamURL.link, (response) => {
    response.pipe(stream);
  });
})();

Get basic info

const hungama = require("hungama-music");

hungama.getInfo("https://www.hungama.com/song/once-upon-a-time/87546214/")
.then(console.log);

Supporters

Stargazers repo roster

Forkers repo roster

About

Get info and download music from hungama.com

Resources

License

Stars

Watchers

Forks

Packages

No packages published