Overview
Amazon Scraper is a Python-based project designed to extract product data from Amazon, such as titles, prices, reviews, and images. It features a Flask backend for handling data processing and a React frontend for displaying results. The scraper is powered by BeautifulSoup to efficiently gather data.
π Features
Scrape Amazon product details using search queries.
Export data to JSON and CSV formats.
A Flask API to serve scraped data.
A React.js frontend for querying and displaying product data.
ποΈ Project Structure
amazon_scraper/
βββ backend/
β βββ app.py # Flask application
β βββ scraper.py # Scraping logic
β βββ utils.py # Utility functions
β βββ user_queries.json # User input queries
β βββ requirements.txt # Backend dependencies
β βββ output/ # Scraped data storage
β βββ vercel.json # Backend deployment config
βββ frontend/
β βββ public/ # Static frontend files
β βββ src/ # React.js source files
β βββ package.json # Frontend dependencies
β βββ .env # Environment variables
β βββ build/ # Production-ready frontend
π¦ Installation
Backend Setup
Clone the repository:
git clone https://github.com/engrmumtazali0112/python-script-amazon-scrape.git
cd amazon_scraper/backend
Install dependencies:
pip install -r requirements.txt
Run the Flask server:
python app.py
Access the backend at: http://127.0.0.1:5000
Frontend Setup
Navigate to the frontend directory:
cd ../frontend
Install dependencies:
npm install
Start the development server:
npm start
π Deployment
Backend Deployment
Ensure vercel.json is correctly configured.
Deploy to Vercel:
vercel --prod
Frontend Deployment
Build the React app:
npm run build
Deploy to Vercel:
vercel --prod
π Dependencies
Python 3.12
Flask
BeautifulSoup
React.js
Node.js
π License
This project is licensed under the MIT License.
π Follow Us
Made with β€οΈ by Mumtaz Ali
Happy Coding! β¨
Top comments (0)