# QuickBooks Desktop — Accounting API: gotchas

> Canonical URL: https://developers.apideck.com/apis/accounting/quickbooks-desktop/gotchas

## GET /accounting/tax-rates

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## GET /accounting/bills

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/bills

Bill expense lines map from `line_items[]` (`ledger_account` → expense account, `total_amount`, `description`). Lines cannot be changed after creation; see the update operation.

## PATCH /accounting/bills/{id}

QuickBooks Desktop cannot modify bill line items: `line_items` sent on update are ignored and the response still returns the bill `id`. Only header fields change — `supplier`, `bill_date`, `due_date`, `bill_number`, `terms`, `notes`. `currency`, `currency_rate` and `tracking_categories` are also ignored on update. Delete and recreate the bill to change its lines.

Updates need `row_version` from a prior read of the record: without it the update is rejected with `Missing required field: data.editSequence`. Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it; read the record back before retrying.

## GET /accounting/invoices

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/invoices

On create, QuickBooks Desktop only honors `customer`, `invoice_date`, `number`, `reference` (memo), and `line_items`. Header fields such as `due_date`, `terms`, `po_number`, `customer_memo`, billing/shipping address, currency, and tracking category are ignored at create time — set them with a follow-up update. Each line item must include an `item` (QBD rejects invoices whose lines have no item). On update, line items cannot be modified — only header fields (customer, dates, ref number, memo) change; resend line edits by voiding and recreating.

`number` is limited to 11 characters; a longer value is rejected ("RefNumber is too long", error 3070). Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the invoice; list invoices by `number` before retrying.

## PATCH /accounting/invoices/{id}

Updates need `row_version` from a prior read of the record: without it the update is rejected with `Missing required field: data.editSequence`.

Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it. Read the record back before retrying.

## GET /accounting/ledger-accounts

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## PATCH /accounting/ledger-accounts/{id}

Updates need `row_version` from a prior read of the record: without it the update is rejected with `Missing required field: data.editSequence`.

Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it. Read the record back before retrying.

## GET /accounting/invoice-items

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/invoice-items

A service item needs its posting account by name: send `income_account.name` (the QuickBooks account name). An account `id` alone is not resolved, and QuickBooks rejects the item without a posting account ("A posting account must be specified", error 3180).

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the item. List items to find it before retrying.

## PATCH /accounting/invoice-items/{id}

Updates need `row_version` from a prior read of the record: without it the update is rejected with `Missing required field: data.editSequence`.

Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it. Read the record back before retrying.

## GET /accounting/credit-notes

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/credit-notes

Credit-note lines cannot be changed after creation; see the update operation.

## PATCH /accounting/credit-notes/{id}

QuickBooks Desktop cannot modify credit-note line items, the AR account or the tracking category: `line_items` sent on update are ignored and the response still returns the credit note `id`. Only `customer`, `date_issued`, `number` and `note` change. Delete and recreate the credit note to change its lines.

Updates need `row_version` from a prior read of the record: without it the update is rejected with `Missing required field: data.editSequence`. Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it; read the record back before retrying.

## GET /accounting/bill-credit-notes

Bill credit notes are QuickBooks vendor credits. How much of a vendor credit is still unused is not available, so `balance` and `remaining_credit` are not returned and `status` is always `posted`. Supported filters: `number`, `updated_since` and `created_since`; `supplier_id` is not supported. `currency` and the tax fields are not returned.

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/bill-credit-notes

Creates a vendor credit; `supplier` is required. A `line_items[]` entry with an `item` becomes an item line (`quantity` and `unit_price`, or `total_amount` when no unit price is given); an entry without one becomes an expense line (`ledger_account`, `total_amount`, `description` and the first of its `tracking_categories`). An item line's `description`, `customer` and first `tracking_categories` entry are written too, by qbd-connect builds that include apideck-io/qbd-connect#110; an older build takes the item, quantity and price only and QuickBooks fills the description from the item. `currency`, `line_items[].tax_rate` and the credit note's own `tracking_categories` are not written either.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the credit note. List bill credit notes to find it before retrying: sending the create again adds a second credit note.

## PATCH /accounting/bill-credit-notes/{id}

QuickBooks Desktop cannot modify vendor credit lines: `line_items` sent on update are ignored and the response still returns the `id`. Only `supplier`, `number`, `date_issued` and `note` change. Delete and recreate the credit note to change its lines.

Updates need `row_version` from a prior read of the record. Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it, and the change can take a few minutes to show when the record is read back.

## DELETE /accounting/bill-credit-notes/{id}

A delete can return a `504` timeout after 28 seconds while QuickBooks still deletes the credit note. Read it back before retrying: a `404` means it is gone.

## GET /accounting/customers

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/customers

`currency` is written only when multi-currency is turned on in the company file. On a single-currency file QuickBooks rejects a create that carries `currency` (error 3250, "This feature is not enabled"), so leave `currency` out unless the file uses multi-currency.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the customer. List customers to find it before retrying.

## PATCH /accounting/customers/{id}

Updates need `row_version` from a prior read of the record: without it the update is rejected with `Missing required field: data.editSequence`.

Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it. Read the record back before retrying.

## GET /accounting/suppliers

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/suppliers

On create, QuickBooks Desktop stores `display_name` (or `company_name` when it is missing), `company_name`, `first_name`, `last_name`, the `billing` address (the first address when none is typed `billing`), the `primary` and `fax` phone numbers and the `primary` email. An `other` or `secondary` phone number is not stored on create.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the supplier; a re-sent create is rejected because the name is already in use (error 3100). Read suppliers by `filter[display_name]` before retrying.

## PATCH /accounting/suppliers/{id}

Updates need `row_version` from a prior read of the record: without it the update is rejected with `Missing required field: data.editSequence`.

Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it. Read the record back before retrying.

## GET /accounting/payments

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/payments

QuickBooks Desktop applies a payment to invoices via `allocations[]` — each `allocations[].id` is the target invoice's transaction id and `allocations[].amount` the amount applied. Without `allocations`, the payment is created unapplied. On update, QBD cannot change the applied invoices, payment method, or deposit/AR account — only customer, `transaction_date`, `reference`, `total_amount`, and `note` are updatable; recreate the payment to change allocations.

## PATCH /accounting/payments/{id}

Updates need `row_version` from a prior read of the record: without it the update is rejected with `Missing required field: data.editSequence`.

Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it. Read the record back before retrying.

## GET /accounting/company-info

QuickBooks Desktop has no company identifier or status: `id` is not returned and `status` is always `active`. `currency`, `sales_tax_number` and the sales tax settings are not returned.

## GET /accounting/balance-sheet

The report is generated live by QuickBooks Desktop on every request: the call waits up
to 25 seconds for the next Web Connector run (it polls about once a minute). If the run
does not happen in time the call returns 408 and the report job stays queued, so repeat
the same request a little later and it returns the finished report. Only
`filter[end_date]` (the "as of" date; defaults to today) and `filter[accounting_method]`
(Accrual or Cash) shape the report; `filter[start_date]` is accepted and ignored (a
balance sheet is a point-in-time position), while `period_count`, `period_type` and
`location_id` are rejected as unsupported. Assets, liabilities and equity follow
QuickBooks' own captions (ASSETS, LIABILITIES & EQUITY → Liabilities, Equity); when a
caption is missing (renamed or non-English company file) the group is rebuilt flat from
the lines whose account has a matching QuickBooks account type, and equity is then
assets minus liabilities. Items keep QuickBooks' own grouping (Current Assets →
Checking/Savings → accounts); `title` is the caption as printed (`10100 · Checking`),
`name` the account name, `account_id` the ledger account id and `code` the account
number, joined from the synced chart of accounts (absent until the first accounts sync; a
file that prints none of the `ASSETS`, `Liabilities` and `Equity` captions returns `502`
until then, since its groups can only be rebuilt from the synced account types).
`currency` is not reported.

## GET /accounting/profit-and-loss

The report is generated live by QuickBooks Desktop on every request: the call waits up
to 25 seconds for the next Web Connector run (it polls about once a minute, occasionally
skipping a cycle). If the run does not happen in time the call returns 408 and the report
job stays queued, so repeat the same request a little later and it returns the finished
report. `filter[start_date]` and `filter[end_date]` map to the report period (omit both
for the calendar year to date; a start date alone runs to today, an end date alone runs from 1970-01-01, i.e. all history),
`filter[accounting_method]` selects the Accrual or Cash basis and
`filter[customer_id]` restricts the report to one customer or job; `filter[location_id]`
is not supported. Sections follow QuickBooks' own captions (Income, Cost of Goods Sold,
Expense, Other Income, Other Expense); when a caption is missing (renamed or non-English
company file) the section is rebuilt flat from the lines whose account has the matching
QuickBooks account type. Record titles are the account captions as QuickBooks prints
them (`40110 · Design Income`) and a parent account with sub-accounts becomes a nested
section. Each record's `id` is the ledger account id and `code` its account number,
joined from the synced chart of accounts; until the first accounts sync has run they
are absent, and a file that prints neither an `Income` nor an `Expense` caption (renamed
or localised) returns `502` until then, since its sections can only be rebuilt from the
synced account types. `currency` is not reported. When QuickBooks chooses the period (a date
macro, or a single bound), `start_date` / `end_date` are read from the report subtitle.

## GET /accounting/journal-entries

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/journal-entries

Each line needs its account by name: send `line_items[].ledger_account.name` (the QuickBooks account name); an account `id` alone is not resolved and the entry is rejected. Only the date part of `posted_at` is stored. `memo` is not stored: QuickBooks keeps a memo per line (`line_items[].description`), not on the entry.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the entry. List journal entries before retrying.

## PATCH /accounting/journal-entries/{id}

Updates need `row_version` from a prior read of the record: without it the update is rejected with `Missing required field: data.editSequence`.

Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it. Read the record back before retrying.

## GET /accounting/sales-receipts

Only `filter[updated_since]` is supported; `customer_id` is not. `currency` and `customer_memo` are not returned.

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/sales-receipts

A `line_items[]` entry sends `unit_price`, or `total_amount` when no unit price is given. `line_items[].tax_rate`, `currency` and the discount fields are not written. `customer_memo` is not written either: QuickBooks holds it as a reference to its Customer Message list and refuses the document for any other text.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the sales receipt. List sales receipts to find it before retrying: sending the create again adds a second sales receipt.

## PATCH /accounting/sales-receipts/{id}

Only `customer`, `number`, `transaction_date` and `note` change. `line_items` sent on update are ignored; delete and recreate the sales receipt to change its lines.

Updates need `row_version` from a prior read of the record. Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it, and the change can take a few minutes to show when the record is read back.

## DELETE /accounting/sales-receipts/{id}

A delete can return a `504` timeout after 28 seconds while QuickBooks still deletes the sales receipt. Read it back before retrying: a `404` means it is gone.

## GET /accounting/purchase-orders

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/purchase-orders

Purchase-order lines cannot be changed after creation; see the update operation. Per-line `customer` is not supported on QuickBooks Desktop purchase-order lines.

`po_number` is limited to 11 characters; a longer value is rejected ("RefNumber is too long", error 3070). Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the purchase order; list purchase orders by `po_number` before retrying.

## PATCH /accounting/purchase-orders/{id}

QuickBooks Desktop cannot modify purchase-order line items: `line_items` sent on update are ignored and the response still returns the purchase order `id`. Only header fields change — `supplier`, `issued_date`, `po_number`, `memo`, `expected_arrival_date`, tracking category. Delete and recreate the purchase order to change its lines.

Updates need `row_version` from a prior read of the record: without it the update is rejected with `Missing required field: data.editSequence`. Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it; read the record back before retrying.

## GET /accounting/goods-receipts

Goods receipts are QuickBooks item receipts, and `status` is always `received`. `purchase_order_id` and `po_number` are set when the receipt is linked to exactly one purchase order; `line_items[].purchase_order` is not returned. `line_items` holds the receipt's item lines only. Only `filter[updated_since]` is supported.

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## GET /accounting/goods-receipts/{id}

Goods receipts are QuickBooks item receipts, and `status` is always `received`. `purchase_order_id` and `po_number` are set when the receipt is linked to exactly one purchase order; `line_items[].purchase_order` is not returned. `line_items` holds the receipt's item lines only.

## GET /accounting/bank-accounts

Bank accounts are the QuickBooks accounts of type Bank and Credit Card. `account_type` is `credit_card` for a credit card account and is not returned for a bank account, because QuickBooks has a single type for checking, savings and cash accounts. `ledger_account` is the account itself, with its chart-of-accounts number in `nominal_code`; the bank's own account number is not returned. Supported filters: `name` and `status` (`active` or `inactive`); `account_type` is not supported.

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/bank-accounts

A bank account is created as a QuickBooks account: of type Credit Card when `account_type` is `credit_card`, of type Bank for every other `account_type` or none. Written: `name`, `description` and `ledger_account.nominal_code` (the number in the chart of accounts). The bank's own `account_number`, `bank_name`, `currency`, `balance` and the other bank details are not written. Creating an account whose name already exists returns that account instead of a second one.

A write runs when the QuickBooks Web Connector next polls, about once a minute. A request that waits longer than the platform allows answers `408` or `504` and is still applied: read the list before sending it again.

## GET /accounting/bank-accounts/{id}

Bank accounts are the QuickBooks accounts of type Bank and Credit Card. `account_type` is `credit_card` for a credit card account and is not returned for a bank account. `ledger_account` is the account itself, with its chart-of-accounts number in `nominal_code`; the bank's own account number is not returned.

## PATCH /accounting/bank-accounts/{id}

Updates the QuickBooks account: `name`, `description`, `status` (`active` or `inactive`) and `ledger_account.nominal_code`. The unified bank account has no `row_version`, so the update is applied to the account as it is now: the last write wins. The id of an account that is not a bank or credit card account answers `404`. `account_type` cannot be changed, and the bank details (`account_number`, `bank_name`, `currency`, `balance`) are not written.

A write runs when the QuickBooks Web Connector next polls, about once a minute. A request that waits longer than the platform allows answers `408` or `504` and is still applied.

## DELETE /accounting/bank-accounts/{id}

Deletes the QuickBooks account from the chart of accounts. To hide an account without deleting it, update its `status` to `inactive`. Only a bank or credit card account can be deleted here: the id of any other account answers `404`.

A delete runs when the QuickBooks Web Connector next polls, about once a minute. A request that waits longer than the platform allows answers `408` or `504` and is still applied.

## GET /accounting/trial-balance

Built from QuickBooks Desktop's `TrialBalance` report, generated live on every request: the call waits up to 25 seconds for the next Web Connector run (about once a minute, occasionally two) and returns a `408` if it does not happen in time; the report job stays queued, so repeating the same request shortly after returns the finished report. `filter[end_date]` is the "as of" date (today in UTC when left out); balance sheet accounts are cumulative to it and income and expense accounts are fiscal year to date (QuickBooks ignores a period start for this report), with `start_date` the first day of that fiscal year from the company file's first fiscal month (null until qbd-connect has synced the company info). `filter[accounting_method]` selects the Accrual or Cash basis. Each account's debit or credit is as QuickBooks prints it, netted into one side; accounts with a zero balance are left out, so a company with no data returns an empty list. `account_id` is the account's ListID, the id `GET /accounting/ledger-accounts/{id}` takes, `code` its account number and `name` its own (short) name; a row whose printed caption matches no synced account has `line_type` `unmapped` and no `account_id` (poll again after the accounts sync). `currency` is null (QuickBooks Desktop reports in the home currency). A report whose debits and credits differ by half a cent or more returns a `502`.
## GET /accounting/tracking-categories

Tracking categories are QuickBooks classes. `name` is the class's own name; a sub-class carries its parent in `parent_id` and `parent_name`.

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/tracking-categories

To create a sub-class send `parent_name` with the parent class's full name (for example `Remodel`, or `Remodel:Kitchen` for a class two levels down). `parent_id` on its own is not used.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the class. List tracking categories to find it before retrying: sending the create again adds a second class.

## PATCH /accounting/tracking-categories/{id}

`name` and `status` can be changed, and the parent through `parent_name`.

Updates need `row_version` from a prior read of the record. Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it, and the change can take a few minutes to show when the record is read back.

## DELETE /accounting/tracking-categories/{id}

A delete can return a `504` timeout after 28 seconds while QuickBooks still deletes the class. Read it back before retrying: a `404` means it is gone.

## GET /accounting/bill-payments

Bill payments are the QuickBooks bill payments made by check and by credit card, checks first. While a connection is synced for the first time the list can already hold the payments by check and not yet those by credit card. `payment_method` is `check` or `credit_card`. `account` is the bank or credit card account the payment was made from and `allocations[]` lists the bills it was applied to. `status` is `voided` for a voided payment, by check or by credit card (QuickBooks sets its amount to zero and starts its memo with `VOID:`), and `paid` otherwise. Only `filter[updated_since]` is supported. `currency` is not returned.

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/bill-payments

Creates a bill payment by check from a bank account, or by credit card when `account` is a credit card account. An account QuickBooks knows to be of another type answers `400`. `supplier`, `account` (the bank or credit card account to pay from) and at least one `allocations[]` entry carrying the bill `id` and `amount` are required. QuickBooks sets the payment total to the sum of those amounts, so `total_amount` is not used. Only allocations of type `bill` are sent. `currency` and `payment_method` are not written.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the bill payment. List bill payments to find it before retrying: sending the create again adds a second bill payment.

## PATCH /accounting/bill-payments/{id}

Only a payment made by check can be updated: QuickBooks cannot modify a bill payment made by credit card, and the update answers `405`. Only `transaction_date`, `reference` and `note` change. `allocations`, `supplier`, `account` and the amounts sent on update are ignored; delete and recreate the payment to change them.

Updates need `row_version` from a prior read of the record. Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it, and the change can take a few minutes to show when the record is read back.

## DELETE /accounting/bill-payments/{id}

A delete can return a `504` timeout after 28 seconds while QuickBooks still deletes the bill payment. Read it back before retrying: a `404` means it is gone.

## GET /accounting/expenses

Expenses are QuickBooks checks, credit card charges and credit card credits, listed in that order. While a connection is synced for the first time the list can already hold the checks and not yet the credit card records. `payment_type` is `check` for a check and `credit_card` for the other two; `type` is `refund` for a credit card credit and `expense` otherwise. `account` is the bank or credit card account of the record: the one a check or a credit card charge was paid from, and the card a credit card credit was refunded to. QuickBooks does not say whether the payee is a supplier, a customer or an employee, so `supplier` is not returned. `status` is `voided` for a voided check, credit card charge or credit card credit (QuickBooks sets its amount to zero and starts its memo with `VOID:`) and `posted` otherwise. `currency` is not returned. Only `filter[updated_since]` is supported.

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/expenses

Creates a check, a credit card charge or a credit card credit. The `account`, sent as an object with `id` or `name` (`account_id` is not read), decides which: a credit card account makes a credit card charge, a bank account a check. An account QuickBooks knows to be of another type answers `400`; one that is not synced yet is left to QuickBooks. `type: refund` makes a credit card credit and needs a credit card account (a refund on any other account answers `400`); `payment_type` is not read for a refund. For an expense, a `payment_type` of `check` or `credit_card` must agree with the account, otherwise the create answers `400`; `cash`, `other` or none leave the choice to the account. `supplier` is sent as the payee. A `line_items[]` entry with an `item` becomes an item line (`quantity` and `unit_price`, or `total_amount` when no unit price is given); an entry without one becomes an expense line (`account`, `total_amount`, `description`, `customer` and the first of its `tracking_categories`). An item line's `description`, `customer` and first `tracking_categories` entry are written too, by qbd-connect builds that include apideck-io/qbd-connect#110; an older build takes the item, quantity and price only and QuickBooks fills the description from the item.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the expense. List expenses to find it before retrying: sending the create again adds a second expense.

## PATCH /accounting/expenses/{id}

Only `number`, `transaction_date` and `memo` change. `line_items`, `account` and `supplier` sent on update are ignored; delete and recreate the expense to change them.

Updates need `row_version` from a prior read of the record. Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it, and the change can take a few minutes to show when the record is read back.

## DELETE /accounting/expenses/{id}

A delete can return a `504` timeout after 28 seconds while QuickBooks still deletes the expense. Read it back before retrying: a `404` means it is gone.

## GET /accounting/aged-creditors

Built from QuickBooks Desktop's `APAgingDetail` report, generated live on every request: the call
waits up to 25 seconds for the next Web Connector run (about once a minute, occasionally
two) and returns 408 if it does not happen in time; the report job stays queued, so repeat
the same request shortly after and it returns the finished report.
`filter[report_as_of_date]` is the date the report is run as of (today in UTC when left
out): every supplier transaction still open on that date is listed, including ones not yet
due (period 0, "current") and unapplied payments and credits (negative `outstanding_balance`).
QuickBooks ages by due date (transaction date for payments and credits) and the rows are
re-bucketed against `filter[period_count]` (default 4) and `filter[period_length]` (default
30 days), so the periods match the request exactly. `filter[supplier_id]` restricts the report to one
supplier. `supplier_id` is the QuickBooks ListID (the id `GET /accounting/suppliers/{id}` takes) and `transaction_id` the
TxnID, both resolved from the synced store by name and by type + date + number + name. The
two lookups are independent: when the supplier is not found `supplier_id` is empty; when the
transaction is not found `transaction_id` is omitted and `original_amount` falls back to the
open balance (poll again after the next sync).
`original_amount` is the transaction's own total (invoices and credit memos include sales tax).
`currency` is null: QuickBooks Desktop reports in the home currency. `report_generated_at`
is when the Web Connector returned the report.

## GET /accounting/aged-debtors

Built from QuickBooks Desktop's `ARAgingDetail` report, generated live on every request: the call
waits up to 25 seconds for the next Web Connector run (about once a minute, occasionally
two) and returns 408 if it does not happen in time; the report job stays queued, so repeat
the same request shortly after and it returns the finished report.
`filter[report_as_of_date]` is the date the report is run as of (today in UTC when left
out): every customer transaction still open on that date is listed, including ones not yet
due (period 0, "current") and unapplied payments and credits (negative `outstanding_balance`).
QuickBooks ages by due date (transaction date for payments and credits) and the rows are
re-bucketed against `filter[period_count]` (default 4) and `filter[period_length]` (default
30 days), so the periods match the request exactly. `filter[customer_id]` restricts the report to one
customer. `customer_id` is the QuickBooks ListID (the id `GET /accounting/customers/{id}` takes) and `transaction_id` the
TxnID, both resolved from the synced store by name and by type + date + number + name. The
two lookups are independent: when the customer is not found `customer_id` is empty; when the
transaction is not found `transaction_id` is omitted and `original_amount` falls back to the
open balance (poll again after the next sync).
`original_amount` is the transaction's own total (invoices and credit memos include sales tax).
`currency` is null: QuickBooks Desktop reports in the home currency. `report_generated_at`
is when the Web Connector returned the report.

## GET /accounting/bank-feed-accounts

A bank feed account is a QuickBooks Desktop `Bank` or `CreditCard` account; `id` is the
account ListID and listing returns exactly those accounts.

## POST /accounting/bank-feed-accounts

Creating with `target_account_id` links that existing Bank/CreditCard account (no write).
Creating without it adds the account in QuickBooks; because the Web Connector polls on a
schedule, that call can return a timeout error — the account is still created, and
retrying the same request links it (create is idempotent by name). Bank feeds post
transactions straight into the register: set the `bank_feed_offset_account` connection
setting to the income/expense account lines are categorised to. If it is blank,
QuickBooks' Uncategorized Income / Uncategorized Expenses accounts are used, and files
that do not have them reject every line (error 3140).

## GET /accounting/bank-feed-statements

QuickBooks Desktop has no bank-feed review screen: lines are posted to the register as
native transactions on the Web Connector's next run. `status` is `pending` until every
line posted, then `success`, or `rejected` as soon as QuickBooks rejected a line. Use
`filter[bank_feed_account_id]` to read one account's statements. Per-line QuickBooks
transaction ids and rejection reasons are not part of the unified transaction model;
read the statement with `raw=true` to see them.

## POST /accounting/bank-feed-statements

Each transaction is written to the register as a native Deposit, Check, Credit Card
Charge or Credit Card Credit (chosen from the account type and `credit_or_debit`),
categorised to the `bank_feed_offset_account` connection setting; leave it blank only if
the company file has QuickBooks' Uncategorized Income / Uncategorized Expenses accounts,
otherwise every line is rejected (error 3140). Creating a statement returns its `id` with
status `pending`; poll the statement until `status` is `success` or `rejected`.
`source_transaction_id` is required and is the dedup key: re-sending a statement never
posts a line twice. `counterparty`, `currency` and balances are stored but not written.

## GET /accounting/categories

Categories are the QuickBooks customer types (`type: customer`) and vendor types (`type: supplier`), customer types first. QuickBooks has no expense or revenue categories: `filter[type]=expense` and `filter[type]=revenue` return an empty list. The `id` is `customer-` or `supplier-` followed by the QuickBooks ListID, because the two lists are numbered separately and share ids. `name` is the full name of the type, with its parents (`Parent:Child`). Read-only.

QuickBooks Desktop does not expose a reliable cross-page total record count. `meta.total_count` will not appear.

## GET /accounting/categories/{id}

A category is a QuickBooks customer type or vendor type. The `id` is `customer-` or `supplier-` followed by the QuickBooks ListID (as returned by the list); a bare ListID answers `404`, because the two lists share ids.

## GET /accounting/quotes

Quotes are QuickBooks estimates. `status` is not returned: QuickBooks only marks an estimate active or inactive, which does not tell a sent, an accepted and a rejected quote apart. `expiry_date` and `currency` are not returned. Supported filters: `number`, `updated_since` and `created_since`; `customer_id` is not supported.

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/quotes

A `line_items[]` entry sends `unit_price`, or `total_amount` when no unit price is given. `status`, `expiry_date`, `line_items[].tax_rate` and `currency` are not written. `customer_memo` is not written either: QuickBooks holds it as a reference to its Customer Message list and refuses the document for any other text.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the quote. List quotes to find it before retrying: sending the create again adds a second quote.

## PATCH /accounting/quotes/{id}

Only `customer`, `number`, `quote_date` and `reference` change. `line_items` sent on update are ignored; delete and recreate the quote to change its lines.

Updates need `row_version` from a prior read of the record. Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it, and the change can take a few minutes to show when the record is read back.

## DELETE /accounting/quotes/{id}

A delete can return a `504` timeout after 28 seconds while QuickBooks still deletes the quote. Read it back before retrying: a `404` means it is gone.

## GET /accounting/projects

Projects are QuickBooks jobs: the customers that belong to another customer (`Customer:Job`), at any depth. `customer` is the customer the job belongs to, with its `id` when the job sits directly under it; a job under another job has `parent_project` and the customer's name only. `status` follows the QuickBooks job status: `approved` (Awarded), `in_progress` (In progress), `completed` (Closed), `draft` (Pending) and `cancelled` (Not awarded); a job without a job status has none. `start_date`, `end_date` and `completion_date` are the job's start date, projected end date and end date. Budgets, amounts, hours and billing settings are not returned. Supported filters: `name`, `status` and `updated_since`; `customer_id` is not supported. `filter[status]` takes the statuses the list returns; `active` is read as `in_progress`, and `on_hold` and `other`, which QuickBooks does not have, match nothing. Supported sort keys: `name`, `start_date`, `end_date`, `created_at` and `updated_at`; `status` is not, because QuickBooks orders by its own status names.

QuickBooks Desktop does not expose a reliable cross-page total record count. `meta.total_count` will not appear.

## POST /accounting/projects

Creates a QuickBooks job under `parent_project` when one is given, otherwise under `customer`. Either is named by its `id`, or by name (`parent_project.name`, the full `Customer:Job` path, or `customer.display_name`) when no id is sent. One of the two is required: without it the create answers `400`. Written: `name`, `description`, `status`, `active`, `start_date`, `end_date` (the projected end date) and `completion_date`. `status` is written as the QuickBooks job status: `approved` as Awarded, `in_progress` and `active` as In progress, `completed` as Closed, `draft` as Pending and `cancelled` as Not awarded; `on_hold` and `other` have no QuickBooks equivalent and are not written. Budgets, amounts, hours and billing settings are not written.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the job. List projects to find it before sending the create again.

## GET /accounting/projects/{id}

A project is a QuickBooks job, a customer that belongs to another customer. The id of a customer that is not a job answers `404`.

## PATCH /accounting/projects/{id}

Changes `name`, `description`, `status`, `active`, `start_date`, `end_date` and `completion_date`. `row_version` from a prior read is required. The customer and the parent project cannot be changed, and `status` `on_hold` and `other` are not written.

Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it. The change can take a few minutes to show when the record is read back.

## DELETE /accounting/projects/{id}

Writes are applied on the Web Connector's next run, so a delete can return a `504` timeout after 28 seconds while QuickBooks still deletes the job. Read it back before retrying: a `404` means it is gone.

## GET /accounting/sales-orders

`status` is `closed` when the order was closed by hand in QuickBooks, `invoiced` when it is fully invoiced, otherwise `open`. `delivery_date` and `currency` are not returned. Supported filters: `number`, `updated_since` and `created_since`; `customer_id` is not supported.

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/sales-orders

A `line_items[]` entry sends `unit_price`, or `total_amount` when no unit price is given. `status`, `line_items[].tax_rate` and `currency` are not written. `customer_memo` is not written either: QuickBooks holds it as a reference to its Customer Message list and refuses the document for any other text.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the sales order. List sales orders to find it before retrying: sending the create again adds a second sales order.

## PATCH /accounting/sales-orders/{id}

Only `customer`, `number`, `order_date` and `notes` change. `line_items` sent on update are ignored; delete and recreate the sales order to change its lines.

Updates need `row_version` from a prior read of the record. Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it, and the change can take a few minutes to show when the record is read back.

## DELETE /accounting/sales-orders/{id}

A delete can return a `504` timeout after 28 seconds while QuickBooks still deletes the sales order. Read it back before retrying: a `404` means it is gone.

## GET /accounting/employees

`status` is `active` or `inactive`: an employee released in QuickBooks keeps that status and carries the release date in `termination_date`. Supported filters: `status` (`active` or `inactive`) and `updated_since`. Social security numbers are never returned.

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/employees

An employee needs `display_name` or `first_name`; `display_name` defaults to the first and last name. One address (`line1`, `line2`, `city`, `state`, `postal_code`, `country`), the `primary` and `mobile` phone numbers and one email are written. `notes`, a fax number and further address lines are not written. Social security numbers are never written.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the employee. List employees to find it before retrying: sending the create again adds a second employee.

## PATCH /accounting/employees/{id}

The same fields are written as on create; `notes` and a fax number are not. A field cannot be cleared by sending `null`: it keeps its value.

Updates need `row_version` from a prior read of the record. Writes are applied on the Web Connector's next run, so an update can return a `504` timeout after 28 seconds while QuickBooks still applies it, and the change can take a few minutes to show when the record is read back.

## DELETE /accounting/employees/{id}

A delete can return a `504` timeout after 28 seconds while QuickBooks still deletes the employee. Read it back before retrying: a `404` means it is gone.

## GET /accounting/payment-methods

`type` is `credit_card` for every QuickBooks card type (Visa, MasterCard, American Express, Discover) and `electronic` for an e-check.

QuickBooks Desktop does not expose a reliable cross-page total record count. Getting `total_count` requires a separate COUNT query — an extra API call that is not currently implemented. `meta.total_count` will not appear.

## POST /accounting/payment-methods

`name` is required. `type` `bank_transfer` has no QuickBooks equivalent and is left unset.

Writes are applied on the Web Connector's next run, so a create can return a `504` timeout after 28 seconds while QuickBooks still creates the payment method. List payment methods to find it before retrying: sending the create again adds a second payment method.

## DELETE /accounting/payment-methods/{id}

A delete can return a `504` timeout after 28 seconds while QuickBooks still deletes the payment method. Read it back before retrying: a `404` means it is gone.


[API reference](https://developers.apideck.com/apis/accounting/reference.md) · [Coverage matrix](https://developers.apideck.com/apis/accounting/coverage)
