Skip to content

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

INVNTRY — Inventory & Order Management System

A full-stack Inventory & Order Management System built with FastAPI, React, and PostgreSQL, fully containerized with Docker.

Live Deployment

Link
🌐 Frontend https://inventory-system-chi-sage.vercel.app
⚙️ Backend API https://inventory-system-p1zk.onrender.com
📖 API Docs (Swagger) https://inventory-system-p1zk.onrender.com/docs
🐳 Docker Hub Image https://hub.docker.com/r/utkarshr2112/inventory-backend/tags
💻 GitHub Repository https://github.com/utkarsh21123/inventory-system

Tech Stack

Layer Technology
Frontend React 18, React Router v6, Axios
Backend Python 3.11, FastAPI, SQLAlchemy 2, Pydantic v2
Database PostgreSQL 15
Containers Docker, Docker Compose
Frontend Server Nginx (production)

Features

  • Products — Create, read, update, delete. Unique SKU enforcement. Stock tracking.
  • Customers — Create, read, delete. Unique email enforcement.
  • Orders — Create with multiple line items. Auto-calculates total. Reduces stock on creation. Restores stock on cancellation.
  • Dashboard — Summary stats: total products, customers, orders, low-stock alerts (≤10 units).
  • Business logic — Insufficient stock prevents order placement. All inputs validated server-side.

Running Locally with Docker Compose

1. Clone the repo

git clone https://github.com/utkarsh21123/inventory-system.git
cd inventory-system

2. Configure environment

cp .env.example .env

3. Start all services

docker compose up --build
Service URL
Frontend http://localhost:3000
Backend API http://localhost:8000
API Docs (Swagger) http://localhost:8000/docs

4. Stop

docker compose down

API Reference

Products

Method Endpoint Description
GET /products List all products
POST /products Create a product
GET /products/{id} Get product by ID
PUT /products/{id} Update product
DELETE /products/{id} Delete product

Customers

Method Endpoint Description
GET /customers List all customers
POST /customers Create a customer
GET /customers/{id} Get customer by ID
DELETE /customers/{id} Delete customer

Orders

Method Endpoint Description
GET /orders List all orders
POST /orders Create an order
GET /orders/{id} Get order by ID
DELETE /orders/{id} Cancel/delete order

Dashboard

Method Endpoint Description
GET /dashboard Stats + low-stock list

Docker Hub

docker pull utkarshr2112/inventory-backend:latest

Project Structure

inventory-system/ ├── backend/ │ ├── app/ │ │ ├── core/database.py │ │ ├── models/models.py │ │ ├── schemas/schemas.py │ │ ├── routes/products.py │ │ ├── routes/customers.py │ │ ├── routes/orders.py │ │ ├── routes/dashboard.py │ │ └── main.py │ ├── requirements.txt │ └── Dockerfile ├── frontend/ │ ├── src/ │ │ ├── components/layout/Sidebar.js │ │ ├── pages/Dashboard.js │ │ ├── pages/Products.js │ │ ├── pages/Customers.js │ │ ├── pages/Orders.js │ │ ├── services/api.js │ │ └── App.js │ └── Dockerfile ├── docker-compose.yml ├── .env.example └── README.md

Releases

Packages

Contributors

Languages