/Resources
/Introduction
/How to Contribute
/Project Structure

Project Structure

Quick overview of the monorepo organization - apps, packages, and tools.

A modern monorepo with clear separation between apps, shared packages, and development tools.

Tech Stack

See Tech Stack for technology details.

Quick Overview

reloop/
├── apps/
│   ├── backend/         # ElysiaJS microservices
│   │   ├── api-key/     # API key management
│   │   ├── auth/        # Better Auth service
│   │   ├── billing/     # Stripe billing service
│   │   ├── contacts/    # Contact segmentation
│   │   ├── domain/      # Domain & DNS validations
│   │   ├── email/       # Direct transactional mail
│   │   ├── kumomta/     # Kumomta MTA logging
│   │   ├── kumomta-smtp/# SMTP protocol service
│   │   ├── logs/        # Clickhouse event logging
│   │   ├── mailing/     # Campaign delivery queues
│   │   ├── template/    # Visual template builder
│   │   ├── upload/      # File & S3 upload manager
│   │   ├── webhook/     # Webhook dispatching handlers
│   │   └── workflow/    # Automation workflows
│   └── frontend/        # Next.js applications
│       ├── dashboard/   # Core customer dashboard
│       ├── docs/        # Public MDX docs (this app)
│       └── web/         # Public marketing website
├── packages/            # Shared libraries (@reloop/ui, @reloop/db, etc.)
└── package.json         # Workspace scripts & dependencies

Frontend Applications

We maintain three user-facing applications inside the monorepo:

Backend API Microservices

Our modular backend architecture consists of 14 dedicated ElysiaJS microservices inside apps/backend/. These coordinate via a NATS pub-sub bus and BullMQ background queues:

Shared Packages

Shared libraries inside /packages ensure consistent types, schemas, and logic across the entire repository:

Configuration Tooling

Global settings and development pipelines are kept unified under dedicated directories:

Key Benefits of this Monorepo Structure

  • Typesafe Contract (Zero-overhead APIs): Drizzle database schemas, UI components, and TypeScript interfaces are shared directly between frontend applications and backend microservices, ensuring absolute compile-time type safety.
  • Fast Build Caching (Turborepo): Build and lint processes are optimized globally. Unchanged packages leverage fast local and cloud caches, reducing build times to near-instant.
  • Unified Code Style: A global Biome layout enforces extremely fast formatting, import sorting, and linting rules across all workspaces.
  • Modular Abstraction: Each backend feature functions as a decoupled microservice, allowing developer teams to scale and deploy distinct modules without interference.