> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lerian.studio/llms.txt
> Use this file to discover all available pages before exploring further.

# Service a loan

> Operate an active loan account — read its schedule and transactions, record and preview repayments, prepay, reschedule, and correct with reversals.

export const GAuditTrail = ({children}) => <Tooltip headline="Audit trail" tip="A chronological, immutable record of every action and transaction in the system — essential for regulatory compliance and dispute resolution." cta="See glossary" href="/en/glossary">
    {children}
  </Tooltip>;

Once a loan is disbursed it becomes a **loan account** — the servicing view of the live contract. Servicing is everything that happens across its life: money comes in, the schedule changes, and mistakes get corrected without ever rewriting history.

## Read the account

***

| Operation                                     | Purpose                                                                        |
| --------------------------------------------- | ------------------------------------------------------------------------------ |
| `GET /api/v1/loan-accounts/{id}`              | Read the active loan account.                                                  |
| `GET /api/v1/loan-accounts/{id}/schedule`     | Read the current installment schedule.                                         |
| `GET /api/v1/loan-accounts/{id}/transactions` | List transactions posted against the account.                                  |
| `GET /api/v1/loan-accounts/{id}/charges`      | List active charges on the account.                                            |
| `GET /api/v1/loan-accounts/{id}/audit-events` | Read the immutable <GAuditTrail>audit trail</GAuditTrail> of lifecycle events. |

The `servicing` collection (`GET /api/v1/servicings`, `GET /api/v1/servicings/{id}`) is the list-and-lookup surface over these accounts, including an external-status read (`GET /api/v1/servicings/{id}/status`).

## Record money

***

<Steps>
  <Step title="Preview the allocation">
    `POST /api/v1/loan-accounts/{id}/preview-repayment` shows how a repayment would be allocated across outstanding installments — principal, interest, and charges — **without recording it**.
  </Step>

  <Step title="Record the repayment">
    `POST /api/v1/loan-accounts/{id}/repayments` records money received and allocates it across the schedule. Writes are idempotent.
  </Step>

  <Step title="Prepay">
    `POST /api/v1/loan-accounts/{id}/prepayments` settles the loan ahead of schedule, in whole or in part. In Brazil, take a binding [prepayment quote](/en/lender/brazil-regulatory-pack) first.
  </Step>
</Steps>

## Change the schedule

***

`POST /api/v1/loan-accounts/{id}/reschedules` rewrites the remaining schedule — for a renegotiation, for example. The change is a new schedule state, not an edit of the old one.

## Correct without destroying

***

Corrections preserve a consistent, auditable timeline. To undo a posted transaction, reverse it:

`POST /api/v1/loan-accounts/{id}/transactions/{transactionId}/reverse`

A reversal posts a compensating entry to the ledger rather than deleting anything, so the account and its books stay in step and the audit trail stays complete.

<Warning>
  Servicing never edits the past. Repayments, reschedules, and reversals all append new facts; state is re-derived from that history (replay), which is what keeps the ledger and the loan account reconcilable.
</Warning>

## What happens downstream

***

Servicing emits `repayment.recorded`, `repayment_reversal.recorded`, `loan_schedule.prepayment_applied`, and `loan_schedule.rescheduled`, and each money movement books to the ledger through the [posting path](/en/lender/lender-in-the-platform).

## Next steps

***

<Card title="Accounting and accrual runs" icon="calculator" href="/en/lender/accounting-and-accrual-runs" horizontal>
  Recognize interest over time and trace every posting back to the ledger.
</Card>

<Card title="Portfolio and delinquency" icon="chart-line" href="/en/lender/portfolio-and-delinquency" horizontal>
  See the servicing book in aggregate, including overdue loans.
</Card>
