Skip to main content
POST
Initiate a DARF payment

Autorizaciones

Authorization
string
header
requerido

JWT bearer token issued by the identity provider.

Encabezados

X-Organization-Id
string

Tenant organization ID. Accepted but ignored: the tenant is determined by the credentials you authenticate with, so sending this header, or sending a different value in it, changes nothing.

Idempotency-Key
string

Client-supplied idempotency key. Required in practice even though the schema marks it optional: a request that omits this header is refused with 400 PBP-0012.

Cuerpo

application/json
fineAmount
string
requerido

Fine amount as a decimal string, up to two decimal places. Must be non-negative.

Maximum string length: 32
Ejemplo:

"5.00"

interestAmount
string
requerido

Interest amount as a decimal string, up to two decimal places. Must be non-negative.

Maximum string length: 32
Ejemplo:

"10.00"

mainAmount
string
requerido

Principal amount as a decimal string, up to two decimal places. Must be positive.

Maximum string length: 32
Ejemplo:

"100.00"

midazAccountId
string
requerido

Midaz account the payment settles from.

name
string
requerido

Taxpayer name, up to 80 bytes (UTF-8; accented characters count as more than one byte).

Ejemplo:

"Fulano de Tal"

personType
string
requerido

Taxpayer person type: F for an individual (CPF, 11 digits) or J for a legal entity (CNPJ, 14 digits). It must agree with taxId: a length that does not match the person type, or a failing check digit, is refused with 400 PBP-0200.

Ejemplo:

"F"

referenceDate
string<date>
requerido

Tax period reference date, YYYY-MM-DD.

Ejemplo:

"2026-04-01"

taxId
string
requerido

Taxpayer CPF or CNPJ, digits only. Its length and check digits are validated against personType.

Ejemplo:

"12345678909"

treasuryRevenueCode
string
requerido

Federal treasury revenue code (codigo da receita): the four zero-padded digits listed in the tax code catalogue the provider publishes as TaxMessageCodes.pdf. Send the four digits alone — the service prefixes them with TRC_ on the way to the provider, and a value that already carries that prefix is forwarded unchanged. The code is not checked against the catalogue here; an unknown code is refused by the provider.

Ejemplo:

"0086"

type
string
requerido

DARF type: S for Simples, N for Normal.

Ejemplo:

"S"

description
string

Optional free-text description carried on the payment.

dueDate
string

Optional due date, YYYY-MM-DD.

history
string

Optional free-text history carried on the payment.

referenceNumber
integer<int64>

Optional reference number carried to the tax authority.

totalIncomeAmount
string

Optional total income amount as a decimal string.

Maximum string length: 32
totalIncomePercent
string

Optional total income percentage as a decimal string.

Maximum string length: 32

Respuesta

Created

createdAt
string
requerido
id
string
requerido
providerId
string
requerido
status
string
requerido
totalAmount
string
requerido
type
string
requerido