Scheduled payment process
Every active loan has a scheduled payment processing sub-process embedded in the Loan management flow. It is what makes the loan “self-collecting” — the system attempts to take the payment on the due date without manual intervention.
When it runs
A timer fires every day at 03:00 AM and asks: “Is today a payment day for this loan?”
- Fixed-term loan. A day is a payment day if it equals the next scheduled payment date in the amortization schedule.
- Credit line. A day is a payment day if it equals the payment date of the most recently closed billing cycle.
If today is not a payment day, the sub-process ends silently. Otherwise, it proceeds with payment processing.
Outside of the scheduled job, both loan types accept ad-hoc payments — initiated by the borrower from their portal (Initiate Payment) or by a credit officer (Register Payment, see the Register payment operation page).
What happens on the payment day
- The loan record is refreshed from the database.
- The system checks that the loan is still active.
- Process Payment is invoked: a transaction is created and routed to the configured repayment provider (Squarepay, VoPay variants, Plaid, Acquired, etc., or “no repayment” if no automatic provider is configured).
- If the provider confirms the payment, a Repayment loan event is created with the transaction reference and amount.
- The borrower receives a “payment received” notification.
- The new snapshot reflects the reduced balances.
Failure handling
If the provider rejects the payment (insufficient funds, account closed, etc.), the transaction is marked as Failed. The scheduled payment sub-process ends; the loan moves to Overdue when the calendar advances past the payment day and the obligation remains unmet, triggering the collection workflow.