Request payment of collection invoice (agreement/tribute)
This endpoint allows the payment request for collection invoices with two-factor authentication. The request should be made after a consultation, using the returned information to ensure the correct flow and avoid failures during the process.
This type of charge is issued by utility companies (water, electricity, telephone, and gas bills) and public entities (taxes). They are not registered with the Interbank Payment Clearinghouse (CIP/Núclea) and, therefore, do not return the same information as a boleto.
Request
Request Endpoint
Request Path Params
Field | Type | Description | Characters |
---|---|---|---|
account_key * | uuid4 | Unique account identification key. | 36 |
Request Body: Collection invoice request with digitable line
{
"request_control_key": "b6804f32-101e-4702-8fbc-c2dbc4c2caec",
"digitable_line": "00190000090361557400500000024174396700000991000",
"payment_amount": 1156.8,
"tfa_info": {
"approver_document_number": "98765432100",
"contact_type": "email"
}
}
Request Body: Collection invoice request with barcode
{
"request_control_key": "b6804f32-101e-4702-8fbc-c2dbc4c2caec",
"barcode": "00190000090361557400500000024174396700000991000",
"payment_amount": 1156.8,
"tfa_info": {
"approver_document_number": "98765432100",
"contact_type": "email"
}
}
Body Params
Field | Type | Description |
---|---|---|
request_control_key * | uuid4 | Unique identification key for the client's request. |
barcode | string | Barcode. |
digitable_line | string | Digitable line. |
payment_amount * | number | Amount to be paid. |
tfa_info * | object | Object containing the document of the account approver and the means of contact. |
The payment_amount
must always be equal to the total_amount
returned in the boleto query.
Object tfa_info
Field | Type | Description |
---|---|---|
approver_document_number * | string | Document number of the account approver (CPF/CNPJ). |
contact_type * | string | Means of contact with the account approver, can be sms or email |
Response
Success Response
Response Body: Payment pending two-factor approval
{
"payment_key": "33860ad0-bcb0-47b7-bbe7-c7e3ec2fc61a",
"request_control_key": "ae4508df-f2cb-4e28-9f04-a19b7f2758c9",
"payer_name": "COOPERATIVA INDUSTRIAL MURILO",
"payer_document_number": "62069937000118",
"source_account_key": "daae79e6-ee8b-449f-aa1e-96959d5d5a72",
"transaction_key": "fc9ccfd0-2f21-4207-9772-69238be74152",
"transaction_revert_key": null,
"paid_amount": 1389.21,
"payment_date": "2024-04-30",
"payment_type": "collection_slip",
"bank_slip": null,
"collection_slip": {
"barcode": null,
"digitable_line": "836200000138892100450006762142420244046000010192",
"collection_name": "CIA ULTRAGAZ SA-COD",
"collection_document_number": "00394460005887",
"expiration_date": "2024-04-15",
"total_amount": 1389.21
},
"payment_status": "pending_2fa_approval"
}
Response Body Params
Field | Type | Description |
---|---|---|
payment_key * | uuid4 | Unique payment identification key. |
request_control_key * | uuid4 | Unique identification key for the client's request. |
payer_name * | string | Name of the effective payer. |
payer_document_number * | string | Document of the effective payer (CPF/CNPJ). |
source_account_key * | uuid4 | Key of the debited account. |
transaction_key * | uuid4 | Payment transaction key. |
transaction_revert_key | uuid4 | Payment reversal transaction key. |
paid_amount * | number | Amount effectively paid. |
payment_date * | string | Payment date. |
payment_type * | enum | Payment type. |
bank_slip | object | Boleto bancário. |
collection_slip | object | Collection invoice. |
payment_status * | enum | Payment status. |
Enumerators payment_type
Enumerator | Type | Description |
---|---|---|
bank_slip | string | Boleto bancário |
collection_slip | string | Collection invoice |
The enumerator bank_slip
does not apply to the collection invoice flow, and the bank_slip object will always be null.
Enumerators payment_status
Enumerator | Description |
---|---|
pending_2fa_approval | pending two-factor approval |
Object collection_slip
Field | Type | Description |
---|---|---|
barcode | string | Barcode. |
digitable_line | string | Digitable line. |
collection_name * | string | Name of the agreement. |
collection_document_number | string | Document number of the agreement (CPF/CNPJ). |
expiration_date * | string | Due date. |
total_amount * | number | Total amount. |
Error Response
Response Body
{
"title": "Título",
"description": "Description in english",
"translation": "Description in portuguese",
"code": "Código"
}
HTTP Code | QI Code | Title | Description (eng) | Description (pt-br) |
---|---|---|---|---|
400 | BIP000032 | Bad Request | The bill sent does not correspond to a collection slip. | A conta enviada não corresponde a uma fatura de recolhimento. |
400 | BIP000033 | Bad Request | The barcode or digitable line of the collection slip must have 44 or 48 characters. | O código de barras ou linha digitável da fatura de recolhimento deve ter 44 ou 48 caracteres. |
403 | BIP000010 | Forbidden | User is not allowed to do this action | Usuário não tem autorização para fazer essa ação |
404 | BIP000011 | Not Found | The source account key was not found. | A chave da conta de origem não foi encontrada. |
400 | BIP000012 | Bad Request | It was not possible to consult the source account at this time. Please try again in a few minutes. | Não foi possível consultar a conta de origem neste momento. Por favor, tente novamente em alguns minutos. |
400 | BIP000013 | Bad Request | The source account is closed. | A conta de origem está fechada. |
400 | BIP000014 | Bad Request | The source account is blocked. | A conta de origem está bloqueada. |
400 | BIP000024 | Bad Request | Request control key already exists. | Chave de controle da requisição já existe. |
400 | BIP000028 | Bad Request | The source account has blocked balance. Payment cannot be made. | A conta de origem possui saldo em conta bloqueado. Pagamento não pode ser realizado. |
400 | BIP000034 | Bad Request | Collection slip already paid. | Fatura de recolhimento já paga. |
400 | BIP000035 | Bad Request | Covenant slip invalid barcode. | Código de barras da fatura de recolhimento inválido. |
400 | BIP000036 | Bad Request | Covenant slip overdue. | Fatura de recolhimento vencida. |
400 | BIP000037 | Bad Request | Error in collection slip consultation. | Erro na consulta da fatura de recolhimento. |
400 | BIP000038 | Bad Request | Outside of covenant payment hours. | Fora do horário de pagamento do convênio. |
400 | BIP000039 | Bad Request | Collection slip not accepted. | Fatura de recolhimento não aceita. |
400 | BIP000040 | Bad Request | Minimum advance not reached. | Mínimo de dias de adiantamento não atingido. |
400 | BIP000041 | Bad Request | Max payment amount exceeded. | Valor máximo de pagamento excedido. |
400 | BIP000044 | Bad Request | It was not possible to pay the collection slip at this time. Please verify your information and, if necessary, contact us for assistance. | Não foi possível pagar a fatura de recolhimento neste momento. Por favor, verifique suas informações e, se necessário, entre em contato conosco para assistência. |
403 | BIP000052 | Forbidden | Given document number does not belong to an approver for this account | Número de documento enviado não pertence a um aprovador da conta |
400 | BIP000053 | Bad Request | Error getting approver data | Erro ao obter dados do aprovador |
400 | BIP000054 | Bad Request | TFA info required | Informações de TFA necessárias |
400 | BIP000055 | Bad Request | Error sending verification token | Erro ao enviar token de verificação |
400 | BIP000065 | Bad Request | Payment verification time window exceeded. | Janela de tempo de verificação de pagamento excedida. |
Sandbox Environment
In our sandbox environment, we provide mocked digitable lines for simulating successful payments and testing error scenarios.
Digitable Line |
---|
828300000007411100972013905080001546763201900028 |
838000000009235700481007241345219112001474229880 |
848000000006308600802021201071261517689002201070 |
858200000015000000643025703477209504800448091020 |
858500000037350000643217212883260006147448091022 |