Skip to main content

E-Commerce Scraper

Create an instance of the PyScrappy library to interact with the class ECommerceScraper

Helps in scrapping data from E-Commerce websites

1. Alibaba2. Flipkart3. Snapdeal
  • Type#


    class

  • Note#


    Create an object of this class to procced further.

    obj = PyScrappy.ECommerceScrapper()

Flipkart#

  • flipkart_scrapper()#

    Helps in scraping data from Flikart ('Name', 'Price', 'Original Price', 'Description', 'Rating').

    Return type#


    pandas.DataFrame

    Parameters#


    product_name: Enter the name of the desired product, which you want to scrape the data of
    Type: str

    n_pages: Enter the number of pages that you want to scrape
    Type: int

    Note#


    Both the arguments are a compulsion. If n_pages == 0: A prompt will ask you to enter a valid page number and the scrapper will re-run.

    obj = PyScrappy.ECommerceScrapper()obj.flipkart_scrapper(product_name, n_pages)

Snapdeal#

  • snapdeal_scrapper()#

    Helps in scraping data from Snapdeal ('Name', 'Price', 'Original Price', 'Number of Ratings').

    Return type#


    pandas.DataFrame

    Parameters#


    product_name: Enter the name of the desired product, which you want to scrape the data of
    Type: str

    n_pages: Enter the number of pages that you want to scrape
    Type: int

    Note#


    Both the arguments are a compulsion. If n_pages == 0: A prompt will ask you to enter a valid page number and the scrapper will re-run.

    obj = PyScrappy.ECommerceScrapper()obj.snapdeal_scrapper(product_name, n_pages)

Alibaba#

  • alibaba_scrapper()#

    Helps in scraping data from Alibaba ('Name', 'Number of Items', 'Description', 'Ratings').

    Return type#


    pandas.DataFrame

    Parameters#


    product_name: Enter the name of desired product
    Type: str

    n_pages: Enter the number of pages that you want to scrape
    Type: int

    Note#


    Both the arguments are a compulsion. If n_pages == 0: A prompt will ask you to enter a valid page number and the scrapper will re-run.

    obj = PyScrappy.ECommerceScrapper()obj.alibaba_scrapper(product_name, n_pages)