mirror of
https://github.com/NikolaiT/se-scraper.git
synced 2025-08-14 07:48:21 +02:00
added google maps scraper
This commit is contained in:
31
examples/google_maps.js
Normal file
31
examples/google_maps.js
Normal file
@ -0,0 +1,31 @@
|
||||
const se_scraper = require('./../src/node_scraper.js');
|
||||
|
||||
(async () => {
|
||||
let browser_config = {
|
||||
debug_level: 1,
|
||||
output_file: 'examples/results/maps.json',
|
||||
test_evasion: false,
|
||||
block_assets: false,
|
||||
headless: false,
|
||||
|
||||
google_maps_settings: {
|
||||
scrape_in_detail: false,
|
||||
}
|
||||
};
|
||||
|
||||
let scrape_job = {
|
||||
search_engine: 'google_maps',
|
||||
keywords: ['Berlin Zahnarzt'],
|
||||
num_pages: 1,
|
||||
};
|
||||
|
||||
var scraper = new se_scraper.ScrapeManager(browser_config);
|
||||
|
||||
await scraper.start();
|
||||
|
||||
var results = await scraper.scrape(scrape_job);
|
||||
|
||||
console.dir(results, {depth: null, colors: true});
|
||||
|
||||
await scraper.quit();
|
||||
})();
|
Reference in New Issue
Block a user