Add balance settlement feature for small remaining balances #4
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Feature Request
Problem
The proportional distribution algorithm creates a "Zeno's paradox" situation for clients with small remaining balances. When a client has a much smaller balance relative to others, they receive proportionally tiny payouts that asymptotically approach zero but never fully settle.
Example:
This creates a poor user experience where small-balance clients see tiny, drawn-out payments instead of being settled promptly.
Proposed Solution
1. Manual Settlement (Admin-Initiated)
Allow admins to manually initiate a custom payment to settle all or part of a client's remaining balance at the current exchange rate. The operator uses their own funds to make the client "square."
2. Automatic Settlement (Threshold-Based)
Optionally automate settlements when balances fall below configurable thresholds:
Threshold Options:
Configuration:
Implementation Ideas
settlement_paymentstable or flag on existingdca_paymentslamassu_configfor auto-settlement rulesUse Case
Benefits