post https://demo.onefin.in/api/v1/client/line/{lead_id}/tranche/
Once you have received approval from the GET API of the loan, you can create and trigger loan tranche disbursal.
POST /api/v1/client/line/<lead_id>/tranche/
{
"bank_account": {
"ac_number": "<bank account number>",
"ifsc_code": "<IFSC code of customer>",
"nach_umrn": "<NACH UMRN of the given bank account>",
"nach_type": "<physical/api-mandate>",
"ac_name": "<name of the customer in bank account>",
"upi_vpa": "<enter the UPI/VPA ID>"
},
"invoice": {
"invoice_id": "< invoice id >",
"invoice_amount": "< invoice amount >",
"invoice_date": "< date of the invoice >"
},
"partner_tranche_id": "<tranche id at the partner side>",
"disbursal_detail": {
"date": "<Date of tranche>",
"amount": "<Amount to be released>",
"disbursal_type": "<principal>",
"processing_fee": "<processing fee>",
"pre_emi": "<pre emi>",
"gst": "<GST on the processing fee collected>",
"subvention": "<Subvention amount, if any>",
"upfront_emi": "<Upfront EMI, if any>",
"downpayment": "<Downpayment, if any>",
"insurance": "<Insurance, if any>"
},
"repayment_schedule": [{
"due_date": "<Due Date, when EMI is due>",
"due_amount": "<Due Amount, which customer has to pay>",
"principal_amount": "<Principal amount>",
"interest_amount": "<Interest amount>"
}],
"additional_variables": {}
}
The payload should contain the file as the file name and the same file name should be uploaded in the API.
Sample response:
{
"is_success": true,
"data": {
"tranche_id": <id of the tranche>
}
}
Error Scenario - Partner Tranche ID is resent.
There might be a scenario, wherein the Tranche creation API is triggered twice, and since Partner Tranche ID is unique for every drawdown, we will raise the following error.
This will raise a 400 status code.
{
"is_success": false,
"error": {
"message": "Partner Tranche ID already exists.",
"code": "duplicate_partner_tranche_id",
"details": {
"tranche_id": "82a332e6-099f-4b36-acb4-d7c74214aa92"
}
}
}