FTOS_BP_CalculatePMT
Returns the value for the calculated PMT, or payment terms for a loan or investment.
Syntax
The FTOS_BP_CalculatePMT custom endpoint is called from within the Endpoint API endpoint. Visit the Endpoint API page for more details.
Copy
POST <host_address>/ftosapi/automation-processors/actions/ftos_bp_calculatepmt
Content-Type: application/json
{
"jsonParam": {
"FinancedAmount": <loan_financed_amount>,
"InterestPercent": <annual_interest_percentage>,
"InstallmentsNo": <number_of_installments>,
"GracePeriodPrincipal": <1_to_skipinstallment_at_the_beginning_0_if_missing>,
"PeriodicityType": "periodicity_type",
"FutureValue": <ballon_value_or_0_if_missing>,
"InterestCalculationMethod": "30/360",
"InterestType": <calculation_type_0_for_InArrears_1_for_InAdvance>
}
}
Here's a list of the available parameters:
| Parameter | Description |
|---|---|
| host_address | URL of the FintechOS Platform server. |
| InstallmentsNo | Mandatory, whole number. The number of installments. |
| PeriodicityType | Mandatory, string. The type of periodicity for PMT calculation. The possible values are the names of the records from the FTOS_CB_PeriodicityType entity. |
| InterestCalculationMethod | Mandatory, string. The method to be used for interest calculation. The possible values are the names of the records from the FTOS_BP_InterestCalculationType option set. |
| FinancedAmount | Optional, numeric. The loan's financed amount. |
| InterestPercent | Optional, numeric. The annual interest percentage. |
| GracePeriodPrincipal | Optional, possible values 0 or 1. If the value is 1, then the installment is skipped at the beginning. If the parameter is not present, its value is considered 0. |
| FutureValue | Optional, numeric. The balloon value. If the parameter is not present, its value is considered 0. |
| InterestType | The type of calculation for the interest, with 0 for InArrears and 1 for InAdvance. |
Response
The response is an array of objects with the calculated PMT and the principal value.
Example
To view the calculated PMT and the principal value for a loan, send the following request, changing the parameters to suit your need.
Request
Copy
POST https://your_FintechOS_server/ftosapi/automation-processors/actions/ftos_bp_calculatepmt
Content-Type: application/json
{
"jsonParam": {
"FinancedAmount": 10000,
"InterestPercent": 5,
"InstallmentsNo": 12,
"GracePeriodPrincipal": 1,
"PeriodicityType": "Monthly",
"FutureValue": 1002.3,
"InterestCalculationMethod": "30/360",
"InterestType": 0
}
}
Response
Copy
{
"PMTValue": 842.74,
"PrincipalValue": 1000.0
}