Set Loan Back to Partial Application
Overview
Reverts a loan application to partial application status to allow additional information collection.
Endpoint
POST /api/bpm/cmd
Request Headers
| Header | Type | Required | Description |
|---|---|---|---|
| Authorization | string | Yes | Bearer token for authentication |
| Content-Type | string | Yes | Must be application/json |
| X-Tenant-Id | string | Yes | Tenant identifier |
Request Body
{
"cmd": "SetLoanBackToPartialApplicationCommand",
"data": {
"accountEncodedKey": "LN-2024-001234",
"comment": "Additional documentation required - Income proof and bank statements needed"
}
}
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| cmd | string | Yes | Must be "SetLoanBackToPartialApplicationCommand" |
| data | object | Yes | Revert data |
| ↳ accountEncodedKey | string | Yes | Loan account identifier (EncodedKey or AccountNumber) |
| ↳ comment | string | No | Reason for reverting to partial application |
Response
Success Response (200 OK)
{
"success": true,
"message": "Loan set back to partial application successfully",
"data": {
"loanId": "LA-2024-00001",
"status": "PartialApplication",
"revertedAt": "2024-01-13T11:00:00Z",
"revertedBy": "officer@bank.com",
"reason": "Additional documentation required",
"missingInformation": [
"Proof of income",
"Guarantor acceptance letter"
]
}
}
Status Codes
| Code | Description |
|---|---|
| 200 | Loan reverted successfully |
| 400 | Invalid request or loan not eligible |
| 401 | Unauthorized |
| 404 | Loan not found |
| 409 | Loan in wrong status for revert |
| 500 | Internal server error |
Business Rules
- Can only revert before approval
- Used when incomplete information discovered
- Allows loan officer to collect missing data
- Customer notified of requirements
- Loan can be resubmitted when complete
Code Examples
C# Example
public async Task<RevertResponse> SetLoanBackToPartialAsync(string loanId, string reason, List<string> missingInfo = null)
{
var request = new { loanId, reason, missingInformation = missingInfo };
var json = JsonSerializer.Serialize(request);
var content = new StringContent(json, Encoding.UTF8, "application/json");
var response = await _httpClient.PostAsync("/api/administration/loan/set-back-to-partial", content);
response.EnsureSuccessStatusCode();
var result = await response.Content.ReadAsStringAsync();
return JsonSerializer.Deserialize<ApiResponse<RevertResponse>>(result).Data;
}
TypeScript Example
async function setLoanBackToPartial(loanId: string, reason: string, missingInfo?: string[]): Promise<RevertResponse> {
const response = await fetch('/api/administration/loan/set-back-to-partial', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization': `Bearer ${accessToken}`,
'X-Tenant-Id': tenantId
},
body: JSON.stringify({ loanId, reason, missingInformation: missingInfo })
});
const result = await response.json();
return result.data;
}
Notes
- Helps manage incomplete applications
- Customer receives list of missing items
- Tracked in loan application timeline
- No penalty to customer for revert
- Common during initial application review