Skip to main content
POST
/
v1
/
collections
/
duedate
Create a Dynamic Charge with Due Date
curl --request POST \
  --url https://plugin-pix-indirect.api.lerian.net/v1/collections/duedate \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'X-Account-Id: <x-account-id>' \
  --data '
{
  "amount": {
    "original": "100.00"
  },
  "debtor": {
    "document": "12345678901",
    "name": "João da Silva",
    "address": "Rua das Flores, 123",
    "city": "São Paulo",
    "email": "joao@example.com",
    "state": "SP",
    "zipCode": "01310-100"
  },
  "dueDate": "2024-12-31",
  "receiverKey": "+5511999999999",
  "txId": "TXabcdefghijklmno123456789",
  "validAfterDue": 5,
  "additionalInfo": {
    "customerId": "67890",
    "orderId": "12345"
  },
  "description": "Payment for order #12345",
  "locationInformation": {
    "categoryCode": "5411",
    "merchantCity": "São Paulo",
    "merchantName": "Loja ABC",
    "postalCode": "01310-100"
  },
  "metadata": {},
  "tags": [
    "ecommerce",
    "subscription"
  ]
}
'
{
  "additionalInfo": {
    "customerId": "67890",
    "orderId": "12345"
  },
  "amount": {
    "original": "100.00",
    "abatement": {
      "modality": "PERCENT",
      "value": "3.00"
    },
    "discount": {
      "modality": "AMOUNT_ADVANCE_BUSINESS_DAY",
      "discountDateFixed": [
        {
          "date": "2024-12-25",
          "value": "10.00"
        }
      ],
      "value": "5.00"
    },
    "fine": {
      "modality": "PERCENT",
      "value": "2.00"
    },
    "interest": {
      "modality": "PERCENTAGE_PER_MONTH_CALENDAR_DAYS",
      "value": "1.00"
    }
  },
  "createdAt": "2024-01-15T10:30:00Z",
  "debtor": {
    "address": "Rua das Flores, 123",
    "city": "São Paulo",
    "document": "12345678901",
    "email": "joao@example.com",
    "name": "João da Silva",
    "state": "SP",
    "zipCode": "01310-100"
  },
  "deletedAt": "2024-01-25T10:30:00Z",
  "description": "Payment for order #12345",
  "dueDate": "2024-12-31",
  "emv": "00020126580014br.gov.bcb.pix...",
  "id": "550e8400-e29b-41d4-a716-446655440010",
  "locationUrl": "https://api.example.com/qr/550e8400",
  "metadata": {},
  "receiver": {
    "address": "Rua das Flores, 123",
    "city": "São Paulo",
    "document": "12345678901",
    "name": "João da Silva",
    "state": "SP",
    "tradeName": "Company Name",
    "zipCode": "01310-100"
  },
  "receiverKey": "+5511999999999",
  "review": 0,
  "status": "ACTIVE",
  "tags": [
    "ecommerce",
    "subscription"
  ],
  "txId": "TXabcdefghijklmno123456789",
  "updatedAt": "2024-01-20T14:45:00Z",
  "validAfterDue": 5
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

X-Account-Id
string
required

Account ID (UUID format)

Body

application/json
amount
object
required

Amount is the amount configuration object (required)

debtor
object
required

Debtor is the debtor information (required)

dueDate
string
required

DueDate is the due date for the collection in format YYYY-MM-DD (ISO8601)

Example:

"2024-12-31"

receiverKey
string
required

Pix key that will receive the payment

Example:

"+5511999999999"

txId
string
required

TxID is the unique transaction identifier for this collection

Example:

"TXabcdefghijklmno123456789"

validAfterDue
integer
required

ValidAfterDue is the number of days after the due date that the collection remains valid

Required range: x >= 0
Example:

5

additionalInfo
object

AdditionalInfo is a key-value map for additional information

Example:
{ "customerId": "67890", "orderId": "12345" }
description
string

Description is a custom message or description for the collection

Example:

"Payment for order #12345"

locationInformation
object

LocationInformation contains merchant location data for QR code generation

metadata
object

Metadata is an optional map for custom key-value pairs (max 50 keys)

tags
string[]

Tags is an array of custom tags for categorization

Example:
["ecommerce", "subscription"]

Response

Created

additionalInfo
object

AdditionalInfo is a key-value map for additional information (optional)

Example:
{ "customerId": "67890", "orderId": "12345" }
amount
object

Amount is the amount configuration object (required)

createdAt
string

CreatedAt is the timestamp when the collection was created (required)

Example:

"2024-01-15T10:30:00Z"

debtor
object

Debtor is the debtor information (required)

deletedAt
string

DeletedAt is the timestamp when the collection was deleted (optional, nullable)

Example:

"2024-01-25T10:30:00Z"

description
string

Description is the custom description of the collection (optional)

Example:

"Payment for order #12345"

dueDate
string

DueDate is the due date for the collection in format YYYY-MM-DD (required)

Example:

"2024-12-31"

emv
string

EMV is the QR code payload in EMV format (required)

Example:

"00020126580014br.gov.bcb.pix..."

id
string

ID is the unique identifier of the collection (required)

Example:

"550e8400-e29b-41d4-a716-446655440010"

locationUrl
string

LocationURL is the URL to access the collection location/QR code (required)

Example:

"https://api.example.com/qr/550e8400"

metadata
object

Metadata is the custom metadata associated with this collection

receiver
object

Receiver is the receiver information (required)

receiverKey
string

Pix key that will receive the payment

Example:

"+5511999999999"

review
integer

Review is the revision number of the collection (required)

Example:

0

status
string

Status is the current status of the collection (required) Valid values: ACTIVE, COMPLETED, REMOVED_BY_RECEIVER, REMOVED_BY_PSP

Example:

"ACTIVE"

tags
string[]

Tags is an array of custom tags (optional)

Example:
["ecommerce", "subscription"]
txId
string

TxID is the transaction identifier (required)

Example:

"TXabcdefghijklmno123456789"

updatedAt
string

UpdatedAt is the timestamp of the last update (required)

Example:

"2024-01-20T14:45:00Z"

validAfterDue
integer

ValidAfterDue is the number of days after the due date that the collection remains valid (required)

Example:

5