Payment configuration overview

The payment configuration represents an abstract entity containing information that characterizes payment options. Each offer can have multiple payment configurations associated with it.

Company global configuration

Additionally, the company, which represents our partner, also has a global payment configurations associated with it. These payment configurations serve as defaults, defining maximum or minimum values for certain fields.

When configuring offers, pay attention to the following restricted fields:

  • interest_rate: Must be lower than the default value.
  • max_installments: Must be lower than the default value.
  • down_payment_value: Must be higher than the default value when translated to an absolute value.

Calculating correct down payment for offer

We have a registration fee that is included in the down_payment, so for example if you want to create a first bill with a specific value, the calculation is as follows:

first_bill_amount = down_payment_value + (registration_fee * offer_amount)

Lets create an offer with a first bill of R$ 60,00. In this case the offer will have an amount_cents of 77400:

The registration fee is returned in the global config of your company, in this case lets use a value of 0.0197. So to create an offer with a total of R$ 60,00 in the first bill you will have to calculate the down_payment:

first_bill_amount = down_payment_value + (registration_fee * offer_amount)
down_payment_value = first_bill_amount - (registration_fee * offer_amount)
down_payment_value = 6000 - (0.0197 * 77400)
~4475

So if you create a payment_configuration with a down_payment_value: 4475 in this offer, the result will be a first bill of R$ 60,00

Payment Configuration Schema

FieldDescriptionType
idUnique identifier (UUID)String
payment_typeType of payment option. Can be upfront (full payment) or financed (installment plan)String
installmentsRange or array of allowed installment numbersObject
max_installmentsMaximum number of installments the customer can choose for the purchaseInteger
down_payment_typeHow down payment is calculated. Can be percentage or absoluteString
down_payment_valueDown payment value - in cents if type is absolute, or as decimal if type is percentage (e.g., 0.20 for 20%)Float
fee_embedded_in_down_paymentWhether the registration fee is embedded in the down payment amountBoolean
min_installment_amount_centsMinimum amount in cents required for each installmentInteger
availabilityConfiguration availability status. Can be enabled or disabledString
financed_typeType of financing. Can be bolepix (boleto/PIX payments) or card (credit card)String
expires_inNumber of hours until the down payment expires (Maximum: 72 hours)Integer
interest_rateMonthly interest rate applied to financed installments (as decimal, e.g., 0.0199 for 1.99%)Float
registration_feeRegistration fee percentage charged on the down payment (as decimal, e.g., 0.0197 for 1.97%)Float
allowed_down_payment_methodsArray of payment methods allowed for the down payment (first installment)Array
payment_methodsArray of payment methods available for recurring installment billsArray
max_down_payment_installmentsMaximum number of installments allowed for the down payment when using credit cardInteger
down_payment_interest_rateInterest rate applied to down payment installments (only for credit card down payments)Float
take_rate_typeHow the platform take rate is calculated. Can be absolute (fixed amount) or percentage (percentage of amount)String
take_rate_valuePlatform take rate value - either fixed amount in cents or percentage as decimalFloat
metadataAdditional custom metadata stored as key-value pairsObject
payment_method_configurationsArray of payment method configuration objects defining specific settings for each payment methodArray

Payment Type Values

ValueDescription
upfrontFull payment made at once, with no financing or installments
financedPayment plan with installments, including a down payment and recurring monthly bills

Down Payment Type Values

ValueDescription
absoluteThe down_payment_value represents a fixed amount in cents
percentageThe down_payment_value represents a percentage of the total amount (as decimal, e.g., 0.25 = 25%)

Financed Type Values

ValueDescription
bolepixFinancing using boleto (bank slip) or PIX payment methods
cardFinancing using credit card payments

Table of contents