Strategic Context
El Dorado is a dead end — no open API, fully manual, vendor unresponsive. Japheth's platform has critical gaps. Any licensing deal creates long-term dependency. The decision is to build proprietary software: Client owns the IP, controls the roadmap, increases company valuation at exit.
Engagement Structure
A retainer-based engagement with a fixed total investment and a flexible delivery cadence.
The engagement is structured as a monthly retainer across a duration to be finalized by the Client. The total investment is fixed regardless of the payment cadence selected. Common Goodworks commits to 10–12 dedicated hours per week toward the project, with any work performed above that range absorbed at no additional cost to the Client.
User Roles & Access Model
Four roles. Each has a distinct access scope, login experience, and capability set. The UPB Admin is the only role that can create domains, assign specialists, and onboard clients.
UPB Admin
Billing Specialist
Client
Resident
Phased Development Roadmap
Two development phases following Discovery. Phase 0 delivers one complete billing cycle on one property; Phase 1 delivers full feature parity plus the Full Resident Portal.
- Domain model design confirmed
- Client approval flow defined
- Auth0 integration confirmed
- Cloud deployment architecture selected
- GitHub repo + Claude Code integration
- 7 Phase 0 DB schemas reviewed & approved
- Audit_Log structure finalized
- Rent Manager API credentials obtained
- Japheth partnership position documented
- Application code of any kind
- UI / UX design work
- Billing formula implementation
- Data migration planning
- Next.js scaffold — App Router, TypeScript, PostgreSQL, Auth0
- All 4 user roles with correct routing and data scoping
- UPB Admin: domain creation and specialist assignment
- Billing Specialist: domain-scoped property access
- Client: siloed login, pre-billing approval workflow
- Resident: magic-link invoice portal with PDF download
- Property + unit setup (manual)
- RUBS Formulas 1 & 2 via decimal.js
- PDF bill upload — pdfplumber extracts meter/account numbers; specialist labels each billable or non-billable
- CSV meter read upload
- Anomaly detection + specialist approval gate
- Pre-billing report with inline editing + live recalculation
- Client approval step before charges finalize
- Async PDF → email via SES (no S3)
- Audit_Log written on every action from day one
- 7 new DB tables + AWS baseline
- RUBS Formulas 3–8
- Submeter billing
- Full Resident Portal (Phase 1)
- PMS integration
- AMR auto-sync
- Bill caps, tiered rates
- AI-based bill extraction (Bedrock/Claude) — architecture-ready, activated when provider coverage gaps appear
- Reporting suite
- RUBS Formulas 3–8 (ratio occupancy, sq footage, per bed/bath, blended)
- Submeter billing — Methods A, B, C, D
- Direct Metered and Flat Fee billing types
- CAD, bill caps, vacancy toggles, proration rules
- Percentage-based fees (CARE discounts, surcharges)
- Tiered rate configuration
- Recurring charge auto-generation
- Multi-property specialist dashboard (domain-scoped)
- Void and re-bill workflow with full Audit_Log trail
- CSV charge export for manual PMS posting
- Full Resident Portal (see Section 5)
- AMR integration (Phase 2 — future SOW)
- PMS API sync (Phase 3 — future SOW)
- AI-based bill extraction (Bedrock/Claude) — drop-in upgrade when pdfplumber coverage gaps are identified
- AP Journal Entries module
- Reporting suite (Phase 5 — future SOW)
- Mobile native applications
Full Resident Portal — New in v4
The Full Resident Portal is the most significant scope addition from v3 to v4. This section defines what the portal is, so there is no ambiguity at Phase 1 acceptance.
The Full Resident Portal is a resident-facing web experience that provides comprehensive self-service access to billing information. It is accessed via secure magic-link authentication — no resident account creation is required. The portal is mobile-responsive and works on any modern browser.
| Capability | Description |
|---|---|
| Full bill history | Every billing cycle the resident has been billed on is viewable, with clear cycle dates, amounts, and status. |
| Itemized charge breakdown | For each cycle, the resident sees exactly how their charges were calculated — the RUBS formula used, their share, applicable fees, any CAD deduction, proration adjustments. |
| PDF invoice download | Any past invoice can be downloaded as a PDF on demand. PDFs are generated fresh, not stored, consistent with the Phase 0 architecture. |
| Customizable PDF templates | Per-client PDF template configuration: logo placement, billing message text, and line-item label language. |
| Email distribution configuration | Property-level configuration of invoice email distribution — which addresses receive copies, which receive summaries. |
| Mobile-responsive | The portal works fluidly on phones, tablets, and desktops without requiring a native app. |
| Magic-link authentication | Residents authenticate via emailed magic links with configurable TTL. No password management, no account creation friction. |
Technical Stack
Locked April 15, 2026. All decisions confirmed before any code is written.
| Layer | Technology | Rationale |
|---|---|---|
| Full stack | Next.js (App Router) | Single framework for UI, API routes, server-side logic. One codebase, one deployment. Preserves Claude Code session consistency. |
| Billing math | decimal.js | Precise financial arithmetic. All RUBS and submeter calculations run through decimal.js exclusively — never native JS number. |
| PDF extraction | pdfplumber (deterministic) | Extracts meter/account numbers from digital utility bill PDFs using label pattern matching. Covers known pilot providers in Phases 0–1. AWS Bedrock (Claude) is the designed-in upgrade path when new provider formats exceed pattern coverage — same extraction interface, no architectural change required. |
| PDF + email | Async → SES | PDFs generated on demand and attached to emails via AWS SES. No S3 bucket — files are transient. |
| Database | PostgreSQL (RDS) | Managed via AWS RDS. All billing tables + Audit_Log in the same instance. |
| Audit trail | Audit_Log table | Every action, edit, approval, void written to a PostgreSQL table. From day one — never retrofitted. |
| Auth | Auth0 + magic link | Handles UPB Admin, Specialist, and Client roles. Residents use magic-link tokens — no Auth0 seat required. |
| Cloud | AWS | EC2/ECS for compute, RDS, SES for email, CloudWatch for monitoring. |
| Repository | GitHub | Claude Code integrates natively. |
| Domain | app.utilityprobilling.com | App portal. www remains the marketing site. |
Data Model Status
13-table core schema complete. Seven tables added during Discovery. Audit_Log always-on from day one.
| Category | Tables | Status |
|---|---|---|
| Core schema | Clients, Properties, Property_Groups, Units, Leases, Residents, Meters, Meter_Reads, Utility_Bills, Charges, Fees, Client_Invoicing | Done · Apr 2026 |
| Phase 0 additions | Users, Domains, Billing_Cycles, Anomaly_Approvals, Billing_Cycle_Snapshots, Documents, Property_Config | Designed in Discovery |
| Always-on | Audit_Log | Day one · never retrofitted |
Risk Register
Key risks monitored across the engagement. Updated from v3 to reflect v4 scope and engagement structure.