Skip to content

MongoDB-powered IoT device management solution with real-time status tracking, advanced search, and admin-friendly UI.

Notifications You must be signed in to change notification settings

srinathvv-dev/Gear-Track

Repository files navigation

Device Management System

Project Banner

A comprehensive MongoDB-powered solution for managing IoT sensors and devices with real-time status tracking, search capabilities, and admin-friendly UI.

Features

  • Centralized Device Management: Store all sensor/device information in a MongoDB database
  • Dynamic Status Updates: Real-time status monitoring with instant UI updates
  • Advanced Search: Quickly find devices by type, IP, status, or description
  • Admin Dashboard: Intuitive interface for CRUD operations
  • Custom Fields: Dynamically add new fields to device records
  • Filtering & Sorting: Organize devices by status or alphabetical order
  • Responsive Design: Works on desktop and mobile devices

Tech Stack

Frontend:

  • React.js (with hooks)
  • Tailwind CSS
  • Axios for API calls

Backend:

  • Node.js
  • Express.js
  • MongoDB (with Mongoose ODM)

Installation

Prerequisites

  • Node.js (v16 or higher)
  • MongoDB Atlas account or local MongoDB instance
  • npm or yarn

Setup Instructions

  1. Clone the repository:

    git clone https://github.com/yourusername/iot-device-management.git
    cd iot-device-management
  2. Install dependencies:

    npm install
    # or
    yarn install
  3. Set up environment variables: Create a .env file in the root directory with the following:

    MONGODB_URI=your_mongodb_connection_string
    PORT=3000
    
  4. Start the development server:

    npm run dev
    # or
    yarn dev
  5. Open your browser and navigate to:

    http://localhost:3000
    

API Endpoints

Endpoint Method Description
/api/chat POST Main endpoint for all CRUD operations
Request body should include: { query: 'fetch|create|update|delete', data: {...} }

Usage Guide

Adding a New Device

  1. Fill in the device details in the creation form
  2. Click "Create Sensor"
  3. The new device will appear in the dashboard

Editing a Device

  1. Click the "Edit" button on any device card
  2. Modify the fields as needed
  3. Click "Save Changes"

Adding Custom Fields

  1. Enter field name and value in the "Add Field" section
  2. Click "Add Field"
  3. The field will be added to the current form

Searching and Filtering

  • Use the search bar to find devices by any attribute
  • Select status from the dropdown to filter
  • Choose sort order (A-Z or Z-A)

Project Structure

iot-device-management/
├── client/                   # Frontend React application
│   ├── components/           # Reusable UI components
│   ├── pages/               # Application pages
│   └── ...                  
├── server/                  # Backend server
│   ├── models/              # MongoDB models
│   ├── routes/              # API routes
│   └── ...                  
├── .env.example             # Environment variables template
├── package.json             # Project dependencies
└── README.md                # This file

Contributing

We welcome contributions! Please follow these steps:

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

License

Distributed under the MIT License. See LICENSE for more information.

About

MongoDB-powered IoT device management solution with real-time status tracking, advanced search, and admin-friendly UI.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published