Giter Club home page Giter Club logo

e-scraper's Introduction

E-Commerce Scraper

Collect product and reviews from a different e-commerce stores.

Note that current repo is in its early stages

If you like this tool then please Star it

Supported Stores

Features

  • Scrape products
  • Scrape reviews by product Id

To Do

  • Add proxy support
  • Run from the CLI
  • Save output to the CSV/JSON files
  • Add more stores

Possible errors

  • If there will be let me know

Installation

Install from NPM

$ npm i e-scraper

Install from YARN

$ yarn add e-scraper

USAGE

Module

Options

const options = {
    // Store name
    // Supported stores: Target
    store: "Target",

    // When you search for a product, you need to specify keyword value
    keyword: 'xbox',
    
    // When you need to collect reviews, you need to specific productId value
    productId: '334343',

    // Number of products or reviews to collect
    number: 50,
    
    // Number of products or reviews to skip
    offset: 50,
    
    // Set store ID
    // Some stores can have different store Id values
    // Default {storeId} value for a Target is 3991
    storeId: 3991,
    
    // Include in search result promoted values
    // Some stores can include promoted products in to the response
    // Target does support this option
    // Default {sponsoredProducts} is 1
    sponsoredProducts: 1,
};
const { product, reviews } = require('e-scraper');

(async () => {
    try {
        // Collect products
        const products = await product({ store: 'Target' keyword: 'Xbox ', number: 50 });
        // Collect reviews
        const reviews = await reviews({ store: 'Target', productId: '232323', number: 50 });

    } catch (error) {
        console.log(error);
    }
})();

JSON output:

{
    total: '829',
    has_more: true,
    next: 91,
    output: [{Reviews, Products...}]
}

License

MIT

Free Software

e-scraper's People

Contributors

drawrowfly avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.