Outscraper Node Library
The library provides convenient access to the Outscraper API from applications written in server-side JavaScript. Allows using Outscraper's services from your code.
Installation
Install the package with:
npm install outscraper --save
yarn add outscraper
Link to the NPM package page
Initialization
const Outscraper = require('outscraper');
import Outscraper from 'outscraper';
let client = new Outscraper('SECRET_API_KEY');
Link to the profile page to create the API key
Usage
client.googleMapsSearch(['restaurants brooklyn usa'], limit=20, language='en', region='us').then(response => {
console.log(response);
});
(async () => {
const response = await client.googleMapsSearch(['restaurants brooklyn usa'], limit=20, language='en', region='us');
console.log(response);
})();
client.googleMapsSearch(['rChIJrc9T9fpYwokRdvjYRHT8nI4'], language='en').then(response => {
console.log(response);
});
client.googleMapsReviews(['rChIJrc9T9fpYwokRdvjYRHT8nI4'], reviewsLimit=20, language='en').then(response => {
console.log(response);
});
client.emailsAndContacts(['outscraper.com']).then(response => {
console.log(response);
});
More examples
Contributing
Bug reports and pull requests are welcome on GitHub at https://github.com/outscraper/outscraper-node.