Hanzo
OpenapiBooks

Returns the org's trial balance over an optional [from, to] window of RFC3339…

Returns the org's trial balance over an optional [from, to] window of RFC3339 posting times, including the opening/closing columns and the TotalDebit ==…

GET /v1/books/trial

Addresshttps://api.hanzo.ai/v1/books/trial
MethodGET
Operationget_books_trial
AuthAuthorization: Bearer $HANZO_API_KEY

Returns the org's trial balance over an optional [from, to] window of RFC3339 posting times, including the opening/closing columns and the TotalDebit == TotalCredit proof that the books balance.

Request

3 fields.

FieldInTypeRequiredDescription
sandboxquerystringSandbox reads the org's SANDBOX ledger when it is exactly "true".
fromquerystringFrom is the RFC3339 start of the window, exclusive.
toquerystringTo is the RFC3339 end of the window, inclusive.

Response

StatusBodyMeaning
200TrialBalanceok

200 body — 15 fields.

FieldInTypeAlwaysDescription
balancedbodybooleanBalanced is the proof this report exists to give: whether total debits equal total credits.
frombodystringFrom is the posting time the window opens at, as it was asked for.
rowsbodyTrialBalanceRow[]Rows are the accounts that MOVED in one of the windows.
rows[].accountbodystringAccount is the chart-of-accounts NUMBER this line reports on ("1000", "4000") — the stable posting key, not a display label.
rows[].closingCreditbodyintegerClosingCredit is that closing balance in cents when it is a credit balance.
rows[].closingDebitbodyintegerClosingDebit is the balance at the end of the window, in cents, when it is a debit balance.
rows[].creditbodyintegerCredit is the same window movement in cents when it was net credit.
rows[].debitbodyintegerDebit is the account's MOVEMENT within the window — closing minus opening, not the closing balance — in cents, when that movement was net debit.
rows[].namebodystringName is that account's human name from the fixed chart.
rows[].openingCreditbodyintegerOpeningCredit is the same opening balance in cents when it fell on the credit side.
rows[].openingDebitbodyintegerOpeningDebit is the account's balance before the window began, in whole cents, when that balance was on the debit side.
rows[].typebodystringType is the account's fundamental class — asset, liability, income, expense or equity — which is also its normal balance side.
tobodystringTo is the posting time the window closes at, inclusive.
totalCreditbodyintegerTotalCredit is the sum of every row's closing credit column, in cents.
totalDebitbodyintegerTotalDebit is the sum of every row's CLOSING debit column, in cents.

Failure carries the platform error shape — see Errors.

Examples

hanzo books trial

Books API · All Hanzo APIs · Interactive reference

How is this guide?

On this page