UpdateSelfServiceLoanProductCommand
Overview​
Updates an existing loan product's parameters. All fields except loanProductId are optional — only provided fields are updated. Currency code cannot be changed after creation.
Command Structure​
{
"cmd": "UpdateSelfServiceLoanProductCommand",
"data": "{\"loanProductId\":5,\"interestRate\":4.0,\"interestRateCalculation\":2,\"maximumTenorInDays\":730}"
}
Parameters​
| Parameter | Type | Required | Description |
|---|---|---|---|
loanProductId | long | Yes | ID of the loan product to update |
interestRateCalculation | int | Yes | Interest rate period type (0=Daily, 1=Weekly, 2=Monthly, 3=Yearly) |
name | string | No | New display name |
code | string | No | New product code |
currencyCode | string | No | Currency — blocked from change (returns error) |
interestRate | decimal | No | New interest rate percentage |
disbursementFeeCalculation | int | No | Fee calculation method (0=Flat, 1=% Loan, 2=% Disbursed) |
loanFee | decimal | No | New fee amount or percentage |
minimumAmount | decimal | No | New minimum loan amount |
maximumAmount | decimal | No | New maximum loan amount |
maximumTenorInDays | int | No | New maximum tenor in days |
Validations​
- Product must exist — error returned if
loanProductIdnot found nameandcodemust remain unique — error if new value already belongs to another productcurrencyCodechange is blocked — returns an error if a new currency is provided
Response​
{
"ok": true,
"statusCode": "00",
"message": "Loan product updated successfully.",
"outData": {
"LoanProductId": 5,
"LoanProductName": "Personal Loan",
"LoanProductCode": "PERSONAL"
}
}