The Entry Message
An Entry message represents an entry into one of the Ledger's journals. An entry represents the transfer of an amount between two or more accounts in the ledger.
Ledger's Reference mechanism allows the application to connect the Entry to an external entity, for example an invoice, payment, etc.
Business Rules
- Entries must have amounts that balance debits and credits.
- Non-clearing entries may have only one source account, which can be either a debit or credit account.
- Clearing entries may have multiple debits and credits.
- There can be one or more target accounts. If the source amount is a debit, the target accounts must be credits; if the source is a credit, all the targets must be debits.
- The entry must have a text description.
- If
language
is not specified, the description is assumed to be in the Ledger's language. - If no SubJournal is specified, the entry is written to the General Journal.
- If no Domain is specified, the default domain is assumed.
- If no Currency is provided, the currency of the default domain is assumed.
- The default state of the
reviewed
flag is set on ledger creation.
Entry Message Properties
Property | Type | Description |
---|---|---|
arguments |
string[] | Arguments to be passed to a string translation function. |
clearing |
bool | This is a clearing transaction. |
currency |
string | The currency of the amounts used in this entry. |
description |
string | Transaction description. |
details |
Detail [] |
Transaction detail records. |
domain |
string | The domain this entry applies to. |
extra |
string | An arbitrary string for use by the application. |
id |
int | A unique identifier for this entry. |
journal |
string | The journal this entry applies to. |
language |
string | The language used for the supplied description. |
lock |
bool | Set when the transaction should be locked. |
reference |
Reference |
A link to an external entity. |
reviewed |
bool | Set when this transaction has been manually reviewed. |
revision |
string | The revision hash code for the account. |
transDate |
Carbon | The effective date of the Entry. |
Requirements for each Command
Property | Add | Delete | Get | Lock | Update |
---|---|---|---|---|---|
arguments |
O | _ | _ | _ | O |
clearing |
D | _ | _ | _ | O |
currency |
D | _ | _ | _ | O |
details |
M | _ | _ | _ | M |
domain |
D | _ | _ | _ | O |
extra |
O | _ | _ | _ | O |
id |
X | M | M | M | M |
journal |
D | _ | _ | _ | O |
language |
D | _ | _ | _ | O |
lock |
_ | _ | _ | M | _ |
opening |
X | _ | _ | _ | X |
reference |
O | _ | _ | _ | O |
reviewed |
O | _ | _ | _ | O |
revision |
X | _ | _ | M | M |
transDate |
M | _ | _ | _ | M |
- D - If omitted, a default value is assumed
- O - Optional
- M - Must be supplied
- X - Invalid
- _ - Ignored