Skip to content

AskTiba/Hestia

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Hestia Universal Backend API

NestJS Prisma PostgreSQL TypeScript

Hestia is a unified Modular Monolith backend built to serve three distinct frontend applications. By centralizing the API infrastructure, we ensure code reusability (like shared authentication), simplify database management, and streamline CI/CD deployments.

🚀 Projects Served

This single API hub powers the following applications:

  1. 🛒 ShopMaster

    • Focus: Inventory management, barcode scanning, POS, and financial analytics for small businesses.
    • Modules: inventory/, sales/, auth/
  2. 📍 VibeCheck (Coming Soon)

    • Focus: Geospatial discovery engine and community hub for local events and places.
    • Modules: places/, events/, reviews/
  3. 🤝 EliteAid (Coming Soon)

    • Focus: Escrow-based marketplace connecting homeowners with vetted household professionals.
    • Modules: tasks/, safety/, payments/

🏗️ Technical Architecture

This backend is built utilizing enterprise-grade technologies:

  • Framework: NestJS (Node.js)
  • Database: Neon.tech (Serverless PostgreSQL)
  • ORM: Prisma
  • Security: Passport.js + JWT (JSON Web Tokens)
  • Documentation: Built-in Swagger OpenAPI (/api)

Why a Modular Monolith?

Instead of managing three separate microservices, all business logic is isolated into domain-specific modules within one server. This allows:

  • Zero-Cost Scaling: A single Render instance handles all API traffic.
  • Shared Context: Global user authentication and role-based access control (RBAC).
  • Frontend Independence: Frontends are decoupled and live in their own repositories, keeping the client codebases lightweight.

🛠️ Local Development

Prerequisites

  • Bun (JavaScript runtime)
  • A PostgreSQL connection string (via Neon.tech or local Docker)

Installation

  1. Navigate to the backend directory:
    cd backend
  2. Install dependencies:
    bun install
  3. Set up your .env file:
    DATABASE_URL="postgresql://user:password@host/db"
    PORT=3001
  4. Generate the Prisma client:
    bunx prisma generate

Running the App

# Development watch mode
bun run start:dev

# Production mode
bun run build
bun run start:prod

📚 API Documentation

When the server is running, interactive Swagger documentation is automatically generated.

Use the Swagger UI to inspect endpoint schemas, test queries, and verify JSON structures before integrating them into the frontend repositories.

About

Hestia Unified Backend: A professional-grade Modular Monolith powering ShopMaster (Inventory), VibeCheck (Geospatial Discovery), and EliteAid (Marketplace) with NestJS, Prisma 7, and PostgreSQL.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors