azlyrics-scraper

1.0.6 • Public • Published

AzlyricsScraper

Search and Scrape lyric from Azlyrics.com using Node

GitHub license GitHub release Dependencies Maintenance Open Issues

Quick Start

const scraper = require("azlyrics-scraper");
// Or use ES6 import
import scraper from "azlyrics-scraper";
 
/* <> Required
 * [] Optional
 */
scraper.search(<Title>).then(result => {
    console.log(result);
}).catch(error => {
    // Error handling here
});
 
scraper.getLyric(<Title>).then(result => {
    console.log(result.join(""));
}).catch(error => {
    // Error handling here
});
 
scraper.getLyricFromLink(<URL>).then(result => {
    console.log(result.join(""));
}).catch(error => {
    // Error handling here
});
 
scraper.hotSongs().then(result => {
    console.log(result.join(""));
}).catch(error => {
    // Error handling here
});
 
scraper.randomArtist([First Letter/Number]).then(result => {
    console.log(result);
}).catch(error => {
    // Error handling here
});
 
scraper.randomSong().then(result => {
    console.log(result);
}).catch(error => {
    // Error handling here
});

Docs

search(query): Returns an array of search results from Azlyrics. returns Promise(result<Array>, error)
getLyric(query): Returns an array of queried lyrics. returns Promise(result<Array>, error)
getLyricFromLink(uri): Must Azlyrics URI Returns an array of queried lyrics. returns Promise(result<Array>, error)
hotSongs(): Returns an array of current hot songs. returns Promise(result<Array> { title, url }, error)
randomArtist(): Returns a url to a random artist on Azlyrics. returns Promise(result<String>, error)
randomSong(): Returns a object to a random song lyric from Azlyrics. returns Promise(result<Object> { title, url }, error)

License

This project is using MIT License, © Edqe14. Read Here

/azlyrics-scraper/

    Package Sidebar

    Install

    npm i azlyrics-scraper

    Weekly Downloads

    2

    Version

    1.0.6

    License

    MIT

    Unpacked Size

    15.5 kB

    Total Files

    10

    Last publish

    Collaborators

    • edqe