Definition
A journal entry (also known as a GL entry in Anglo-Saxon (UK/US-style) accounting systems) is the lowest-level accounting record of a business transaction. It always contains at least two lines and must balance: the total debits equal the total credits. This principle is universal across all accounting models and forms the foundation of (double-entry) bookkeeping.Purpose
- Serves as the base unit of accounting: every transaction ultimately results in one or more journal entries.
- Provides full flexibility: any transaction can be recorded here, from simple payments to complex adjustments.
- Specialized objects such as invoices and financial entries simplify common use cases by exposing only the relevant fields.
Structure
Each journal entry has:- An identifier (
id) and an entry number assigned by the accounting software (name). When you create an entry, you send your own uniquenumber. Use it for idempotency - A journal (
journal_id,journal_name) - An accounting date (
date) - A posted flag (
posted):trueif the entry is finalized. On creation, the default istrue - A reference (
reference) - Due dates (
due_date,due_dates), when the entry relates to an invoice - A currency (
currency) and an exchange rate (currency_exchange_rate) - On creation only: the period covered (
start_date,end_date) for accruals and deferrals, and a PDF (pdf,pdf_name) - An attachment status (
attachments_info):yes,yes_to_request,noorunknown - Lines (
items), at least two. Each line has:- An account. On creation, set the account type (
account_type) and the account (account). See Accounts in journal entries:general_account:accountis a ledger account numbercustomer_account,supplier_account,employee_account:accountis a partner ID
- A debit (
debit) or a credit (credit). The other one is0 - A description (
description) - On read: the account (
account_number,account_name), the partner (partner_id,partner_name) and the matching numbers (matching_numbers) - On creation: optional VAT (
tax_info, general accounts only). See VAT on journal entry lines - Optional analytic accounts (
analytic_accounton read,analytic_distributionon creation)
- An account. On creation, set the account type (
Relationships
- Each journal entry is recorded in a journal (
journal_id). Usejournal_idto filter journal entries. - The
datesets the accounting period and the book year. When you list journal entries,date_fromanddate_toare mandatory if you do not provideupdated_after. - Each line references a ledger account or a partner. Use
partner_idto list the journal entries of one partner. - Invoices and financial entries generate journal entries in the accounting software.
- Open entries of the same partner can be matched together: journal entries, invoices or financial entries. Matched lines share their
matching_numbers. Open items are listed in outstanding items. - Lines can carry analytic accounts:
analytic_accountfor the default plan,analytic_distributionfor multiple plans. - When
attachments_infoisyes_to_request, get the documents from the attachments endpoint withtype=entry.
API endpoints
- Get journal entries: list journal entries, with the analytic accounts of the default analytic plan.
- Get journal entries (multiple analytic plans): list journal entries, with the analytic accounts of all analytic plans.
- Get one journal entry: get one journal entry by its ID.
- Create journal entry: create a journal entry.
- Match entries: match at least 2 open entries of the same partner.