List ledger transaction lines
https://api.light.inc/v1/ledger-transaction-lines
Returns a paginated list of ledger transaction lines
Authorization
Send one of these on every request. See Authentication for how to get credentials.
- API key
Basic authentication header of the form Basic <api_key>, where <api_key> is your api key.
- Bearer token
Query parameters
-
sortstringSort string in the format
field:direction. To provide multiple sort fields, separate them with commas.Available directions:
asc,desc.Available fields:
accountingDocumentNumber,transactionSequenceId,documentSequenceId,documentType,accountCode,accountLabel,postingDate,accountType,taxTagLabel,createdAt. -
filterstringFilter string in the format
field:operator:value. To provide multiple filters, separate them with commas.Available operators:
eq,ne,in,not_in,gt,gte,lt,lte.- For
inandnot_inoperators, provide multiple values separated by the pipe character (|).
Available fields:
accountCode,accountId,accountType,accDocId,businessPartnerId,businessPartnerName,companyEntityCode,companyEntityId,createdAt,customPropertyValueId,documentSequenceId,documentType,eliminationOffset,groupAmount,groupCurrency,id,ledgerName,lineType,localAmount,localCurrency,postingDate,taxTagLabel,transactionCurrency,transactionId,transactionSequenceId.These fields accept only a subset of the operators:
customPropertyValueId(eq,in). - For
-
limitinteger · int32Maximum number of items to return. Default is 50, maximum is 200.
-
offsetinteger · int64deprecatedNumber of items to skip before starting to collect the result set. Deprecated, use 'cursor' instead.
-
cursorstringThe cursor position to start returning results from. To opt-in into cursor-based pagination, provide
0for the initial request. For subsequent requests, usenextCursorandprevCursorfrom the previous response to navigate. Cursor values are opaque and should not be constructed manually. -
includeCustomPropertiesboolean -
includeMaxLineAmountbooleandeprecatedIf true, includes the maximum line amount in the response. This field is deprecated and will be removed, please fetch all lines and compute this locally if needed
Response
-
maxTransactionAmountinteger · int64deprecatedMaximum line amount in transaction currency across all records. This field is deprecated and will be removed, please fetch all lines and compute this locally if needed
-
recordsarray of objectList of records for the current page
-
idstring · uuidNote
Id of this ledger line. Lines are never edited or deleted, so it is stable; corrections arrive as new reversing lines.
-
ledgerTransactionIdstring · uuidNote
The ledger transaction this line belongs to. Lines sharing it were written together and balance to zero in every currency.
-
reversedLedgerTransactionIdstring · uuidOnly reversal lines carry the original ledger transaction ID; original lines have null.
-
reversedLedgerTransactionLineIdstring · uuidOnly reversal lines carry the original ledger transaction line ID; original lines have null.
-
transactionSequenceIdstringNote
The transaction's number,
TX/plus nine digits, assigned per company when the transaction was written. -
companyIdstring · uuidNote
Your company id, the same on every line.
-
companyEntityIdstring · uuidNote
The legal entity whose books this line sits in.
-
companyEntityCodestringNote
The entity's three-digit code, the middle segment of document numbers such as
AP/001/000000042. -
companyEntityNamestringNote
The entity's name.
-
ledgerNamestring⚠️ This enum is not exhaustive; new values may be added in the future.
One of
PRIMARYELIMINATION -
accountIdstring · uuidNote
The ledger account the line posts to.
-
accountCodeinteger · int32Note
The account's numeric code in the chart of accounts.
-
accountLabelstringNote
The account's name.
-
accountTypestring⚠️ This enum is not exhaustive; new values may be added in the future.
One of
BANKCARDCASH_AND_EQUIVALENTSACCOUNTS_RECEIVABLEINVENTORYCORPORATE_TAX_RECEIVABLEOTHER_CURRENT_ASSETINTANGIBLE_NON_CURRENT_ASSETTANGIBLE_NON_CURRENT_ASSETFINANCIAL_NON_CURRENT_ASSETCORPORATE_TAX_DEFERRED_ASSETOTHER_NON_CURRENT_ASSETACCOUNTS_PAYABLEOVERDRAFT_FACILITYCORPORATE_TAX_PAYABLEOTHER_CURRENT_LIABILITYLONG_TERM_LOANCORPORATE_TAX_DEFERRED_LIABILITYOTHER_LONG_TERM_LIABILITYCONTRIBUTED_CAPITALRETAINED_EARNINGSACCUMULATED_OTHER_COMPREHENSIVE_INCOMEOTHER_EQUITYCOST_OF_SALESDISTRIBUTION_COSTGENERAL_AND_ADMINISTRATIVE_EXPENSEPERSONNEL_COSTOTHER_OPERATING_EXPENSEINCOME_TAXDEPRECIATION_AND_AMORTIZATIONNON_OPERATING_EXPENSEINTEREST_EXPENSEEXCHANGE_RATE_LOSS_REALIZEDEXCHANGE_RATE_LOSS_UNREALIZEDOTHER_FINANCIAL_EXPENSEREVENUEDISCOUNTNON_OPERATING_INCOMEINTEREST_INCOMEEXCHANGE_RATE_GAIN_REALIZEDEXCHANGE_RATE_GAIN_UNREALIZEDOTHER_FINANCIAL_INCOME -
accountingDocumentLineIdstring · uuidNote
The document line this ledger line came from.
nullon lines Light derived at posting: tax, rounding and discount lines. -
documentSequenceIdstringNote
The document's number,
<TYPE>/<entity code>/<9 digits>, for exampleAP/001/000000042. -
accountingDocumentIdstring · uuidNote
Id of the posted document. Filter on
accDocIdto get every ledger line of one document. -
accountingDocumentNumberstringNote
The document's external number: the vendor's invoice number on a bill, the invoice number on a sales invoice, the free-text reference on a journal entry.
nullwhen there is none. -
documentTypestring⚠️ This enum is not exhaustive; new values may be added in the future.
One of
APARBPCCCNCTDEFXJEYC -
typestring⚠️ This enum is not exhaustive; new values may be added in the future.
One of
DISCOUNTMAINOFFSETROUNDINGTAXWITHHOLDING -
postingDatestring · dateNote
The ledger date, which decides the accounting period the line falls in.
-
valuationDatestring · dateNote
The date whose exchange rate produced the local and group amounts. Equal to
postingDateunless the document set its own. -
descriptionstringNote
The line's own description, as entered on the document line.
-
documentDescriptionstringNote
The description on the document header.
-
amountsobjectNote
The amount in the document, local and group currencies, unsigned, with one direction in
dcSign. See Reading amounts.-
dcSignstring⚠️ This enum is not exhaustive; new values may be added in the future.
Note
DorC. Redundant with the sign ofsignedLocalAmount(Dis negative there) and withdebit/credit.One of
DC -
transactionAmountinteger · int64Note
Unsigned magnitude. The direction lives in the sign of
signedTransactionAmount, not here. -
transactionAmountInMajorsnumberNote
transactionAmountas a decimal, unsigned. For display, not arithmetic. -
signedTransactionAmountinteger · int64Note
Credit-positive: a credit is positive, a debit is negative, in minor units. This is the opposite polarity to the balances
GET /v1/general-ledger-summaryreturns, which are debit-positive — reconciling one against the other means flipping the sign on one side. There is noInMajorscounterpart to this field; the unsigned*InMajorsvalue beside it carries the magnitude only. -
transactionCurrencystringNote
The document's currency.
nullon lines with no transaction amount: rounding, revaluation and translation-adjustment lines. -
localAmountinteger · int64Note
Unsigned magnitude. The direction lives in the sign of
signedLocalAmount, not here. -
localAmountInMajorsnumberNote
localAmountas a decimal, unsigned. -
signedLocalAmountinteger · int64Note
Credit-positive: a credit is positive, a debit is negative, in minor units. This is the opposite polarity to the balances
GET /v1/general-ledger-summaryreturns, which are debit-positive — reconciling one against the other means flipping the sign on one side. There is noInMajorscounterpart to this field; the unsigned*InMajorsvalue beside it carries the magnitude only. -
localCurrencystringNote
The entity's local currency.
-
groupAmountinteger · int64Note
Unsigned magnitude. The direction lives in the sign of
signedGroupAmount, not here. -
groupAmountInMajorsnumberNote
groupAmountas a decimal, unsigned. -
signedGroupAmountinteger · int64Note
Credit-positive: a credit is positive, a debit is negative, in minor units. This is the opposite polarity to the balances
GET /v1/general-ledger-summaryreturns, which are debit-positive — reconciling one against the other means flipping the sign on one side. There is noInMajorscounterpart to this field; the unsigned*InMajorsvalue beside it carries the magnitude only. -
groupCurrencystringNote
The company's group currency, the same on every line.
-
debitbooleanNote
trueon a debit line. Redundant withdcSignand with a negativesignedLocalAmount. -
creditbooleanNote
trueon a credit line. Redundant withdcSignand with a positivesignedLocalAmount.
-
-
taxIdstring · uuidNote
Id of the tax code on the line;
nullwithout one. -
taxTagLabelstringNote
Label of the tax code's base tag, the VAT-return box the line reports into;
nullwithout a tax code. -
taxCodestringNote
The tax code's code as shown in the product;
nullwithout one. -
businessPartnerNamestringNote
The vendor or customer on the document, when it has one.
-
businessPartnerIdstring · uuidNote
Id of that vendor or customer.
-
costCenterIdstring · uuidNote
Cost center on the line;
nullwhen none. -
accruedLedgerTransactionLineIdstring · uuidNote
On a release line (one instalment of a deferral, accrual or depreciation schedule): the id of the original line it releases. Legacy name;
nullon every other line. -
ledgerTransactionTypestring⚠️ This enum is not exhaustive; new values may be added in the future.
One of
DEFAULTAMORTIZATIONFXCTABANK_CLEARING -
isAmortizedbooleanNote
trueon a line that carries a release schedule, meaning release lines draw it down over time. Legacy name for "is released". -
accountingReleaseStartDatestring · dateNote
First date of the release schedule on this line;
nullwithout one. -
accountingReleaseEndDatestring · dateNote
Last date of the release schedule on this line;
nullwithout one. -
createdAtstring · date-timeNote
When the line was written to the ledger. Not the posting date.
-
createdBystring · uuidNote
The principal that posted the document: a user or an API key.
nullwhen the system posted it. -
customPropertiesarray of objectNote
Custom property values from the document line, returned when
includeCustomPropertiesis true (the default on this endpoint).-
groupIdstring · uuidID of the custom property group
-
groupInternalNamestringInternal name of the custom property group
-
valuesarray of objectList of values. Note that this will be a single value unless the group input type supports multiple values
-
idstring · uuidUnique identifier for the object
-
groupIdstring · uuidID of the custom property group
-
groupInternalNamestringInternal name of the custom property group
-
companyIdstring · uuidID of the company
-
internalNamestringInternal name of the custom property value
-
labelstringLabel of the custom property value
-
contextstringContext/description of the custom property value
-
createdAtstring · date-timeTimestamp when the custom property value was created
-
updatedAtstring · date-timeTimestamp when the custom property value was last updated
-
-
-
-
hasMorebooleanBoolean flag indicating if there are more records available
-
totalinteger · int64deprecatedTotal number of records (only for offset pagination). This field is not guaranteed to be returned and only available for offset pagination, please do not rely on it and migrate to cursor pagination.
-
nextCursorstringCursor for fetching the next page (only for cursor pagination)
-
prevCursorstringCursor for fetching the previous page (only for cursor pagination)