1.0.0 • Published 2 years ago

@voidpkg/scrapper v1.0.0

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

@voidpkg/scrapper

NPM Version NPM Downloads

Community

If you have any questions or want to help, join our Discord server.

Installation

This is a Node.js module available through the npm registry. Installation is done using the npm install command:

$ npm install @voidpkg/scrapper

Usage

const { Engine } = require('@voidpkg/scrapper');

Engine.google('Void Development', {
    proxies: [
        {
            host: '0.0.0.0',
            port: 8080,
            auth?: {
                username: 'clqu',
                password: '123456'
            }
        }
    ]
}).then(console.log).catch(console.error);

Engine API

/*
    types: 0 = Search, 1 = Suggestions, 2 = Images
*/

Engine.google(query, options, type);
Engine.bing(query, options, type);
Engine.youtube(query, options);
Engine.wikipedia(query, options);

With Constructor

const { Google, Bing, YouTube, Wikipedia } = require('@voidpkg/scrapper');
const proxies = [
    {
        host: '0.0.0.0',
        port: 8080,
        auth?: {
            username: 'clqu',
            password: '123456'
        }
    }
];

const google = new Google({ proxies });
const bing = new Bing({ proxies });
const youtube = new YouTube({ proxies });
const wikipedia = new Wikipedia({ proxies });

// Search
google.search('Void Development').then(console.log).catch(console.error);
bing.search('Void Development').then(console.log).catch(console.error);
youtube.search('Void Development').then(console.log).catch(console.error);
wikipedia.get('Void Development').then(console.log).catch(console.error);

// Suggestions
google.suggestions('Void Development').then(console.log).catch(console.error);
bing.suggestions('Void Development').then(console.log).catch(console.error);

Engines

NameState
Google Search
Google Suggestions
Google Images
Bing Search
Bing Suggestions
Bing Images
Wikipedia Search
YouTube Videos Search

Options

NameRequiredTypeDefault
mktstringen-US
pagenumber1
perPagenumber10
safeoff, active, high, medium, safeUndefinedoff
headers{ key: string: any; }undefined
proxiesproxy[]undefined
queries{ key: string: any; }undefined
NameRequiredTypeDefault
mktstringen-US
pagenumber1
perPagenumber10
safeoff, moderate, strictoff
headers{ key: string: any; }undefined
proxiesproxy[]undefined
queries{ key: string: any; }undefined
NameRequiredTypeDefault
headers{ key: string: any; }undefined
proxiesproxy[]undefined
queries{ key: string: any; }undefined
NameRequiredTypeDefault
languagestringen
headers{ key: string: any; }undefined
proxiesproxy[]undefined
queries{ key: string: any; }undefined
NameRequiredType
hoststring
portnumber
auth{ username: string; password: string; }

How to get free proxies?

License

MIT