Case / 03 of 07
Site Master
Configurable software without writing a new application for every client.
Enterprise project under NDA — client and sector withheld.
Context
A multi-tenant platform for running large field programmes where organizations can define their own units, roles, forms, workflows, approval chains and reporting structures.
I built the initial system across the API and both web applications before development continued with another engineer.
System
What I built
- Multi-tenancy
- Organisation management
- Dynamic entities
- Form builder
- Workflow engine
- Approval hierarchies
- Boards
- Gantt views
- Imports
- Reports
- Audit logs
- Dashboards
- Role/ability-based authorization
The hard part
“Configurable” sounds simple until the customer can configure almost everything.
The schema, forms, workflows and approval chains are data.
The challenge is allowing that flexibility without allowing one tenant to see or affect another tenant’s world.
Engineering decisions
- 01
Configuration is data.
Entities, forms, workflows and approval chains are stored and interpreted, not hard-coded per client.
- 02
Ability-based authorization.
CASL abilities decide what each role can see and do, per tenant.
- 03
Tenant isolation as a system property.
Flexibility without one tenant seeing or affecting another tenant’s data.
Shipped
- API
- Two web applications
- Handed over to a second engineer
Stack
- Next.js
- React
- TypeScript
- TanStack Query
- Zustand
- NestJS
- TypeORM
- PostgreSQL
- CASL
- BullMQ
- AMQP
- Turborepo
- Docker
Integrations
- AWS S3
- Razorpay
- Firebase
- PDFKit
- Superset