Brings together Endpoints intended for Charges management
Charge types
The list below, presents the Charge Types on Delbank
BANKSLIP: Conventional bank slip
BANKSLIP_PIX: A bankslip that cointains a QR Code and can also be paid using a Pix payment method
IMPORTANT: Before creating Charges of the BANKSLIP
and BANKSLIP_PIX
type, it will be necessary to configure the bank account as an Authorized Bank slip Emitter or in pt-BR “Cedente”.
You can request this adjust by talking with our Operational Team through email: [email protected].
General Technical Specifications
This section aims to highlight and explain technical elements common to all operations/processes.
In addition to the Authentication process explained above, for HTTP requests, some fields that involve business rules or general specifications of Delbank BaaS stand out.
Below are some fields present in the body of requests and deserve an additional explanation.
type
- Charge Type, previously presented, which in this case must be assigned the valueBANKSLIP
;correlationId
- corresponds to an identifier that guarantees uniqueness to that Charge internally to a system. This field reflects the internal control used in the system of the entity that consumes this API, that is, the client.ourNumber
- corresponds to an identifier for Delbank that allows monitoring or tracking of a Charge. This value will be displayed/recorded on Billing, and normally are presented as “Our Number”/ “Nosso Número”;yourNumber
- corresponds to an identifier for the issuer of the charge, which allows monitoring or tracking of the charge. This amount also will be displayed/recorded on the charge and are presented as "Document Number"/ “N° do Documento”.
Delbank understood that the other fields do not present great complexity or specific rules to be followed.
Creation
Creating a conventional charge
Método POST
https://apisandbox.delbank.com.br/v1/charges
A Cobrança Normal tem como foco o Título Simplificado que irá refletir na Carteira 112.
The Normal charge focuses on the simplified title that will be reflected in "Wallet 112"*.
Note*: Wallet is the way you choose to issue your bank slip. There are two types of wallets available: wallet 112 and wallet 121.
Given the current Billing category, it is not necessary to send the "outNumber" field, since its creation is the responsibility of Delbank.
Request Header and Body
Content-Type: application/json
x-delbank-api-key: API Key
{
"type": "BANKSLIP",
"correlationId": "CORRELATIONID",
"yourNumber": "SEUNUMERO",
"dueDate": "yyyy-mm-dd",
"Amount": 0.1,
"payer": {
"name": "fullname",
"document": "document",
"email": "[email protected]",
"phone": {
"prefix": "79",
"number": "900000000"
},
"address": {
"zipCode": "49000000",
"publicPlace": "public place",
"neighborhood": "neightborhood",
"number": "000",
"complement": "complement",
"city": "city",
"state": "SE"
}
}
}
Response Header and Body
Content-Type: application/json
{
"type": "BANKSLIP",
"amount": 0.1,
"yourNumber": "SEUNUMERO",
"ourNumber": "00000215634",
"correlationId": "68757f64-486c-41dc-b036-4e8cb5e62576",
"dueDate": "2023-04-01",
"barCode": "43596930700000000100001112000000600000215634",
"digitableLine": "43590001161200000060900002156347693070000000010",
"payer": {
"name": "FULANO CICLANO DA SILVA BELTRANO",
"document": "9999999999",
"email": "[email protected]",
"phone": {
"prefix": "79",
"number": "988669383"
},
"address": {
"zipCode": "49010030",
"publicPlace": "AV. RIO BRANCO",
"neighborhood": "CENTRO",
"number": "186",
"complement": "SALA 602",
"city": "ARACAJU",
"state": "SE"
}
},
"status": "Pending",
"updatedAt": "2022-12-07T18:16:47.347Z",
"createdAt": "2022-12-07T18:16:47.347Z"
}
Obs.: Unsuccessful requests will respond with their respective HTTP code and the following Body:
{
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.1",
"title": "One or more validation errors occurred.",
"status": 400,
"traceId": "00-fa5995742bd8906dfbaf6315d1d57d9e-e8c2cf5c14f5099f-00",
"errors": {
"$.dueDate": [
"The JSON value could not be converted to System.Nullable`1[System.DateTime]. Path: $.dueDate | LineNumber: 4 | BytePositionInLine: 25."
]
}
}
Creating an Express Charge
HTTP POST
https://apisandbox.delbank.com.br/v1/charges
Express charge focuses on the title generated by the customer, which will be reflected in "Wallet 121"*.
NOTE*: Wallet is the way you choose to issue your bank slip. There are two types of wallets available: wallet 112 and wallet 121.
Unlike conventional charges, in this type of charge it is necessary to send the "ourNumber" field.
Below are instructions and a template for carrying out this operation.
Request Headers and Body
Content-Type: application/json
x-delbank-api-key: API Key
{
"type": "BANKSLIP",
"correlationId": "CORRELATIONID",
"yourNumber": "SEUNUMERO",
"ourNumber": "00160860733",
"dueDate": "yyyy-mm-dd",
"Amount": 0.1,
"payer": {
"name": "fullname",
"document": "document",
"email": "[email protected]",
"phone": {
"prefix": "79",
"number": "900000000"
},
"address": {
"zipCode": "49000000",
"publicPlace": "public place",
"neighborhood": "neightborhood",
"number": "000",
"complement": "complement",
"city": "city",
"state": "SE"
}
}
}
Response Header and Body
Content-Type: application/json
{
"type": "BANKSLIP",
"amount": 0.1,
"yourNumber": "SEUNUMERO2",
"ourNumber": "00160860733",
"correlationId": "72b8e755-f620-4667-872f-529a87098d07",
"dueDate": "2023-04-01",
"barCode": "43591930700000000100001121000000600160860733",
"digitableLine": "43590001162100000060001608607337193070000000010",
"payer": {
"name": "FULANO CICLANO DA SILVA BELTRANO",
"document": "9999999999",
"email": "[email protected]",
"phone": {
"prefix": "79",
"number": "988669383"
},
"address": {
"zipCode": "49010030",
"publicPlace": "AV. RIO BRANCO",
"neighborhood": "CENTRO",
"number": "186",
"complement": "SALA 602",
"city": "ARACAJU",
"state": "SE"
}
},
"status": "Pending",
"updatedAt": "2022-12-07T21:28:39.663Z",
"createdAt": "2022-12-07T21:28:39.663Z"
}
Obs.: Failed requisistions will have the following HTTP and body:
{
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.1",
"title": "One or more validation errors occurred.",
"status": 400,
"traceId": "00-5d3f8bf7082b9428d8461b504dae9fc0-84ffab015d792b9f-00",
"errors": {
"$.dueDate": [
"The JSON value could not be converted to System.Nullable`1[System.DateTime]. Path: $.dueDate | LineNumber: 5 | BytePositionInLine: 25."
]
}
}
Creating a Title with Guarantor/Drawer
HTTP POST
https://apisandbox.delbank.com.br/v1/charges
This endpoint is used to create a Title, "Bank slip" (BANKSLIP) or "Bank slip pix" (BANKSLIP_PIX) with a Guarantor/Drawer (Final Beneficiary).
Request Headers and Body
Content-Type: application/json
x-delbank-api-key: API Key
{
"type": "BANKSLIP",
"correlationId": "CORRELATIONID",
"yourNumber": "SEUNUMERO",
"ourNumber": "00160860733",
"dueDate": "yyyy-mm-dd",
"Amount": 0.1,
"payer": {
"name": "fullname",
"document": "document",
"email": "[email protected]",
"phone": {
"prefix": "79",
"number": "900000000"
},
"address": {
"zipCode": "49000000",
"publicPlace": "public place",
"neighborhood": "neightborhood",
"number": "000",
"complement": "complement",
"city": "city",
"state": "SE"
}
},
"finalBeneficiary": {
"name": "fullname",
"document": "document",
"address": {
"zipCode": "49000000",
"publicPlace": "public place",
"neighborhood": "neightborhood",
"number": "000",
"complement": "complement",
"city": "city",
"state": "SE"
}
}
}
Response Header and Body
Content-Type: application/json
{
"type": "BANKSLIP",
"amount": 0.1,
"yourNumber": "SEUNUMERO2",
"ourNumber": "00160860733",
"correlationId": "72b8e755-f620-4667-872f-529a87098d07",
"dueDate": "2023-04-01",
"barCode": "43591930700000000100001121000000600160860733",
"digitableLine": "43590001162100000060001608607337193070000000010",
"payer": {
"name": "FULANO CICLANO DA SILVA BELTRANO",
"document": "9999999999",
"email": "[email protected]",
"phone": {
"prefix": "79",
"number": "988669383"
},
"address": {
"zipCode": "49010030",
"publicPlace": "AV. RIO BRANCO",
"neighborhood": "CENTRO",
"number": "186",
"complement": "SALA 602",
"city": "ARACAJU",
"state": "SE"
}
},
"status": "Pending",
"updatedAt": "2022-12-07T21:28:39.663Z",
"createdAt": "2022-12-07T21:28:39.663Z"
}
Obs.: Failed requisistions will have the following HTTP and body:
{
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.1",
"title": "One or more validation errors occurred.",
"status": 400,
"traceId": "00-3d4d68882c19524d921cc791e2a5e7ee-166c8e241265c3d3-00",
"errors": {
"$.dueDate": [
"The JSON value could not be converted to System.Nullable`1[System.DateTime]. Path: $.dueDate | LineNumber: 6 | BytePositionInLine: 25."
]
}
}
Creating a Title with Guarantor/Drawer
HTTP POST
https://apisandbox.delbank.com.br/v1/charges
This endpoint is used to create a Charge of type "Pix Bank Slip". In this modality, the Title will be issued in Wallet 112
Request Headers and Body
Content-Type: application/json
x-delbank-api-key: API Key
{
"type": "BANKSLIP_PIX",
"yourNumber": "SEUNUMERO",
"correlationId": "72b8e755-f620-4667-872f-529a87098d07",//uid único para cada request
"dueDate": "yyyy-mm-dd",
"Amount": 0.1,
"payer": {
"name": "fullname",
"document": "document",
"email": "[email protected]",
"phone": {
"prefix": "79",
"number": "900000000"
},
"address": {
"zipCode": "49000000",
"publicPlace": "public place",
"neighborhood": "neightborhood",
"number": "000",
"complement": "complement",
"city": "city",
"state": "SE"
}
},
"discount": {
"type": "Fixed",
"items": [
{
"date": "yyyy-mm-dd",
"amount": 0.01
},
{
"date": "yyyy-mm-dd",
"amount": 0.01
},
{
"date": "yyyy-mm-dd",
"amount": 0.01
}
]
},
"lateFine": {
"type": "Percentage",
"date": "yyyy-mm-dd",
"amount": 2.5
},
"latePayment": {
"type": "Fixed",
"date": "yyyy-mm-dd",
"amount": 2.5
}
}
Response Header and Body
Content-Type: application/json
{
"type": "PIX_STATIC",
"correlationId": "e2590eaa-ca27-4d25-8170-48844785af75",
"amount": 1.99,
"description": "Serviço Realizado.",
"additionalInfo": [
{
"key": "Campo 1",
"value": "Informação Adicional1 do PSP-Recebedor"
}
],
"status": "Created",
"qrCode": "00020101021226790014br.gov.bcb.pix2557pix-h.delbank.com.br/v1/...",
"payments": [],
"createdAt": "2022-09-22T17:28:51.882Z",
"updatedAt": "2022-09-22T17:28:51.882Z"
}
Obs.: Failed requisistions will have the following HTTP and body:
{
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.1",
"title": "One or more validation errors occurred.",
"status": 400,
"traceId": "00-61a3e8c33796e9a3ff0af8052db87afc-ea172db465a74b7f-00",
"errors": {
"$.dueDate": [
"The JSON value could not be converted to System.Nullable`1[System.DateTime]. Path: $.dueDate | LineNumber: 4 | BytePositionInLine: 25."
]
}
}
Creating a Title with discount, fine and late payment
HTTP POST
https://apisandbox.delbank.com.br/v1/charges?2ad27621-b0b2-4a96-8302-838ce5c4cfeb
This endpoint is used to create a Charge of type "Pix Bank Slip". In this modality, the Title will be issued in Wallet 112
Request Headers and Body
Content-Type:application/json
x-delbank-api-key:Api Key
{
"type": "BANKSLIP_PIX",
"correlationId": "SEUIDSEUIDSEUID",
"yourNumber": "SEUNUMEROSEU",
"dueDate": "2023-04-01",
"Amount": 0.1,
"payer": {
"name": "FULANO CICLANO",
"document": "16166823533",
"email": "[email protected]",
"phone": {
"prefix": "79",
"number": "988669383"
},
"address": {
"zipCode": "49010030",
"publicPlace": "AV. RIO BRANCO",
"neighborhood": "CENTRO",
"number": "186",
"complement": "SALA 602",
"city": "ARACAJU",
"state": "SE"
}
},
"discount": {
"type": "Fixed",
"items": [
{
"date": "2023-03-26",
"amount": 0.01
},
{
"date": "2023-03-27",
"amount": 0.01
},
{
"date": "2023-03-28",
"amount": 0.01
}
]
},
"lateFine": {
"type": "Percentage",
"date": "2023-04-02",
"amount": 2.5
},
"latePayment": {
"type": "Fixed",
"date": "2023-04-02",
"amount": 2.5
}
}
Response Header and Body
Content-Type:application/json
{
"type": "PIX_STATIC",
"correlationId": "e2590eaa-ca27-4d25-8170-48844785af75",
"amount": 1.99,
"description": "Serviço Realizado.",
"additionalInfo": [
{
"key": "Campo 1",
"value": "Informação Adicional1 do PSP-Recebedor"
}
],
"status": "Created",
"qrCode": "00020101021226790014br.gov.bcb.pix2557pix-h.delbank.com.br/v1/...",
"payments": [],
"createdAt": "2022-09-22T17:28:51.882Z",
"updatedAt": "2022-09-22T17:28:51.882Z"
}
Requisições malsucedidas responderão com seu respectivo código HTTP e o seguinte corpo:
{
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.1",
"title": "One or more validation errors occurred.",
"status": 400,
"traceId": "00-7a12cadb81f68cdb4dae6b62afadd36b-55605d5867652ca6-00",
"errors": {
"$.dueDate": [
"The JSON value could not be converted to System.Nullable`1[System.DateTime]. Path: $.dueDate | LineNumber: 4 | BytePositionInLine: 25."
]
}
}
Creating an Immediate Static Pix Charge
HTTP POST
https://apisandbox.delbank.com.br/v1/charges?3e917941-7f52-4ccd-a4e6-8828694c3907
Endpoint to create an immediate charge without a payer
Request Headers and Body
Content-Type:application/json
x-delbank-api-key:Api Key
{
"type": "PIX_STATIC",
"correlationId": "e2590eaa-ca27-4d25-8170-48844785af75",
"amount": 1.99,
"description": "Serviço Realizado.",
"additionalInfo": [
{
"key": "Campo 1",
"value": "Informação Adicional1 do PSP-Recebedor"
}
]
}
Response Headers and Body
Content-Type:application/json
{
"type": "PIX_STATIC",
"correlationId": "e2590eaa-ca27-4d25-8170-48844785af75",
"amount": 1.99,
"description": "Serviço Realizado.",
"additionalInfo": [
{
"key": "Campo 1",
"value": "Informação Adicional1 do PSP-Recebedor"
}
],
"status": "Created",
"qrCode": "00020101021226790014br.gov.bcb.pix2557pix-h.delbank.com.br/v1/...",
"payments": [],
"createdAt": "2022-09-22T17:28:51.882Z",
"updatedAt": "2022-09-22T17:28:51.882Z"
}
Obs.: Failed requisistions will have the following HTTP and body:
{
"errors": [
"O campo AdditionalInfo (Valor Da Informação Aditional) não pode ser maior que 37 caracteres para o produto do tipo PIX_STATIC."
],
"errorMessage": "O campo AdditionalInfo (Valor Da Informação Aditional) não pode ser maior que 37 caracteres para o produto do tipo PIX_STATIC."
}
Endpoint to create a Charge with due date
Método POST
https://apisandbox.delbank.com.br/v1/charges
Endpoint to create a Charge with due date
Request Headers and Body
Content-Type:application/json
x-delbank-api-key:Api Key
{
"type": "PIX_STATIC",
"correlationId": "e2590eaa-ca27-4d25-8170-48844785af75",
"amount": 1.99,
"description": "Serviço Realizado.",
"additionalInfo": [
{
"key": "Campo 1",
"value": "Informação Adicional1 do PSP-Recebedor"
}
]
}
Response Headers and Body
Content-Type:application/json
{
"type": "PIX_STATIC",
"correlationId": "e2590eaa-ca27-4d25-8170-48844785af75",
"amount": 1.99,
"description": "Serviço Realizado.",
"additionalInfo": [
{
"key": "Campo 1",
"value": "Informação Adicional1 do PSP-Recebedor"
}
],
"status": "Created",
"qrCode": "00020101021226790014br.gov.bcb.pix2557pix-h.delbank.com.br/v1/...",
"payments": [],
"createdAt": "2022-09-22T17:28:51.882Z",
"updatedAt": "2022-09-22T17:28:51.882Z"
}
Obs.: Failed requisistions will have the following HTTP and body:
{
"errors": [
"O campo Amount (Valor) deve ser maior que 0."
],
"errorMessage": "O campo Amount (Valor) deve ser maior que 0."
}
Charge Query
The charge querying will be in a synchronous format
Charge Query by Correlation Id [GET]
https://apisandbox.delbank.com.br/v1/charges/correlationId
The consultation will provide charge data with already consolidated information.
Request Headers and Body
Content-Type:application/json
x-delbank-api-key:Api Key
Response Headers and Body
Content-Type:application/json
{
"type": "PIX_DYNAMIC",
"correlationId": "e2590eaa-ca27-4d25-8170-48844785af75",
"amount": 1.99,
"expiresIn": 100,
"payer": {
"name": "EXAMPLE HARDCODE",
"document": "18412116216"
},
"additionalInfo": [
{
"key": "Campo 1",
"value": "Informação Adicional1 do PSP-Recebedor"
},
{
"key": "Campo 2",
"value": "Informação Adicional2 do PSP-Recebedor"
}
],
"status": "Created",
"qrCode": "00020101021226790014br.gov.bcb.pix2557pix-h.delbank.com.br/v1/...",
"payments": [],
"createdAt": "2022-09-22T17:28:51.882Z",
"updatedAt": "2022-09-22T17:28:51.882Z"
}
Obs.: Failed requisistions will have the following HTTP and body:
{
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.4",
"title": "Not Found",
"status": 404,
"traceId": "00-72c40340fe67d8caed8275ee6e37a7a6-52bb2d57c1652859-00"
}
Paginated Charge Query by date range [GET]
https://apisandbox.delbank.com.br/v1/charges?startDate=&endDate=&page=&limit=
The paginated query is limited to 100 items per page, and a maximum range of 1 year.
Note: Delbank currently do not provide a variety of filters as a way of encouraging the receipt of notifications and individual handling of charges. If necessary, a specific report can be requested and exported.
Request Headers
Content-Type:application/json
x-delbank-api-key:Api Key
Response Headers and Body
Content-Type:application/json
[
{
"type": "PIX_DYNAMIC",
"correlationId": "e2590eaa-ca27-4d25-8170-48844785af75",
"amount": 1.99,
"expiresIn": 100,
"payer": {
"name": "EXAMPLE HARDCODE",
"document": "18412116216"
},
"additionalInfo": [
{
"key": "Campo 1",
"value": "Informação Adicional1 do PSP-Recebedor"
},
{
"key": "Campo 2",
"value": "Informação Adicional2 do PSP-Recebedor"
}
],
"status": "Created",
"qrCode": "00020101021226790014br.gov.bcb.pix2557pix-h.delbank.com.br/v1/...",
"payments": [],
"createdAt": "2022-09-22T17:28:51.882Z",
"updatedAt": "2022-09-22T17:28:51.882Z"
}
]
Obs.: Failed requisistions will have the following HTTP and body:
{
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.1",
"title": "One or more validation errors occurred.",
"status": 400,
"traceId": "00-55c382b4ece012e01dc19131929cea5c-6d6bb173dab9f992-00",
"errors": {
"endDate": [
"The value 'yyyy-mm-dd' is not valid."
],
"startDate": [
"The value 'yyy-mm-dd' is not valid."
]
}
}
Charge Maintenance
The charge write-off /void order does not make it impossible to receive payments that have already been made.
Partial Charge Update example [PATCH]
https://apisandbox.delbank.com.br/v1/charges/correlationId
Delbank currently provide the partial update of the charge, thus being able to change Its due date.
Request Headers and Body
Content-Type:application/json
x-delbank-api-key:Api Key
{
"walletNumber": "112",
"yourNumber": "SEUNUMERO",
"amount": 10,
"dueDate": "2022-06-13",
"payer": {
"name": "FULANO CICLANO",
"document": "16166823533",
"zipCode": "49010030",
"address": "AV. RIO BRANCO, 186",
"neighborhood": "CENTRO",
"state": "SE",
"city": "ARACAJU"
},
"discount": {
"type": "Fixed",
"items": [
{
"date": "yyyy-MM-dd",
"amount": 0
},
{
"date": "yyyy-MM-dd",
"amount": 0
},
{
"date": "yyyy-MM-dd",
"amount": 0
}
]
},
"lateFine": {
"type": "Percentage",
"date": "yyyy-MM-dd",
"amount": 0
},
"latePayment": {
"type": "Percentage",
"date": "yyyy-MM-dd",
"amount": 0
},
"allowPartialPayment": false
}
Response Header
Content-Type:text/plain
Obs.: Failed requisistions will have the following HTTP and body:
{
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.1",
"title": "One or more validation errors occurred.",
"status": 400,
"traceId": "00-d4f01e7c0b935601aa07789983ec6228-6fffc4c2b5f642dc-00",
"errors": {
"$.dueDate": [
"The JSON value could not be converted to System.Nullable`1[System.DateTime]. Path: $.dueDate | LineNumber: 4 | BytePositionInLine: 25."
]
}
}
Charge write-off /void order [POST]
https://apisandbox.delbank.com.br/v1/charges/correlationId/void
Endpoint to write-off/cancel the charge.
Request Header
x-delbank-api-key:Api Key
Response Header
Content-Type:application/json
Obs.: Failed requisistions will have the following HTTP and body:
{
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.4",
"title": "Not Found",
"status": 404,
"traceId": "00-8a3919c1917bff4f84367110dcf0680a-e156f57e8851b5be-00"
}
Printing/Downloading
Below are some endpoints with examples of PDFs printing and generation of QR Codes
Print bank slip [GET]
https://apisandbox.delbank.com.br/v1/charges/correlationId/stream
Endpoint for printing the charge
[### Request Header](### Request Header)
x-delbank-api-key:Api Key
Response Header
Content-Type:application/pdf
Obs.: Failed requisistions will have the following HTTP and body:
{
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.4",
"title": "Not Found",
"status": 404,
"traceId": "00-f94523a9cff07f9f4b94a6f97837f657-e010fb53ce385f31-00"
}
Staging Environment
Following the endpoints to facilitate tests in staging environment
Charge payment [POST]
https://apisandbox.delbank.com.br/v1/charges/correlationId/pay
The charge payment route is an approval route for integration testing and validation of notifications.
Request Header
x-delbank-api-key: API Key
Response Header
Content-Type:application/json
Obs.: Failed requisistions will have the following HTTP and body:
{
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.4",
"title": "Not Found",
"status": 404,
"traceId": "00-9954e85487cfc65b8841f40c572d181b-d5bf166c3d9c1c1a-00"
}
Charge Expiration [PUT]
https://apisandbox.delbank.com.br/v1/charges/correlationId/expire
The charge expiration route is also an approval route for integration testing and validation of notifications.
NOTE: It will affect the original expiration date of the charge entered.
Request header
x-delbank-api-key:Api Key
Response Header
Content-Type:application/json
Obs.: Failed requisistions will have the following HTTP and body:
{
"type": "https://tools.ietf.org/html/rfc7231#section-6.5.4",
"title": "Not Found",
"status": 404,
"traceId": "00-2229624b5844efe7720e367e25a6bbc8-dea6734e79cf24f8-00"
}