FTOS_CB_AddUpdateReturnedAmountOrGoods

Adds or updates a contract event record representing an event for a returned amount or goods for a contract. The entire repayment schedule is recalculated considering this event. The set of parameters sent via the request body determines the operation performed at the database level.

Syntax

The FTOS_CB_AddUpdateReturnedAmountOrGoods 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_CB_AddUpdateReturnedAmountOrGoods
Content-Type: application/json
            
{
    "contractName":"<contract_number>",
    "eventName":"<event_number>",
    "baseAmount":<amount_to_return>,
    "returnDate":"<yyyy-mm-dd>",
    "decreaseInstallment":<true_or_false>,
    "feeValueToPrincipal":<true_or_false>,
    "externalIdentifier":"<external_identifier_for_event>"
}

Here's a list of the available parameters:

Parameter Description
host_address URL of the FintechOS Platform server.
contractName Mandatory. The number of the contract.
eventName Mandatory only for update operations. Do not send it for add operations. The number of the returned amount or goods event.
returnDate The date of the return. By default = Activation Date. It is validated against Activation Date and Current Date (it cannot be before Activation Date and after Current Date).
baseAmount Mandatory. The plain returned amount that needs to be inserted in the contract.
decreaseInstallment Possible values: true or false. Passing true keeps the contract period length, passing false decreases the contract period length.
feeValueToPrincipal Possible values: true or false. Passing true applies the value of the return fee to the principal, diminishing the outstanding capital.
externalIdentifier Optional, string. The external identifier of the transaction.

Response

The response indicates the result of the code execution, specifically the result of creating or updating a contract event record. The entire repayment schedule is recalculated considering this event.

Example

Error Responses