Skip to content

Repository files navigation

🌾 AgroHelp — Smart Agriculture Marketplace (Demo-Ready SaaS)

AgroHelp is a full-stack agriculture marketplace platform designed for farmers, sellers, and buyers in India. It supports crop selling, seed & fertilizer buying, second-hand machinery listings, mandi price tracking, cart & orders, and an AI farming assistant — all with a demo-safe architecture that works even without backend availability.

Built as a startup-style product, deployable today and extensible to full production later.

🚀 Live Features 👨‍🌾 Farmers

Sell crops with price, quantity, quality & location

Browse mandi prices (real API or demo fallback)

View buyer interest via cart/orders

AI chatbot for crop guidance

🏪 Sellers

List seeds & fertilizers

Manage stock & pricing

Receive demo orders from buyers

🧑‍💼 Buyers

Browse crops, machinery, seeds & fertilizers

Add items to a unified cart

Place demo orders (no real payment)

Guest access supported (no login required)

🚜 Machinery Marketplace

Second-hand farm machinery listings

Tractor, rotavator, plough, sprayer, harvester, pump, etc.

Demo listings shown when backend data is unavailable

Cart & order flow supported

🧠 Demo-First Architecture (Important)

AgroHelp is built with a dual-mode design:

Mode Data Source Behavior Demo Mode Frontend demo data App works even if APIs fail Production Mode Backend APIs Real users & real data

✔ No broken pages ✔ No “Failed to fetch” errors ✔ Professional demo experience ✔ Zero rewrite needed later

🛒 Unified Cart System

One cart for:

Crops

Seeds & fertilizers

Machinery

Quantity control

Seller-wise order creation

Demo checkout flow (payment disabled safely)

🤖 AI Farming Assistant

Powered by Google Gemini API

Available to guest users

Demo-safe fallback when API key is missing

Can answer:

Crop selection

Seasonal advice

Fertilizer usage

General farming questions

No API keys are committed to GitHub.

🧩 Tech Stack Frontend

React + Vite

Tailwind CSS

TanStack Query

Context API (Auth & Cart)

Backend

Node.js + Express

MongoDB (Mongoose)

Firebase Admin (optional / production)

AI

Google Gemini API (frontend-only)

🔐 Security & Secrets

All secrets stored in .env (gitignored)

.env.example provided for setup

No API keys committed

Demo mode works without Firebase or payments

📂 Project Structure (Simplified) AgroHelp-main/ ├── client/ │ ├── pages/ │ ├── components/ │ ├── contexts/ │ ├── data/ # Demo fallback data │ └── lib/ ├── server/ │ ├── models/ │ ├── routes/ │ ├── middleware/ │ └── services/ └── README.md

⚙️ Running Locally 1️⃣ Install dependencies npm install

2️⃣ (Optional) Add Gemini API key

Create client/.env:

VITE_GEMINI_API_KEY=your_key_here

3️⃣ Start backend cd server npm run dev

4️⃣ Start frontend npm run dev

App runs on:

http://localhost:8080 (or shown port)

🧪 Demo Behavior You’ll See

Marketplace shows demo items if backend is offline

Cart & checkout always work

Guest users can browse everything

AI chatbot works with or without API key

Clear demo banners where applicable

🛣️ Future Roadmap (Not Implemented Yet)

Real payment gateway (Razorpay / Stripe)

Logistics & delivery tracking

Government mandi API integration

AI price prediction

Farmer analytics dashboard

📌 Why This Project Matters

AgroHelp demonstrates:

Real-world SaaS architecture

Demo-safe design

Secure handling of secrets

Clean separation of frontend & backend

Practical agriculture use-case for India

Ideal for:

College projects

Portfolio showcase

Startup MVP

Hackathons

👤 Author

JAY ANAND GitHub: @Jayanand07

About

AgroHelp is a full-stack agriculture marketplace platform connecting farmers, buyers, and sellers with crops, machinery, seeds, fertilizers, mandi prices, and an AI farming assistant.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages