Skip to main content

Invoice Payment Webhooks

Attention!

QI Tech webhooks should not be mapped restrictively. Additional fields may be included in the webhook payloads returned by our APIs.

Webhook Resending

You can check and resend webhooks by following the detailed instructions in the documentation: Webhook Resending.

Introduction

After a status change of an invoice payment (invoice_payment) within our system, a webhook will be sent with the payment status change:

EnumeratorTranslationDescription
processing_paymentawaiting paymentInvoice payment awaiting payment
paidpaidInvoice payment paid
Information

The timeout for response to our webhooks is 10 seconds.

Examples

Invoice payment (payroll_discount)

Webhook Body
{
"webhook_type": "baas.invoice.invoice_payment_status_change",
"webhook_datetime": "2024-08-13T21:35:55.679Z",
"data": {
"wallet_key": "8cb70dea-9fb0-4a68-9572-99a72849c8d6",
"invoice_payment_key": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"total_amount": 350.00,
"paid_amount": 0.00,
"payment_date": "2024-02-15",
"invoice_payment_type": "payroll_discount",
"invoice_payment_status": "processing_payment"
}
}

Invoice payment (bank_slip)

Webhook Body
{
"webhook_type": "baas.invoice.invoice_payment_status_change",
"webhook_datetime": "2024-08-13T21:35:55.679Z",
"data": {
"wallet_key": "8cb70dea-9fb0-4a68-9572-99a72849c8d6",
"invoice_payment_key": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"total_amount": 350.00,
"paid_amount": 0.00,
"payment_date": "2024-02-15",
"invoice_payment_type": "bank_slip",
"invoice_payment_status": "processing_payment"
}
}

Webhook Fields

FieldTypeDescriptionCharacters
wallet_keystringUnique wallet identification key in uuid v4 format36
invoice_payment_keystringUnique invoice payment identification key in uuid v4 format36
total_amountnumberTotal amount of the invoice payment-
paid_amountnumberPaid amount of the invoice payment-
payment_datestringPayment date (YYYY-MM-DD format)10
invoice_payment_typestringInvoice payment typeinvoice_payment_type Enumerators
invoice_payment_statusstringInvoice payment statusinvoice_payment_status Enumerators

invoice_payment_type Enumerators

EnumeratorDescription
bank_slipBank slip
payroll_discountPayroll discount

invoice_payment_status Enumerators

EnumeratorDescription
processing_paymentInvoice payment awaiting payment
paidInvoice payment paid
Note
  • For payroll_discount type payments: the payment is created at the time of invoice closing with processing_payment status and the discount is requested from INSS. When the discount payment is made, the status changes to paid.
  • For bank_slip type payments: the payment is created with processing_payment status when we receive the bank slip payment notice. At the time of bank slip settlement, the status changes to paid. The payment can be created with paid status directly if a payment notice is not received.