The Loans API manages personal loans using the French amortization model (constant monthly payment). Each loan tracks a liveDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/soker90/finper/llms.txt
Use this file to discover all available pages before exploring further.
pendingAmount that decreases with every payment. Ordinary payments follow a monthly schedule; extraordinary payments (early capital repayments) can either shorten the term (reduceTerm) or lower the monthly quota (reduceQuota). Rate-change events model variable-rate renegotiations such as Euribor reviews. Every payment automatically updates the linked account balance and generates an expense transaction.
GET /api/loans
List all loans belonging to the authenticated user. The response is a flat array — no amortization table is included at this level.POST /api/loans
Create a new loan.pendingAmount is set automatically to initialAmount; initialEstimatedCost is calculated from the full projected amortization table at creation time — you do not supply either field.
Body parameters
Descriptive label for the loan (e.g.
"Mortgage", "Car Loan").Original principal. Must be a positive number. This value never changes after creation.
Annual nominal interest rate (TIN) expressed as a percentage — e.g.
3.5 means 3.5%. Must be ≥ 0 (0 = interest-free loan).Loan start date as a Unix timestamp in milliseconds. The first projected payment falls exactly on this date.
Initial monthly quota. Must be positive. Used to project the full amortization table and calculate
initialEstimatedCost.ID of the account from which payments will be deducted.
ID of the expense category used when auto-creating payment transactions.
pendingAmount is derived from initialAmount automatically. initialEstimatedCost is computed by projecting the complete amortization schedule at creation time. Both are forbidden in the request body — the API returns HTTP 422 if either is provided.GET /api/loans/:id
Retrieve full loan detail including the historical payment list, the projected future payment schedule, and a statistics summary.Loan ID.
Stats fields
Sum of
principal across all real (historical) payments.Sum of
interest across all real payments.Current
loan.pendingAmount — the live capital still owed.Sum of
interest across all projected future payments.Sum of
amount (principal + interest) across all real payments.totalCostToDate plus the sum of all projected future payment amounts.initialEstimatedCost − estimatedTotalCost. A positive value shows how much interest has been saved through extraordinary early repayments.Unix timestamp (ms) of the last projected payment.
null if the loan is fully paid.Monthly quota currently in effect (from the most recent event, or
loan.monthlyPayment).Annual interest rate currently in effect (from the most recent event, or
loan.interestRate).PUT /api/loans/:id
Edit basic loan metadata. All fields are optional; only the provided fields are updated. This endpoint does not recalculate the projected amortization table — use payment and event endpoints to affect the financial schedule.Loan ID.
New descriptive label.
Replace the linked account ID.
Replace the linked category ID.
DELETE /api/loans/:id
Delete a loan and cascade-delete all of its payments and events.Loan ID.
This operation does not restore account balances or remove the transactions that were generated by past payments. If you need a full revert, delete individual payments first via
DELETE /api/loans/:id/payments/:paymentId.POST /api/loans/:id/pay
Record an ordinary (scheduled monthly) payment. The interest and principal split is calculated automatically from the currentpendingAmount and interestRate. The account balance is decremented and an expense transaction is created unless addMovement is set to false.
Loan ID.
Payment date as a Unix timestamp (ms). Defaults to now.
Override the calculated quota. Must be positive. Useful for final partial payments.
Whether to deduct from the account and create an expense transaction. Defaults to
true.POST /api/loans/:id/amortize
Record an extraordinary payment (early capital repayment). The fullamount goes to principal (interest = 0). Choose a mode to determine whether the remaining term shortens or the monthly quota decreases.
Loan ID.
Capital amount to repay early. Must be positive.
How the loan is restructured after early repayment. One of
reduceTerm or reduceQuota.reduceTerm: keeps the same monthly payment, shortens the remaining term.reduceQuota: keeps the same remaining term, recalculates a lower monthly payment.
Payment date as a Unix timestamp (ms). Defaults to now.
Whether to deduct from the account and create an expense transaction. Defaults to
true.| Mode | Monthly payment | Months remaining |
|---|---|---|
reduceTerm | Unchanged | Decreases |
reduceQuota | Decreases | Unchanged |
POST /api/loans/:id/events
Record a rate-change event — a point in time from which a new interest rate and monthly payment apply. This models variable-rate renegotiations (e.g. annual Euribor + spread reviews).Loan ID.
Effective date of the new conditions, as a Unix timestamp (ms).
New annual nominal interest rate (TIN%) from this date onwards. Must be ≥ 0.
New monthly payment amount from this date onwards. Must be positive.
Adding an event immediately updates
loan.interestRate and loan.monthlyPayment to the new values. Events are immutable history; they cannot be edited, only added.POST /api/loans/:id/simulate-payoff
Simulate the financial impact of making a one-time lump-sum capital payment without modifying any real data. Returns two comparison scenarios so you can decide whether to reduce the term or reduce the quota before committing.Loan ID.
Hypothetical lump-sum amount to apply. Must be a positive integer.
The hypothetical payment amount used in the simulation.
Projected months remaining before the simulation.
Projected end date before the simulation (Unix ms).
Scenario where the lump sum is applied with
reduceTerm — same quota, shorter loan life.Scenario where the lump sum is applied with
reduceQuota — same term, lower monthly payment.PUT /api/loans/:id/payments/:paymentId
Edit an existing payment. Triggers a full forward-pass recalculation ofaccumulatedPrincipal and pendingCapital for every subsequent payment using a bulkWrite. Also updates loan.pendingAmount and, for ordinary payments, synchronises the linked expense transaction.
Loan ID.
Payment ID.
New payment date (Unix ms).
New total payment amount.
New interest portion (min 0).
New principal portion (min 0).
Payment type:
ordinary or extraordinary.At least one of
date, amount, interest, principal, or type must be provided. The request returns HTTP 422 if only internal fields (user, paymentId) are supplied without any editable field.DELETE /api/loans/:id/payments/:paymentId
Delete a payment. Reverts the account balance (adds back the paymentamount) and removes the linked expense transaction (for ordinary payments). Restores loan.pendingAmount by the principal portion of the deleted payment.
Loan ID.
Payment ID.
Account integration
Every ordinary and extraordinary payment with
addMovement: true (the default) performs two side-effects atomically:- Decrements
account.balanceby the paymentamount. - Creates an expense
Transactionlinked toloan.category.
amount or date updates the linked transaction accordingly.