Back to Projects

HolaRoof — Roofing CRM Platform

Full-stack B2B SaaS for a roofing business: multi-role RBAC, project configurator with polygon roof measurement, order lifecycle, and multi-currency invoicing with VAT reverse charge. Under NDA — no public demo.

Python 3.12
FastAPI
SQLAlchemy (async)
PostgreSQL 16
Redis
Alembic
Next.js 16
React 19
TypeScript
TanStack Query
TanStack Form
TanStack Table
Zustand
Tailwind CSS 4
Radix UI
Vitest
Playwright
Google OAuth 2.0
Leaflet
React Three Fiber

This project is under NDA. The client demo is private, so this page describes the architecture and engineering decisions without exposing customer data or internal screens.

Overview

HolaRoof is a full-stack CRM platform built for a roofing business that sells, configures, and delivers roofing projects through a network of partners. A single application serves five different audiences — customers, partners, warehouse staff, sales, and delivery workers — each with its own workspace and permissions, plus a superadmin console on top.

The Challenge

The client ran their entire operation on spreadsheets and email: quotes, partner pricing, stock, deliveries, and invoicing all lived in disconnected documents. The goal was one platform that could:

  • Take a customer from a roof measurement to a confirmed order in one flow
  • Give partners their own pricing tiers and order pipelines
  • Track the full order lifecycle from submission to delivery
  • Produce correct multi-currency invoices, including VAT reverse charge cases
  • Stay GDPR-compliant with data export and deletion built in

Solution Architecture

Backend

The backend is Python 3.12 with FastAPI and fully async SQLAlchemy on PostgreSQL 16, with Redis for caching and sessions and Alembic for migrations.

Backend Highlights

  • Session-based auth with account lockout and Google OAuth 2.0
  • Role-based access control across five user roles plus superadmin
  • Full order lifecycle state machine from SUBMITTED to DELIVERED
  • Multi-line invoicing with partner cost splits and VAT reverse charge
  • Multi-currency support with EUR base and 225 VAT code classifications
  • GDPR data export and deletion endpoints
  • Real-time order notifications over Server-Sent Events

Frontend

The frontend is Next.js 16 with React 19, styled with Tailwind CSS 4 and Radix UI, using the TanStack stack (Query, Form, Table) with Zustand for client state.

Roof Configurator

The most distinctive feature is a project configurator with polygon roof measurement: users draw the roof outline on a map (Leaflet), and a geometry service computes areas and material estimates. A React Three Fiber view visualizes the result in 3D.

Quality Bar

The backend ships with 1,234 tests at 100% coverage, running against a real PostgreSQL instance rather than SQLite substitutes. The frontend adds unit tests with Vitest and end-to-end suites with Playwright that auto-start the full service stack. The codebase went through a multi-phase audit covering security, database constraints, and business-logic edge cases.

Lessons Learned

  1. Test against the real database — several invoice-splitting bugs only reproduced on PostgreSQL semantics and would have slipped through SQLite.
  2. Model the order lifecycle as an explicit state machine — it turned dozens of scattered status checks into one auditable transition table.
  3. VAT is a domain of its own — reverse charge, per-country codes, and partner participation splits deserve dedicated modeling from day one.