Billing Business Rules¶
Why This Exists¶
This document defines business rules for the Billing Domain.
Owner¶
The owner is the Chief Product Officer and Enterprise Architect.
Business Value¶
Business rules protect commercial integrity, subscription access, invoice accuracy, and entitlement enforcement.
Rules¶
| Rule ID | Rule | Rationale |
|---|---|---|
| BILL-RULE-001 | Billing owns subscription, billing account, invoice, payment, entitlement, usage limit, renewal, cancellation, and payment failure state. | Maintains domain ownership. |
| BILL-RULE-002 | Organization owns customer organization identity. Billing must reference OrganizationId. | Preserves Organization ownership. |
| BILL-RULE-003 | Notification delivers billing notifications, but Billing owns billing facts and notification requests. | Separates facts from delivery. |
| BILL-RULE-004 | Analytics may report revenue and subscription metrics but must not own billing facts. | Preserves source ownership. |
| BILL-RULE-005 | Intelligence may explain plan differences and recommend upgrades, but Billing owns accepted subscription state. | Separates reasoning from commercial state. |
| BILL-RULE-006 | A billing account must exist before paid subscription, invoice, or payment workflow. | Establishes commercial context. |
| BILL-RULE-007 | Active plans must define entitlements and limits. | Enables access control. |
| BILL-RULE-008 | Subscription status must be changed only through Billing commands, policies, or accepted provider events. | Protects status integrity. |
| BILL-RULE-009 | Issued invoices must retain immutable line-item history. | Protects audit and customer trust. |
| BILL-RULE-010 | Payment provider callbacks must be validated and deduplicated before changing payment state. | Prevents incorrect payment records. |
| BILL-RULE-011 | Payment failure must create a recovery path or final state. | Supports dunning and access decisions. |
| BILL-RULE-012 | Entitlements must be derived from subscription state, plan limits, and approved overrides. | Keeps access aligned to commercial terms. |
| BILL-RULE-013 | Usage limits must define unit, period, threshold, and enforcement behavior. | Prevents ambiguous enforcement. |
| BILL-RULE-014 | Cancellations must preserve historical billing records. | Protects audit. |
| BILL-RULE-015 | Enterprise subscriptions may have custom terms, but accepted terms must be versioned and auditable. | Supports negotiated customers safely. |
Rule Enforcement¶
Billing rules are enforced through subscription commands, invoice generation, payment callback processing, entitlement evaluation, usage limit checks, renewal workflows, and cancellation workflows.