How to create receivables
This page covers the receivable creation flows: individual and bulk.
Individual flow
POST /v1/receivables
Authorization: Bearer eyJ...
Idempotency-Key: erp-fac-2026-05-15-00012345
Content-Type: application/json
{
"receivableAccountId": 4242,
"amount": 45000.00,
"currencyCode": "ARS",
"receivableType": "INVOICE",
"legalNumber": "0001-00012345",
"issueDate": "2026-05-15",
"dueDate": "2026-05-30",
"description": "Order 5678 - 12 boxes"
}
Request fields
| Field | Type | Required | Description |
|---|---|---|---|
receivableAccountId | int64 | Yes | Account this receivable is issued against |
amount | positive decimal | Yes | Amount, always positive. The accounting sign comes from receivableType |
currencyCode | string | Yes | Must match the account's currency |
receivableType | enum | Yes | See types |
clientId | int64 | No | Default: the account's client. Only pass if it differs |
associateId | int64 | No | Operator registering the receivable. If the account has no operator, this value post-hoc binds it |
parentReceivableId | int64 | Only for negative-sign types | Original receivable this one modifies/cancels |
legalNumber | string | No | AFIP document number |
description | string | No | Free text |
externalRoutingCode | string | No | Route sheet code |
issueDate | YYYY-MM-DD | No | Document issue date |
dueDate | YYYY-MM-DD | No | Due date |
receivableDate | YYYY-MM-DD | No | Default: today |
attachmentUri | URL | No | Document attachment |
invoiceData.* | object | No | AFIP data (version, point of sale, CAE, etc.) |
Response
201 Created
Location: /v1/receivables/99001
Content-Type: application/json
{
"id": 99001,
"receivableAccountId": 4242,
"clientId": 1042,
"associateId": null,
"amount": 45000.00,
"currencyCode": "ARS",
"receivableType": "INVOICE",
"status": "PENDING",
"legalNumber": "0001-00012345",
"description": "Order 5678 - 12 boxes",
"issueDate": "2026-05-15",
"dueDate": "2026-05-30",
"receivableDate": "2026-05-15",
"creationDate": "2026-05-15T10:00:00-03:00",
"modificationDate": "2026-05-15T10:00:00-03:00"
}
Sequence diagram
Post-hoc operator binding
If the account is in Pattern A (only clientId) and this is the first receivable a driver registers on that account, you can pass associateId on the receivable and the account is automatically linked to the associate (transitioning to Pattern C). Useful for flows where the driver-client assignment emerges organically.
POST /v1/receivables
Idempotency-Key: ...
{
"receivableAccountId": 4242,
"amount": 45000.00,
"currencyCode": "ARS",
"receivableType": "INVOICE",
"associateId": 88
}
See more in post-hoc binding.
Related cases
- Create many receivables at once (end of day, initial import): see Bulk receivable creation.
- Credit notes, returns, adjustments, retentions: see Recording credit notes and adjustments.
- Match an incoming collection to a receivable: see Match incoming collections to receivables.
Common errors
| Scenario | HTTP | code |
|---|---|---|
amount <= 0 | 400 | validation |
currencyCode does not match the account | 422 | unmatching-receivable-currency-code |
receivableAccountId points to an account of another customer | 403 | resource-not-accessible |
| Account not enabled for receivables (it is a MAIN/SUB) | 422 | current-account-not-receivable-enabled |
parentReceivableId required for negative types but not sent | 422 | missing-parent-receivable |
clientId differs from the account's client | 422 | unmatching-receivable-client-id |
| Same Idempotency-Key with a different body | 409 | idempotency-key-reuse |
Subsequent modifications
A receivable in PENDING state can be modified with PUT /v1/receivables/{id} (limited to certain fields: description, dueDate, attachmentUri, externalRoutingCode).
To change the status, use PATCH /v1/receivables/{id}/status — see Lifecycle.
If the receivable is already in a terminal state (PAID, SETTLED, EXPIRED, DISABLED), PUT returns 422 updating-receivable-final-status.