REST API for Stockwise — Order & inventory management for African WhatsApp sellers. Built with Node.js, TypeScript, Express, Prisma & PostgreSQL.
# Stockwise API
> **Order management backend for African WhatsApp sellers**
> Bridge between informal WhatsApp selling and structured business management.
---
## Overview
Stockwise is a lightweight order management API built for online sellers in francophone Africa who operate primarily through WhatsApp Business. The product bridges the gap between informal WhatsApp selling and structured business management — without changing how sellers work.
**The core insight:** The problem is not the sale. The problem is tracking what happens after the WhatsApp conversation.
### What Stockwise solves
- Orders getting lost in WhatsApp threads
- Stock managed from memory or spreadsheets
- No real revenue visibility
- No way to identify unreliable customers
---
## Features
| Feature | Description |
| ------------------------ | ------------------------------------------------------------------------------- |
| **OAuth Authentication** | Google & Facebook OAuth2 — zero passwords stored |
| **Customer Management** | Create clients with name and/or WhatsApp number — order history auto-calculated |
| **Product Catalog** | Name, photo, price, stock tracking with alert thresholds |
| **Order Management** | Multi-product cart, status transitions, automatic stock logic |
| **WhatsApp Summary** | Auto-generated order recap ready to copy-paste into WhatsApp |
| **Dashboard & KPIs** | Real revenue, conversion rate, top products, critical stock |
| **PDF & Excel Reports** | Filterable exports by date, status, product, customer |
| **Monitoring** | Sentry error tracking + Winston structured logs + UptimeRobot |
---
## Tech Stack
**Runtime & Language**
- Node.js 20 LTS + TypeScript 5 (strict mode)
**Framework …