Simulations

Simulate installment advancement

Simulate an installment advancement for an account. That is, it simulates advancing one or more installments from a future cycle to the current cycle.

To simulate advancing installments for a specific installment agreement (contract), set the condition query parameter to SINGLE_CONTRACT, and set the transaction_id query parameter to the transaction ID of any of the installments in the installment agreement. Specify the number of installments to advance in the simulation in the number_of_installments_to_advance query parameter. Installments are advanced starting with the last scheduled installment in the agreement and working backwards from there.

To simulate advancing <b>all</b> future installments for <b>all</b> installment agreements in the account, set the condition field to ALL_CONTRACTS. (In this case, the number_of_installments_to_advance field is ignored.)

When you simulate advancing installments, you must specify what to do with the interest. You have three options:

  • To simulate removing 100% of the interest on the advanced installment(s), set the remove_interest_from_current query parameter to true and the calculator query parameter to NONE.
  • To simulate advancing 100% of the interest on the advanced installment(s), set remove_interest_from_current to false and set calculator to NONE.
  • To simulate recalculating the interest applied to the advanced installments(s), set calculator to PRESENT_VALUE. The remove_interest_from_current parameter can be set to either true or false. If true, the interest on installments that were already in the current cycle (and did not need to be advanced) is recalculated in the simulation. Otherwise, interest on those installments is unchanged.

For more information, see <a href='https://developers.pismo.io/pismo-docs/docs/installment-management#installment-advancements'>Installment advancements</a>.

This endpoint generates an <a href='https://developers.pismo.io/events/docs/balance-installment-advancement-1'>Installment advanced</a> event.

get/v1/accounts/{accountId}/installment-advance/simulations

Request

  • Base URL
    https://sandbox.pismolabs.io/installment-management
  • URL
    https://sandbox.pismolabs.io/installment-management/v1/accounts/{accountId}/installment-advance/simulations
  • Auth
    HTTP bearer

Path parameters

accountIdinteger required
Example:6912345

Account ID

Query parameters

transactionIdinteger
Example:98457355

Transaction ID

condition'ALL_CONTRACTS' | 'SINGLE_CONTRACT' required
Example:ALL_CONTRACTS

Indicates if all installments should be advanced (ALL_CONTRACTS) or just a single installment (SINGLE_CONTRACT).

removeInterestFromCurrentboolean

Indicates whether interest should be removed when an installment is advanced to the current statement. Default is false.

calculator'PRESENT_VALUE' | 'NONE'

Specifies the type of calculation to be applied for interest reduction when an installment is advanced to the current cycle. To recalculate the interest on advancements, set calculator to PRESENT_VALUE. Default is NONE.

reschedule'ADVANCEMENT' required

Indicates the type of rescheduling to apply. Must be set to ADVANCEMENT.

numberOfInstallmentsToAdvanceinteger
Example:2

Define the number of installments to be brought to the current statement.

interestRemovalEndDatestring date
Example:2025-06-30

Optional cutoff date for interest removal when calculator is set to PRESENT_VALUE. Installments with a due date on or before this date will have interest recalculated using this date as the reference instead of the original due date. If omitted, the installment's original due date is used.

Response

OK

account_idinteger

Account ID

authorization_idinteger

Authorization ID for the first installment

condition'SINGLE_CONTRACT' | 'ALL_CONTRACTS'

Installments should be advanced for all the contracts for an account (ALL_CONTRACTS) or for a specific contract (SINGLE_CONTRACT). If condition is set to SINGLE_CONTRACT, then the transaction_id field must be set to the transaction ID of the specific contract.

calculator'PRESENT_VALUE' | 'REMOVE_ALL_INTEREST' | 'NONE'

Type of calculation to apply. Default is NONE.

reschedule'ADVANCEMENT'

Reschedule mode to apply. Must be ADVANCEMENT.

interest_removal_end_datestring date

Cutoff date used for interest recalculation when calculator is PRESENT_VALUE. Reflects the value passed in the request. null if not passed. Format = yyyy-mm-dd.

Example response

{
  "account_id": 67854328,
  "authorization_id": 200,
  "condition": "SINGLE_CONTRACT",
  "calculator": "PRESENT_VALUE",
  "reschedule": "ADVANCEMENT",
  "interest_removal_end_date": "2021-04-14",
  "installments": [
    {
      "id": 98457355,
      "new_amount": 99.9,
      "old_amount": 102.9,
      "new_interest_amount": 9.9,
      "old_interest_amount": 11.9,
      "new_statement_id": 1,
      "old_statement_id": 10
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.