Skip to content

Reconciliation

Reconciliation verifies that wallet balances match ledger entries, ensuring data integrity and detecting discrepancies.

What is Reconciliation?

Compares two sources of truth:

SourceDescription
Wallet BalanceDenormalized field on User/Vendor model
Ledger BalanceSum of posted ledger entries (source of truth)

Goal: Wallet Balance = Ledger Balance


Why Reconcile?

PurposeBenefit
Data IntegrityDetect database corruption or tampering
Audit ComplianceMeet regulatory verification requirements
Bug DetectionCatch programming errors
Fraud DetectionIdentify unauthorized balance modifications

Reconciliation Types

TypeDescription
User BalanceVerify single user wallet vs ledger
Vendor BalanceVerify single vendor wallet vs ledger
All UsersReconcile all user balances
All VendorsReconcile all vendor balances
Trial BalanceVerify total debits = total credits

Daily Automated Reconciliation

Runs automatically at 2 AM daily.

Tasks Performed:

  1. Auto-post pending entries > 30 minutes old
  2. Verify all user balances
  3. Verify all vendor balances
  4. Generate and verify trial balance
  5. Create reconciliation record
  6. Alert on critical discrepancies

Discrepancy Severity Levels

SeverityDifferenceAction
LOWE0.01 - E1.00Log only, auto-correct
MEDIUME1.01 - E10.00Alert admin, review
HIGHE10.01 - E100.00Alert admin, freeze account
CRITICAL> E100.00Alert, freeze, escalate

Handling Discrepancies

Auto-Correct (< E1.00)

For small rounding errors:

  1. Find discrepancies < E1.00
  2. Create manual adjustment journal entry
  3. Update wallet balance to match ledger
  4. Log correction in audit trail

Manual Correction (E1.00 - E100.00)

For larger discrepancies:

  1. Calculate difference
  2. Investigate cause
  3. Create manual adjustment with approval
  4. Update wallet balance
  5. Notify admin of correction

Investigation Required (> E100.00)

For critical discrepancies:

  1. Freeze account - Prevent further transactions
  2. Review audit log - Find cause
  3. Check ledger entries - Verify all entries posted
  4. Check wallet transactions - Find orphaned transactions
  5. Manual correction - After investigation complete

Trial Balance

Lists all accounts with their debit/credit totals.

Account CodeAccount NameDebitCredit
1110User WalletsE50,000-
1120Vendor WalletsE25,000-
4110Fee Revenue-E2,500
............
TOTALE75,000E75,000

If debits ≠ credits, there's a fundamental accounting error.


Reconciliation Records

Each run is recorded:

FieldDescription
reconciliationIdUnique identifier (REC-XXXXXX)
startedAtStart timestamp
completedAtEnd timestamp
statusIN_PROGRESS, COMPLETED, FAILED
scopeUSER, VENDOR, TRIAL_BALANCE, FULL
resultsCounts, discrepancies, trial balance

Account Statements

Generate detailed transaction history for users/vendors:

Fields Included:

  • Opening balance
  • Closing balance
  • Transaction entries with descriptions
  • Running balance
  • Counterparty names

Export Formats: CSV, HTML


Monitoring and Alerts

SeverityAlert Method
LOWLog only
MEDIUMEmail to admin
HIGHEmail + Slack
CRITICALEmail + Slack + Phone

Best Practices

  1. Run daily reconciliation at 2 AM (low traffic time)
  2. Auto-correct small discrepancies (< E1.00) to reduce noise
  3. Alert on medium/high discrepancies immediately
  4. Freeze accounts with critical discrepancies
  5. Investigate thoroughly before manual corrections
  6. Document corrections in audit trail with reasons

Internal use only - Keshless Payment Platform