Skip to content
 
 

Repository files navigation

🌾 Khetse — Direct Farmer-to-Consumer Agricultural Marketplace

Flutter CI Flutter SDK Dart GetX Firebase License

Khetse is a modern, cross-platform Flutter application designed to bridge the gap between agricultural producers (farmers) and end consumers or wholesale buyers. By providing real-time Mandi market rates, direct crop ordering, location-based discovery, voice-assisted search, and subscription management, Khetse empowers farmers with fair pricing while providing consumers access to farm-fresh produce.


🎯 Value Proposition & Core Intent

In traditional agricultural supply chains, farmers often lose a significant portion of their revenue to intermediaries and lack access to transparent, real-time market rates. Khetse solves this by delivering an end-to-end digital marketplace:

  • 📈 Real-Time Mandi Rates: Track daily crop prices across regional agricultural markets to make informed sales decisions.
  • 🛒 Direct Crop Ordering: Buyers can browse, search, and place orders directly with farmers without middleman overhead.
  • 🎙️ Voice Search & Localized Discovery: Accessibility-first voice queries (speech_to_text) and location-based nearby market discovery (geolocator).
  • 💎 Premium Memberships: In-app subscription tiers (purchases_flutter / RevenueCat) for advanced market analytics and featured crop listings.

🏗️ Architecture & Module Structure

Khetse strictly implements the GetX Pattern (MVC), decoupling state management, route navigation, and dependency injection across 23 modular domains:

graph TD
    A[App Root / GetMaterialApp] --> B[App Pages / Routes]
    B --> C[Module Binding]
    C --> D[GetxController]
    B --> E[Module View / UI]
    E <--> D
    D <--> F[Services / Firebase & APIs]
    F <--> G[(Cloud Firestore / Remote APIs)]
Loading

Module Directory Overview (lib/app/modules/)

Module Description Key Components
home Main dashboard displaying featured crops & market highlights home_view.dart, home_controller.dart
mandi_rates Real-time Mandi price tracker across commodities & markets mandi_rates_view.dart, mandi_rates_controller.dart
product_detail Detailed crop view with pricing, quantity, & seller details product_detail_view.dart
cart & checkout Shopping cart management & order placement flow cart_controller.dart, checkout_view.dart
orders & order_history Order tracking, status updates, & historical receipts orders_view.dart, order_history_controller.dart
farmer_registration Onboarding flow for local farmers & sellers farmer_registration_view.dart
crop_management Farmer inventory management for listing crops & harvests crop_management_view.dart
voice_search Hands-free speech-to-text crop & market search voice_search_view.dart
location_selection GPS location discovery & manual mandi selection location_selection_controller.dart
subscription In-app subscription tiers & premium plans (RevenueCat) subscription_view.dart
authentication Firebase phone & email authentication flow login_view.dart, auth_controller.dart
profile & settings Account management, app preferences, & localization profile_view.dart, settings_view.dart

💻 Tech Stack


📁 Project Structure

Khetse/
├── .github/
│   ├── ISSUE_TEMPLATE/       # Bug report & feature request templates
│   ├── workflows/            # GitHub Actions CI pipeline
│   ├── CODEOWNERS            # Repository code ownership definition
│   └── dependabot.yml        # Automated dependency updates
├── android/                  # Android native project files
├── ios/                      # iOS native project files
├── web/                      # Web entry points & assets
├── assets/                   # Fonts (DMSans), icons, & images
├── docs/                     # Technical documentation & guides
│   ├── ARCHITECTURE.md       # Detailed GetX architecture breakdown
│   ├── CONTRIBUTING.md       # Contribution guidelines & branch conventions
│   ├── DEVELOPMENT.md        # Local development setup & testing guide
│   ├── GETTING_STARTED.md    # Quickstart guide for new developers
│   ├── SECURITY.md           # Security policy & vulnerability reporting
│   └── FAQ.md                # Frequently asked questions
├── lib/
│   ├── app/
│   │   ├── data/             # Models, providers, & API repositories
│   │   ├── modules/          # 23 GetX feature modules (View, Controller, Binding)
│   │   └── routes/           # Named routes & GetPage definitions
│   ├── core/                 # Shared utilities, constants, & themes
│   └── main.dart             # Application entry point
├── pubspec.yaml              # Flutter project dependencies & configuration
├── .env.example              # Environment variable template
└── README.md                 # Project landing page

🚀 Getting Started

Prerequisites

Ensure you have the following installed on your development system:

  • Flutter SDK: >=3.22.0 (Installation Guide)
  • Dart SDK: >=3.4.0
  • Android Studio / Xcode (for mobile emulator testing)
  • Git

Installation

  1. Clone the repository:

    git clone https://github.com/TheVicky1/Khetse.git
    cd Khetse
  2. Install Flutter dependencies:

    flutter pub get
  3. Configure Environment Variables: Copy .env.example to .env and provide your credentials:

    cp .env.example .env
  4. Add Firebase Configuration:

    • Place google-services.json in android/app/
    • Place GoogleService-Info.plist in ios/Runner/
  5. Run the Application:

    flutter run

🧪 Testing & Quality Assurance

Run static analysis and test suites using the standard Flutter toolchain:

# Analyze codebase for lints & warnings
flutter analyze

# Execute unit and widget tests
flutter test

# Verify production build compilation
flutter build apk --dry-run

📚 Documentation Architecture

For deeper technical details, explore our dedicated guides in docs/:


🤝 Contributing

Contributions are welcome! Please review our Contributing Guide and Code of Conduct before submitting pull requests.

  1. Fork the project repository.
  2. Create your feature branch (git checkout -b feature/amazing-feature).
  3. Commit your changes (git commit -m 'feat: add amazing feature').
  4. Push to the branch (git push origin feature/amazing-feature).
  5. Open a Pull Request.

📄 License

This project is licensed under the MIT License — see the LICENSE file for details.

About

Khetse is a cross-platform Flutter application designed to bridge the gap between agricultural producers and buyers. Built with GetX and Firebase, it features real-time Mandi market price tracking, direct crop ordering, voice-assisted search, location discovery, and RevenueCat in-app subscriptions.

Resources

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages