A modular monolith. An independent core.
The product is one application with reusable packages. Pricing has a small boundary; persistence, authorization and integrations live around it.
Permissions · revisions · transactions
The portable core.
Schema validates estimator documents and references. Engine evaluates definitions and answers with exact monetary arithmetic. Neither needs the web application, database or authentication.
The SDK provides server-side HTTP access and a local calculation facade. It consumes the API and public packages; it does not reach into dashboard state.
Read the architecture referenceThe application.
Next.js handles UI, HTTP and verified sessions. Tenant-scoped services enforce membership, roles and ownership inside PostgreSQL transactions. Organization IDs select resources; they are not credentials.
Customer sessions pin a published revision. Estimates retain answers and results. Audit entries and outbox records commit with writes; a separate PostgreSQL-backed worker delivers webhooks and SMTP.
Entities and lifecyclesSnapshots keep
history honest.
Saving a draft does not change a live estimator. Publishing creates an immutable configuration snapshot. A customer’s in-progress session keeps the revision it opened.
Historical displays and PDFs use retained results. Reproducing arithmetic across engine upgrades also requires archiving the corresponding implementation.
Reproducibility and money semanticsDecisions are
part of the interface.
Why PostgreSQL? Why an integer money representation? Why a controlled formula AST? Nineteen decision records describe the context, chosen approach, alternatives and consequences.
Read the ADRsOPEN SOURCE / OPEN POSSIBILITIES