Create journal entry

POST/api/v1/journal-entries

Create a new double-entry journal entry with balanced line entries.

Operation ID: create_journal_entry_api_v1_journal_entries_post·View as markdown·OpenAPI slice

Authentication

Bearer token authentication. Pass your DayZero API token in the Authorization header and the target business UUID in x-business-id.

Request body

descriptionstring

Human-readable description of the journal entry. Should describe the transaction being recorded.

currencystring

Currency for the journal entry (USD, CAD, AUD, EUR, or GBP). Defaults to business default.

datestring · date

The date when this transaction occurred. Use ISO 8601 date format (YYYY-MM-DD).

line_entriesarray · object

Array of line entries (minimum 2). Total debits must equal total credits. Each entry requires: amount (integer in cents), debit_credit ('debit' or 'credit'), ledger_id (UUID of target ledger account), description (what this line represents).

invoice_idstring

Optional UUID of an invoice to link this journal entry to. Useful for tracking revenue recognition.

inventory_order_idstring

Optional UUID of an inventory order (PO) to link this journal entry to. Useful for the PO audit trail.

Responses

201Successful Response

successboolean
messagestring
codestring
dataJournalEntryResponse

400Bad Request - Invalid input

401Unauthorized - Authentication required

403Forbidden - Insufficient permissions

422Validation Error

detailarray · ValidationErrorValidationError
5 fields
locarray · string | integerrequired
msgstringrequired
typestringrequired
inputobject
ctxobject