2.0.5 • Published 1 year ago

jetwebsearch v2.0.5

Weekly downloads
-
License
ISC
Repository
github
Last release
1 year ago

jetwebsearch

Google and Bing search wrapper. Asychronously retrieves multiple pages of either a Bing or Google search and returns them as a simple array of result objects. More data like image searches is in the works for a future release!.

The googleSearch method takes two parameters. First the term which can be any syntax allowed by Google or Bing depending on which search you are doing. Second is the number of pages you want returned. You do a Microsoft Bing search (bingSearch(term, pages)) with the same parameters.

The search methods return a promise, so either async await or val.then() must be used.

Example usage

npm install jetwebsearch

import { googleSearch, bingSearch } from 'jetwebsearch';

const googleResults = await googleSearch('yamaha xt500', 2); console.log(googleResults);

const bingResults = await bingSearch('yamaha xt600', 3); console.log(bingResults);

Example return:

[ OrganicResult { title: 'XT 600 - Barkbusters Moto', description: 'You have selected Yamaha XT 600. SABRE. Single Point Mount. JET. Single Point Mount. Two Point Mount. EGO. Will not fit this model.', url: 'https://barkbusters.net/what-fits-my/yamaha/xt600/', favicons: Object }, OrganicResult { title: 'yamaha xt600', description: 'Front Brake Clutch Levers Replacement for Yamaha YZ80 YZ100 YZ125 TW200 XT225 250 XT250 TTR250 IT125 IT200 XT350 XT600 TT600 MX100 BW200 TT250 TT350,Silver.', url: 'https://www.amazon.com/yamaha-xt600/s?k=yamaha+xt600', favicons: Object } ]

User agents are random to help keep searches anonomous. For better anonimity rotating ip's is required.

2.0.5

1 year ago

2.0.4

1 year ago

2.0.3

1 year ago

2.0.2

1 year ago

2.0.1

1 year ago

2.0.0

1 year ago