v1
latestOpenAPI 3.1.02026-07-263644911022.4 KBLoan Accounts
Prepay loan account
Appends an immutable prepayment schedule version and recalculation trigger. BR accounts require quoteId; amount-only prepayment is available only for non-BR accounts. When both are provided, amount must equal the quote's net settlement amount. Idempotency is enforced by the lib-commons idempotency middleware via the X-Idempotency header; a reused key with different facts yields 409. A missing required BR quote, malformed UUID, or invalid amount yields 422.
post/api/v1/loan-accounts/{id}/prepayments
Path parameters
idstring uuid required
Loan account identifier (UUID).
Example:550e8400-e29b-41d4-a716-446655440000
Loan account identifier (UUID).
Headers
X-Idempotencystring required
Canonical idempotency request ID. Enforced by the lib-commons idempotency middleware.
Example:550e8400-e29b-41d4-a716-446655440011
Canonical idempotency request ID. Enforced by the lib-commons idempotency middleware.
Request body
Example request
{
"amount": "100.00",
"businessDate": "2026-06-14",
"effectiveDate": "2026-06-14",
"quoteId": "550e8400-e29b-41d4-a716-446655440020"
}Response
Created
Example response
{
"previousScheduleVersionId": "550e8400-e29b-41d4-a716-446655440031",
"scheduleVersion": {
"createdAt": "2026-06-14T12:00:00Z",
"id": "550e8400-e29b-41d4-a716-446655440030",
"installments": [
{
"dueDate": "2026-06-14T12:00:00Z",
"feesAmount": "3.50",
"interestAmount": "20.00",
"number": 3,
"penaltiesAmount": "1.50",
"principalAmount": "100.00",
"principalRemaining": "100.00",
"totalAmount": "125.00"
}
],
"loanAccountId": "550e8400-e29b-41d4-a716-446655440000",
"predecessorVersionId": "550e8400-e29b-41d4-a716-446655440031",
"versionNumber": 2
}
}