Open Source
Storefront API
Sep 2023 – Feb 2024GitHub
On this page
Overview
A production-ready REST API for e-commerce with multi-tenant support, role-based access, inventory management, and Stripe payment integration.
Designed around a multi-tenant architecture so a single deployment can power multiple storefronts with isolated data. Features JWT + refresh-token auth, rate limiting per tenant, a full product/inventory model, order lifecycle management, and Stripe webhook handling for payment reconciliation.
- Node.js
- TypeScript
- PostgreSQL
- Prisma
- Redis
- Stripe
- Docker
- Jest
Case Study
Situation
Multiple client projects needed an e-commerce back-end. Copy-pasting and adapting the same codebase each time was unsustainable.
Task
Design a reusable, multi-tenant API that any storefront can plug into without bespoke backend work.
Action
Built a tenant-scoped data model in PostgreSQL using Prisma. Added a Redis-backed rate limiter scoped per tenant API key, Stripe webhook handlers with idempotency keys, and a full test suite with Jest and Supertest.
Result
Used as the backend for three client projects. Reduced new storefront setup time from two weeks to under two days.