Mahbubul Alam.
MAS Formation

MAS Formation

Business formation SaaS for USA LLC & UK LTD registration, built as five separate apps (client site, admin CMS, technical web/mobile/desktop) on one NestJS/GraphQL backend.

Overview

MAS Formation is a business formation SaaS that helps entrepreneurs register a USA LLC or UK LTD company — from initial paperwork through document workflow, payment, and renewal. Rather than one monolithic app, the platform is five separate, purpose-built applications sharing a single NestJS/GraphQL/PostgreSQL backend: a customer-facing website, a Superadmin CMS dashboard, and an internal Technical staff dashboard shipped as its own web app, mobile app, and an early-stage desktop tool — each scoped to exactly what that audience needs, nothing more.

I own the backend architecture and all five frontend surfaces, plus the recurring job of reviewing the ~40-module codebase for business-logic correctness and security as it grows.

Key Features

  • Country → state → package/service pricing catalog, with a separate admin-configurable "Pricing Plan" layer for customizing what customers see per country tab without touching the underlying price data.
  • Server-side price engine — base package price → government fees → selected add-on services → state fee (only where applicable) → coupon/offer discount — computed fresh on every order, never trusted from the client.
  • Order lifecycle with state/country uniqueness rules (one active order per company per state, country-level for jurisdictions with no state fee like the UK/UAE), renewals, and a document workflow that tracks each service from submitted through received to auto-completed.
  • Three payment gateways — Stripe, PayPal, and Pliso — each with signature-verified webhooks driving order/payment status.
  • Coupons vs. scoped offers as two distinct discount mechanisms: universal codes versus campaigns scoped to specific packages/services with their own discount cap.
  • Company Transfer onboarding — a dedicated flow for customers whose company was formed elsewhere and now want to move its compliance/registered-agent service onto the platform.
  • Refunds, support tickets, and an admin analytics overview (order trends, service distribution, revenue) restricted to Superadmin/Technical Admin roles.

Technical Highlights

  • Five independently deployable frontends (Next.js client site, Next.js admin CMS, Next.js technical dashboard, Expo mobile app, Electron desktop prototype) against one GraphQL schema — each surface only sees the queries/mutations its role can use.
  • Pricing and jurisdiction rules modeled as relational data (packages, services, per-package-per-service status) rather than hardcoded logic, so an admin can add a state fee or rename a package without a deploy.
  • Staff authentication kept structurally separate from customer accounts (its own credentials table), reconciled to the same role-based guard system via a "shadow principal" pattern so the rest of the codebase doesn't need two auth code paths.
  • I run periodic full-codebase reviews as a deliverable in their own right — documented, prioritized findings (e.g., client-trusted renewal pricing, an admin auto-fill path that skipped a refund-amount check) rather than silent fixes, so the team can decide what to prioritize.

Impact

The five-surface split keeps each dashboard fast and focused — Superadmin content editors aren't loading technical-staff order tooling, and the mobile/desktop technical apps only ship what field/back-office staff actually need — while every surface stays consistent because pricing, order state, and permissions all resolve through the same backend.