GET
View general ledger (organization)
Organization space Accounting module For: Accountant, Administrator · Permission: journal_entries.viewreports Conditions
  • The accounting module must be part of the organization’s plan.
  • In the organization space, the caller needs an accounting access grant on the book.
  • The account parameter is required and must be an account of this book.
  • per_page is an integer from 1 to 100; to must be on or after from.
  • The book needs a fiscal year covering to (any fiscal year when to is not sent) to supply the currency, otherwise the call answers 404.
Part of Accounting reports.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

book
string
required

Identifier of the book the report covers (27-character KSUID string): the organization itself or one of its companies of the session organization.

Query Parameters

fiscal_year_id
string | null

Fiscal year whose start and end dates define the window; when sent, from and to are ignored.

fiscal_period_id
string | null

Accepted but not used by this report; use fiscal_year_id or from/to.

from
string<date-time> | null

Start of the window, ISO 8601 date. Without it the ledger starts at the first line and the opening balance is 0. Ignored when fiscal_year_id is sent.

to
string<date-time> | null

End of the window, ISO 8601 date, on or after from. Without it the ledger runs to the last line. The book needs a fiscal year containing this date (or, without it, any fiscal year) to supply the currency, otherwise the call answers 404.

account
string
required

Required. Identifier of the account to list (27-character KSUID string).

per_page
integer | null

Number of items per page.

Required range: 1 <= x <= 100
cursor
string | null

Position in the list. Pass the meta.next_cursor or meta.prev_cursor value of the previous page; leave it out to get the first page.

Response

book
object
required

The book the report covers. In the client space it is the session client's book; in the organization space it is the book named in the URL.

account
object
required

The account whose movements are listed.

from
string<date> | null
required

Start date of the window used, ISO 8601 date format; null when the request set none.

to
string<date> | null
required

End date of the window used, ISO 8601 date format; null when the request set none.

opening_balance
required

Signed balance of the account (debits minus credits) over every line before from, in minor units of currency_code (divide by 10 to the power currency_exponent). 0 when there is no from.

closing_balance
integer
required

Opening balance plus the signed movements of the window, in minor units of currency_code (divide by 10 to the power currency_exponent).

lines
object
required

One page of movements, ordered by accounting date. An object with data and meta.

currency_code
string
required

ISO 4217 code of the currency of every amount in the report.

currency_exponent
integer
required

Number of decimal places of the currency (0 for XOF). An amount in minor units divided by 10 to this power gives the amount in the currency.