Skip to main content

Inventory Recon Accounts (Earmark Suggestions)

GET 

/api/ledger/reconciliation/inventory/accounts

Candidate inventory control accounts for the daily reconciliation earmark step. Pulls SKU's current-asset nominal codes (plus any warehouse-mapped account), cross-references the provider's cached current-asset chart (Xero xero_accounts, matched by code — no live provider call), computes each account's point-in-time SKU inventory value as-of now, and flags which look like inventory accounts. Suggested-then-code ordered.

Not yet available to API tokens

This endpoint currently requires session authentication; Personal Access Token scope support is in progress.

Authentication: Requires Bearer token.

Row fields: nominal_code_id, code, sku_name, sku_type, provider_account_name, provider_account_type, provider_account_id (nullable when no provider match), warehouse_count, warehouse_names[], is_earmarked (the user's persisted decision), is_suggested (heuristic), suggestion_reasons[] (strongest first: warehouse-mapped, SKU type Inventory, provider type Inventory, name looks like inventory), current_sku_value (null when no warehouse — and therefore no SKU inventory — maps to it). current_sku_value sums THREE valuation subsystems, because inventory does not all live in one place: standard warehouse stock (fifo_layers), Amazon FBA stock, and Amazon AWD stock (both in amazon_fifo_layers). An AWD or FBA control account therefore shows its real value here rather than $0 — before AWD was folded in, the one account that most needed earmarking looked like an empty one.

Request

Responses

OK

Response Headers
    Content-Type