Skip to main content

A Python package to scrape Flipkart product details

Project description

Flipkart Scraper

A Python package to scrape product details such as price, title, rating, and other information from Flipkart.com. This package offers both an all-in-one method for retrieving all product details at once and separate methods for retrieving specific product details.

Features

  • Get product title
  • Get product price
  • Get product rating
  • Get all product details at once

Installation

You can install the abhi-flipkart package using pip:

pip install abhi-flipkart

Requirements Make sure you have the following packages installed:

requests beautifulsoup4 These will be automatically installed with the package.

Usage

from flipkart import FlipkartScraper

# Provide the product URL
product_url = 'https://www.flipkart.com/samsung-galaxy-s23-fe-purple-256-gb/p/itm8f6a49271bf21?pid=MOBGVTA2VGHCJFGG&lid=LSTMOBGVTA2VGHCJFGG1TC2LI&marketplace=FLIPKART&store=tyy%2F4io&srno=b_1_1&otracker=CLP_BannerX3&fm=organic&iid=en_Xqy_OHyrcQALLToVeCOiYi6XfZ1TBn8U_wcElBhYNuR7OzG-guKfCEmcxu3dm4paf1YFLsimTplvCE6DlbZbrvUFjCTyOHoHZs-Z5_PS_w0%3D&ppt=clp&ppn=mobile-phones-store&ssid=stxkg1hx740000001729468470030'

# Create a scraper instance
scraper = FlipkartScraper(product_url)

# Get individual details
title = scraper.get_title()
price = scraper.get_price()
rating = scraper.get_rating()

# Get all details at once
details = scraper.get_all_details()

print(f"Title: {title}")
print(f"Price: {price}")
print(f"Rating: {rating}")
print(f"Details: {details}")

License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

abhi_scraper-1.0.0.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

abhi_scraper-1.0.0-py3-none-any.whl (3.5 kB view details)

Uploaded Python 3

File details

Details for the file abhi_scraper-1.0.0.tar.gz.

File metadata

  • Download URL: abhi_scraper-1.0.0.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.12

File hashes

Hashes for abhi_scraper-1.0.0.tar.gz
Algorithm Hash digest
SHA256 b4cd6d69fc67ad2b112fcb39bee8e2ff9780a804d6ef4f9cc33c6dda3c868565
MD5 0c6ca33bb1992851d0a04166a583a2c4
BLAKE2b-256 8e84503d63c1134b9aab666f4a0ff719214689f84d6b0734146168905e741aa3

See more details on using hashes here.

File details

Details for the file abhi_scraper-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: abhi_scraper-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 3.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.12

File hashes

Hashes for abhi_scraper-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b89cc82acbc044048a1b8fb2e2afab6969ca1be965f637c451fa84aba5a7dcf3
MD5 187e6b0ea5cfa7a09839a7029c65079d
BLAKE2b-256 350cf3cdc49df14e398beae4f8c944bbfb0eee6b51f3f8bf84348fbd8b011f55

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page