Skip to main content

Legacy debt simulation

At QI Tech, we provide our clients with the ability to simulate the values of a credit operation before its actual issuance. The simulation follows the same pattern as the debt issuance request, but it is not necessary to provide the borrower's registration data and disbursement account.

Request

In the example below, a debt simulation request is described.

ENDPOINT
/debt_simulation
METHOD
POST
Request Body
{
"borrower": {
"person_type": "natural"
},
"financial": {
"desired_installments": [
{
"total_amount": 578.69,
"due_date": "2027-04-01"
},
{
"total_amount": 304.25,
"due_date": "2028-04-01"
}
],
"interest_type": "pre_price_days",
"disbursement_date": "2026-09-06",
"fine_configuration": {
"monthly_rate": 0.0,
"interest_base": "calendar_days",
"contract_fine_rate": 0.0
},
"annual_interest_rate": 0.2387205,
"credit_operation_type": "ccb",
"interest_grace_period": 0,
"number_of_installments": 2,
"principal_grace_period": 0,
"rebates": [
{
"amount": 10,
"fee_type": "tac",
"amount_type": "absolute",
"rebate_bank_account": {
"name": "CONTA BANCARIA",
"bank_code": "329",
"account_digit": "1",
"branch_number": "0001",
"account_number": "00003",
"document_number": "32402502000135"
}
}
]
}
}

Response

STATUS
200
Response Body
{
"type": "debt",
"key": "bf84379c-d4cf-4f16-a63c-865c129e6fce",
"status": "finished",
"event_datetime": "2025-03-27 22:28:37",
"data": {
"interest_type": "pre_price_days",
"credit_operation_type": "ccb",
"interest_grace_period": 0,
"interest_payment_month_period": 1,
"principal_grace_period": 0,
"principal_amortization_month_period": 1,
"operation_type": "structured_operation",
"post_fixed_interest_base": "workdays",
"post_fixed_interest_rate": null,
"prefixed_interest_rate": {
"interest_base": "calendar_days_365",
"annual_rate": 0.23872053,
"monthly_rate": 0.0179999999,
"daily_rate": 0.0005866899
},
"issue_date": "2026-09-06",
"number_of_installments": 2,
"requester_key": "f2b3b903-aa41-4a79-8b2f-abc3cc5a6590",
"final_disbursement_amount": 701.6,
"total_pre_fixed_amount": 153.0,
"iof_amount": 18.34,
"cet": 0.0219,
"annual_cet": 0.297,
"disbursement_date": "2026-09-06",
"installments": [
{
"calendar_days": 207,
"workdays": 140,
"business_due_date": "2027-04-01",
"due_date": "2027-04-01",
"due_principal": 729.94,
"has_interest": true,
"post_fixed_amount": 0,
"pre_fixed_amount": 94.22564648,
"tax_amount": 8.22329794,
"total_amount": 578.69,
"principal_amortization_amount": 484.46435352,
"installment_number": 1
},
{
"calendar_days": 366,
"workdays": 253,
"business_due_date": "2028-04-03",
"due_date": "2028-04-01",
"due_principal": 245.47564648,
"has_interest": true,
"post_fixed_amount": 0,
"pre_fixed_amount": 58.77435352,
"tax_amount": 7.3470861,
"total_amount": 304.25,
"principal_amortization_amount": 245.47564648,
"installment_number": 2
}
],
"external_contract_fees": [
{
"fee_type": "tac",
"amount_type": "absolute",
"amount": 10.0,
"fee_amount": 10.0,
"tax_amount": 1.42,
"net_fee_amount": 8.58,
"csll_amount": 0,
"irrf_amount": 0,
"pis_amount": 0,
"cofins_amount": 0,
"amount_released": 8.58,
"description": null
},
{
"fee_type": "spread_tax_free",
"amount_type": "absolute",
"amount": 0.0,
"fee_amount": 0.0,
"tax_amount": 0.0,
"net_fee_amount": 0.0,
"csll_amount": 0,
"irrf_amount": 0,
"pis_amount": 0,
"cofins_amount": 0,
"amount_released": 0,
"description": null
},
{
"fee_type": "tac_tax_free",
"amount_type": "absolute",
"amount": 0.0,
"fee_amount": 0.0,
"tax_amount": 0.0,
"net_fee_amount": 0.0,
"csll_amount": 0,
"irrf_amount": 0,
"pis_amount": 0,
"cofins_amount": 0,
"amount_released": 0,
"description": null
},
{
"fee_type": "insurance_premium",
"amount_type": "absolute",
"amount": 0.0,
"fee_amount": 0.0,
"tax_amount": 0.0,
"net_fee_amount": 0.0,
"csll_amount": 0,
"irrf_amount": 0,
"pis_amount": 0,
"cofins_amount": 0,
"amount_released": 0,
"description": null
}
],
"contract_fee_amount": 3.65,
"external_contract_fee_amount": 10.0,
"net_external_contract_fee_amount": 8.58,
"contract_fees": [
{
"fee_type": "spread",
"amount_type": "percentage",
"amount": 0.5,
"fee_amount": 3.65
},
{
"fee_type": "spread_ted_fee",
"amount_type": "absolute",
"amount": 3.0,
"fee_amount": 3.0
}
],
"issue_amount": 729.94,
"disbursed_issue_amount": 701.6,
"assignment_amount": 736.59,
"disbursement_options": [
{
"iof_amount": 18.34,
"total_pre_fixed_amount": 153.0,
"cet": 0.0219,
"annual_cet": 0.297,
"contract_fees": [
{
"fee_type": "spread",
"amount_type": "percentage",
"amount": 0.5,
"fee_amount": 3.65
},
{
"fee_type": "spread_ted_fee",
"amount_type": "absolute",
"amount": 3.0,
"fee_amount": 3.0
}
],
"external_contract_fees": [
{
"fee_type": "tac",
"amount_type": "absolute",
"amount": 10.0,
"fee_amount": 10.0,
"tax_amount": 1.42,
"net_fee_amount": 8.58,
"csll_amount": 0.0,
"irrf_amount": 0.0,
"pis_amount": 0.0,
"cofins_amount": 0.0,
"amount_released": 8.58,
"description": null
},
{
"fee_type": "spread_tax_free",
"amount_type": "absolute",
"amount": 0.0,
"fee_amount": 0.0,
"tax_amount": 0.0,
"net_fee_amount": 0.0,
"csll_amount": 0,
"irrf_amount": 0,
"pis_amount": 0,
"cofins_amount": 0,
"amount_released": 0.0,
"description": null
},
{
"fee_type": "tac_tax_free",
"amount_type": "absolute",
"amount": 0.0,
"fee_amount": 0.0,
"tax_amount": 0.0,
"net_fee_amount": 0.0,
"csll_amount": 0,
"irrf_amount": 0,
"pis_amount": 0,
"cofins_amount": 0,
"amount_released": 0.0,
"description": null
},
{
"fee_type": "insurance_premium",
"amount_type": "absolute",
"amount": 0.0,
"fee_amount": 0.0,
"tax_amount": 0.0,
"net_fee_amount": 0.0,
"csll_amount": 0,
"irrf_amount": 0,
"pis_amount": 0,
"cofins_amount": 0,
"amount_released": 0.0,
"description": null
}
],
"contract_fee_amount": 3.65,
"external_contract_fee_amount": 10.0,
"net_external_contract_fee_amount": 8.58,
"disbursement_date": "2026-09-06",
"first_due_date": "2027-04-01",
"installments": [
{
"calendar_days": 207,
"workdays": 140,
"business_due_date": "2027-04-01",
"due_date": "2027-04-01",
"due_principal": 729.94,
"has_interest": true,
"post_fixed_amount": 0,
"pre_fixed_amount": 94.22564648,
"tax_amount": 8.22329794,
"total_amount": 578.69,
"principal_amortization_amount": 484.46435352,
"installment_number": 1
},
{
"calendar_days": 366,
"workdays": 253,
"business_due_date": "2028-04-03",
"due_date": "2028-04-01",
"due_principal": 245.47564648,
"has_interest": true,
"post_fixed_amount": 0,
"pre_fixed_amount": 58.77435352,
"tax_amount": 7.3470861,
"total_amount": 304.25,
"principal_amortization_amount": 245.47564648,
"installment_number": 2
}
],
"issue_amount": 729.94,
"disbursed_issue_amount": 701.6,
"assignment_amount": 736.59,
"final_disbursement_amount": 701.6,
"prefixed_interest_rate": {
"interest_base": "calendar_days_365",
"annual_rate": 0.23872053,
"monthly_rate": 0.0179999999,
"daily_rate": 0.0005866899
}
}
]
}
}


Definitions

Request Body

Borrower Object

FieldTypeDescriptionEnum
person_typeobjectLegal nature of the operation borrowernatural or legal

Financial Object

FieldTypeDescriptionMax. Char.
amoutfloatIssue/nominal value of the credit operation-
interest_typeobjectInterest Type Enumerator - Amortization method and interest calculation form-
credit_operation_typeobjectCredit Operation Type Enumerator - Type of credit contract-
annual_interest_ratefloatPre-fixed interest rate expressed as decimal per year-
disbursement_datedateOperation disbursement date-
interest_grace_periodintInterest grace period (in months)-
principal_grace_periodintPrincipal grace period-
number_of_installmentsintNumber of installments of the credit operation-
fine_configurationobjectfine_configuration Object - Interest and late fee configuration-

Fine Configuration Object

FieldTypeDescriptionMax. Char.
contract_fine_ratefloatLate fee percentage expressed as decimal-
interest_baseenumInterest Base Enumerator - Interest calculation base-
monthly_ratefloatLate interest percentage per month expressed as decimal-

Response Body

FieldTypeDescriptionMax. Char.
data.dataobjectData Object-
data.event_datetimedateSimulation generation timestamp-
data.keystringUnique simulation key-
data.statusstringfinished-
data.typestringdebt-

Data Object

FieldTypeDescriptionMax. Char.
annual_cetfloatTotal effective cost expressed as decimal per year-
assignment_amountfloatCredit operation acquisition value-
cetfloatTotal effective cost expressed as decimal per month-
contract_fee_amountfloatQI Tech fee charged on the operation-
contract_feesobjectContract Fees Object - List of QI Tech fees charged on the operation-
credit_operation_typeenumCredit Operation Type Enumerator - Type of credit contract-
disbursed_issue_amountfloatDisbursed value in the credit operation-
disbursement_datedateOperation disbursement date-
disbursement_optionslistList of operation disbursement options (financial values of the operation may vary according to disbursement day)-
external_contract_fee_amountfloatFee value charged on the operation rebated by QI to partner-
external_contract_feeslistContract Fees Object - List of fees charged on the operation rebated by QI to partner-
final_disbursement_amountfloatValue effectively disbursed to the borrower-
installmentslistInstallments Object - Operation installments-
interest_grace_periodintInterest grace period (in months)-
interest_payment_month_periodintInterest charge frequency in installments (in months)-
interest_typeenumInterest Type Enumerator - Amortization method and interest calculation form-
iof_amountfloatTotal IOF value (composed of the sum of Base IOF and Total IOF)-
issue_amountfloatIssue/nominal value of the credit operation-
issue_datedateOperation contract issue date-
net_external_contract_fee_amountfloatNet fee value charged on the operation rebated by QI to partner-
operation_typeenumOperation Type Enumerator-
post_fixed_interest_baseenumInterest Base Enumerator - Interest calculation base-
post_fixed_interest_rateobjectInterest Rate Object - Post-fixed interest indexer of the contract-
prefixed_interest_rateobjectInterest Rate Object - Pre-fixed nominal interest rate of the contract-
principal_amortization_month_periodintPrincipal charge frequency in installments (in months)-
principal_grace_periodintPrincipal grace period (in months)-
requester_keystringUnique identifying key of the partner within QI.-
total_pre_fixed_amountfloatTotal interest paid by the borrower in the credit operation-

Contract Fees Object

FieldTypeDescriptionMax. Char.
amountfloatFee value (in percentage or absolute value, depending on the value informed in the amount_type field-
amount_typeenumamount_type Enumerators - Fee value unit-
fee_amountfloatAbsolute fee value charged on the operation-
fee_typeenumFee Type Enumerator - Type of fee charged on the operation-

Installments Object

FieldTypeDescriptionMax. Char.
business_due_datedateInstallment due date on business day-
calendar_daysintHow many calendar days between one installment and another-
due_datedateInstallment due date on calendar day-
due_principalfloatRemaining principal on installment due date before its payment-
has_interestbooleantrue - Interest incidence indicator on installment-
installment_numberintInstallment number-
post_fixed_amountfloatPost-fixed interest value paid on installment-
pre_fixed_amountfloatPre-fixed interest value paid on installment-
principal_amortization_amountfloatAmortization value paid on installment-
tax_amountfloatInstallment Base IOF-
total_amountfloatTotal installment value-
workdaysintHow many business days between one installment and another-

Interest Rate Object

FieldDescriptionMax. Char.
annual_ratePre/post interest rate expressed as decimal per year-
daily_ratePre/post interest rate expressed as decimal per day-
interest_baseInterest Base Enumerator - Interest calculation base-
monthly_ratePre/post interest rate expressed as decimal per month-

Enumerators

Person Type Enumerator

EnumeratorDescription
legalLegal entity
naturalNatural person

Account Type Enumerator

EnumeratorDescription
checking_accountChecking account
deposit_accountDeposit account
guaranteed_accountGuaranteed account
investment_accountInvestment account
payment_accountPayment account
saving_accountSavings account
salary_accountSalary account

Amount Type Enumerator

EnumeratorDescription
absoluteAbsolute value
percentagePercentage value

Interest Type Enumerator

EnumeratorDescription
pre_price_daysPrice amortization method (equal installments) with pre-fixed interest calculation per day
pre_pricePrice amortization method (equal installments) with pre-fixed interest calculation in fixed periods (30 days)
pre_sacSAC amortization method (constant amortization) with pre-fixed interest calculation per day
post_sacSAC amortization method (constant amortization) with interest calculation based on a pre-fixed rate + post-fixed indexer (cdi, ipca or igpm) per day
post_pricePrice amortization method (equal installments) with interest calculation based on a pre-fixed rate + post-fixed indexer (cdi, ipca or igpm) in fixed periods (30 days)
post_price_daysPrice amortization method (equal installments) with interest calculation based on a pre-fixed rate + post-fixed indexer (cdi, ipca or igpm) per day

Credit Operation Type Enumerator

EnumeratorDescription
ccbBank Credit Note
cceExport Credit Note
cciReal Estate Credit Note
nceExport Credit Note

Interest Base Enumerator

EnumeratorDescription
workdaysInterest calculation base in business days considering a year of 252 days
calendar_daysInterest calculation base in calendar days considering a year of 360 days
calendar_days_365Interest calculation base in calendar days considering a year of 365 days

Fee Type Enumerator

Each fee type must be previously enabled and configured by QI Tech

EnumeratorDescription
tacAccount opening fee
spreadPremium charged on the credit operation acquisition value
warranty_analysisWarranty analysis fee
ted_feeTED fee
spread_ted_feeTED fee premium charged on the credit operation acquisition value