Case study
EstateOS
Portfolio stress testing for real estate investors and advisors. Originally built as an internal tool, now being launched as a SaaS platform.
Full-Stack SaaS · Real Estate Technology · Launching Soon
- 25+API Endpoints
- 10Database Tables
- 3Background Workers
Get early access
Join the waitlist to be notified when EstateOS launches.

01 —
Project Overview
EstateOS started as an internal tool built to stress test real estate portfolios against economic scenarios. After proving its value, it's now being developed into a full SaaS platform for investors and advisory firms.
The platform is architected as a monorepo with shared TypeScript packages, ensuring type safety from database queries through API responses to frontend components.
Key technical challenges included building a deterministic financial calculation engine, implementing background job processing for PDF generation, and designing a multi-tenant architecture with plan-based feature gating.
Technical Scope
- Multi-tenant SaaS with tiered subscription plans
- Background job processing with retry logic
- PDF report generation with S3 storage
- Stripe subscription billing with webhook handling
- Token-based portfolio sharing system
- White-label branding capabilities
- Email notification system with preferences
- CSV bulk import with row validation
02 —
Technology Stack
Built on a modern, type-safe foundation designed for reliability and maintainability.
Monorepo
npm workspaces
Shared packages and coordinated buildsFrontend
React + Vite + TypeScript
Type-safe UI with fast HMRBackend
Express.js + TypeScript
RESTful API with strict typingDatabase
PostgreSQL + Drizzle ORM
Type-safe queries and migrationsQueue System
BullMQ + Redis
Background job processingAuthentication
Clerk
OAuth and email auth flowsPayments
Stripe
Subscriptions and webhooksEmail
Resend
Transactional notificationsStorage
AWS S3
Secure document storage
03 —
Security Architecture
Defense-in-depth approach to protecting user data and platform integrity.
Route Protection Middleware
All API endpoints protected with authentication verification before processing requests.Plan-Based Feature Gating
Subscription tier enforcement at the API level prevents unauthorized feature access.Token-Based Sharing
32-byte hex tokens with 30-day expiration for secure, revocable portfolio sharing.Cascade Deletes
Foreign key constraints ensure data integrity and prevent orphaned records.Webhook Signature Verification
Stripe webhook payloads verified before processing payment events.Signed URLs
S3 documents accessed via time-limited signed URLs (24hr expiry).
04 —
Architecture Highlights
Pure TypeScript Math Engine
Zero-dependency calculation package (@estateos/math) for deterministic financial computations including PMT, DSCR, LTV, and Herfindahl index.Background Job Processing
BullMQ workers handle PDF generation, email delivery, and alert creation with exponential backoff retry logic.Data Conventions
Monetary values stored as cents (integers), percentages as basis points (800 = 8%), UUIDs for primary keys.Webhook-Driven Billing
Stripe webhooks handle checkout completion, subscription lifecycle, and payment events with idempotent processing.
05 —
Data Model
PostgreSQL schema designed for multi-tenant isolation and data integrity.
usersportfoliospropertiessnapshotsalertsbrandingemail_preferencesreportsshareswaitlist
Need a custom platform like this?
Whether you need a multi-tenant SaaS platform, secure financial application, or complex data processing system, let's discuss your requirements.