Update ledger

PUT/api/v1/ledgers/{ledger_id}

Update an existing ledger account.

Operation ID: update_ledger_api_v1_ledgers__ledger_id__put·View as markdown·OpenAPI slice

Authentication

Bearer token authentication. Pass your DayZero API token in the Authorization header and the target business UUID in x-business-id.

Parameters

Path

ledger_idstringrequired

Request body

namestring

Ledger name

descriptionstring

Ledger description

account_numberstring

Optional account number/code for chart-of-accounts numbering.

statusstring

Ledger status (active, inactive)

debit_creditstring

Debit/credit behavior (debit, credit)

sort_codeinteger

Sort code for chart ordering (e.g. 1000 for assets, 4000 for revenue).

sub_typestring

Ledger sub-type

report_cash_flowboolean

Include in cash flow reports

cash_flow_sectionCashFlowSectionEnum

Cash flow statement section: 'operating' (working capital changes), 'investing' (fixed assets, investments), 'financing' (loans, equity), or 'excluded' (not shown in cash flow statement).

cfs_classCashFlowClassEnum

Indirect-method cash flow classification (e.g. 'ar', 'ppe', 'lt_debt'). See CashFlowClassEnum for full list.

editableboolean

Whether journal entries can be manually posted to this account.

parent_idstring

Parent ledger ID for creating child/sub-ledgers

financial_account_typestring

Financial account type: bank_account, credit_card, payments, payroll, loan, prepaid_card, accounts_receivable, accounts_payable. Set to designate this ledger as a financial account.

Responses

200Successful Response

successboolean
messagestring
codestring
dataLedgerResponse

400Bad Request - Invalid input

401Unauthorized - Authentication required

403Forbidden - Insufficient permissions

404Not Found - Resource does not exist

422Validation Error

detailarray · ValidationErrorValidationError
5 fields
locarray · string | integerrequired
msgstringrequired
typestringrequired
inputobject
ctxobject