Restructure a loan

Restructures an existing loan: the original loan's authorization is reversed and a new loan is authorized for the
original loan's outstanding principal (the total_payable.principal returned by GET /v2/loans/{loanId}, net of
partial principal payments and adjustments). Interest of the new loan is priced by the selected installment plan.

This endpoint generates a Loan updated event and changes the original loan to a RENEGOTIATED status.

A Rates simulation must exist for exactly that outstanding principal, the installment plan and the number of
installments. Simulate the outstanding principal first and send the resulting simulation_id; without it, Rates
uses the most recent simulation of the same account, plan and amount. The simulation is validated before anything is
reversed: when it does not match, the request fails with ELND2008 and the loan is not changed.

Processing is asynchronous. If the new loan's authorization is denied after the original loan was reversed, the
original loan stays RENEGOTIATED without a restructure_loan_id, a lending_error event with error code
ERST0001 is published, and the restructure can be retried by calling this endpoint again with a new
Idempotency-Key.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
uuid
required

The ID of the original loan to restructure

Body Params
string
required

Installment plan ID

string
required

Loan product ID

integer
required

Number of installments

uuid

Optional. ID of the Rates simulation of the loan's outstanding principal for the selected installment plan and number of installments. Recommended, so the new loan is priced with the simulation shown to the operator.

Headers
uuid
required

Required UUID that makes the request idempotent, enabling you to retry it multiple times while the system processes it only once.

Responses

500

Internal Server Error

Language
Credentials
Bearer
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json