Delete accounts

Bulk delete chart of accounts entries. Accounts with posted activity, a bank feed connection, or equity accounts cannot be deleted and are skipped; deactivate them instead. The query filters are the same as for searching accounts and select the candidate set; the body picks the accounts within it. Provide ids, or explicitly set include to false to delete every account matching the filters (and every account outright when no filters are given); an empty body is rejected.

Required permission: Accounting Settings

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Query Params
string

Return accounts whose number or name contains the given text.

string

Return accounts whose description contains the given text.

string

Return accounts created by users whose name contains the given text.

string

Comma-delimited list of fund ids. Returns accounts whose default fund is one of them. Use -1 to include accounts without a default fund.

string

Comma-delimited list of account type ids or codes (coa_type_asset, coa_type_liability, coa_type_equity, coa_type_income, coa_type_expense).

string

Comma-delimited list of account category ids or codes. Category ids and codes appear on each account in the response.

boolean

If true, returns only register (bank/checking) accounts; if false, only non-register accounts.

boolean

If true, returns only accounts-payable accounts; if false, only non-payable accounts.

boolean

If true, returns only accounts-receivable accounts; if false, only non-receivable accounts.

boolean

If true, returns only bad-debt expense accounts; if false, only non-bad-debt accounts.

boolean

If true, returns only payable-adjustment accounts; if false, only non-adjustment accounts.

boolean

If true, returns only active accounts; if false, only deactivated accounts.

double

Return accounts with at least this many posted line items.

double

Return accounts with at most this many posted line items.

date-time

Return accounts whose earliest activity is on or after this date.

date-time

Return accounts whose earliest activity is on or before this date.

date-time

Return accounts whose latest activity is on or after this date.

date-time

Return accounts whose latest activity is on or before this date.

double

Return accounts with a balance of at least this amount.

double

Return accounts with a balance of at most this amount.

double

Return accounts with a starting balance of at least this amount.

double

Return accounts with a starting balance of at most this amount.

Body Params

The accounts to delete

ids
array of doubles | null

The ids the operation applies to: an include list by default, or an exclude list when include is false. For deletes, required unless include is false.

ids
boolean | null

Whether ids is an include list (true, default) or an exclude list (false). Setting include to false with no ids applies the operation to every record matching the query filters.

Responses
200

OK

401

Authentication is required, or the Ocs-Api-Key header is missing or invalid.

Language
Credentials
Header
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here!