Inventory valuation report
distru-report-inventory-valuationReadCurrent stock and value per product, by state: active, reserved, available and incoming.
Inputs
Every tool also takes the common inputs.
| Field | Type | Required | Description |
|---|---|---|---|
| cursor | string | No | nextCursor of the previous call; keep the other arguments unchanged. |
| calculationMethod | enumCOSTPRICE | No | Values active stock at unit price (PRICE, default) or unit cost (COST, 0 when none). Only activeValue changes. |
| locationIds | string[] | No | Narrows the counted stock, not the products. ORed with userIds. Resolve via distru-search-locations. |
| search | string | No | Case-insensitive substring of product name or SKU, or fuzzy match on name. Row order unchanged. |
| userIds | string[] | No | Narrows the counted stock to these users' inventory, not the products. ORed with locationIds. Resolve via distru-search-users. |
| productCategoryIds | string[] | No | Product category of the rows. ORed with productSubcategoryIds; a listed subcategory of a listed category narrows that category to it. Resolve via distru-search-lookups (type PRODUCT_CATEGORY). |
| productSubcategoryIds | string[] | No | Product subcategory of the rows. See productCategoryIds. Resolve via distru-search-lookups (type PRODUCT_CATEGORY, each row's subcategories). |
| productTagIds | string[] | No | Any of these tags on the product. Resolve via distru-search-lookups (type PRODUCT_TAG). |
| vendorIds | string[] | No | The vendor set on the product, not the company an order was placed with. Resolve via distru-search-companies. |
| brandIds | string[] | No | Product brand of the rows, itself a company. Resolve via distru-search-companies, or read it on a distru-search-products row. |
| productGroupIds | string[] | No | Resolve via distru-search-lookups (type PRODUCT_GROUP). |
| maxRowsLimit | integer | No | Rows per page. Defaults to 500. |
Output
Presence on a nested field assumes its parent exists.
| Field | Type | Presence | Description |
|---|---|---|---|
| nextCursor | string | Can be absent | Pass as cursor to fetch the next page. Present only when meta.truncated. |
| meta | object | Always | |
| meta. | string | Always | |
| meta. | string | Always | |
| meta. | number | Always | |
| meta. | number | Always | |
| meta. | number | Always | |
| meta. | number | Always | |
| meta. | boolean | Always | |
| meta. | object[] | Always | |
| meta. | string | Always | |
| meta. | string | Always | |
| rows | object[] | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Can be null | |
| rows[]. | string | Can be null | |
| rows[]. | string | Can be null | |
| rows[]. | string | Always | |
| rows[]. | string | Can be null | |
| rows[]. | string | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Can be null | |
| rows[]. | string | Always | |
| rows[]. | string | Can be null | |
| rows[]. | string | Can be null | |
| rows[]. | string | Always | |
| rows[]. | string | Can be null | |
| rows[]. | string | Can be null | |
| rows[]. | string | Can be null | |
| rows[]. | object[] | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Always | |
| rows[]. | string | Can be null |
What the AI reads
Current stock per product: one row per product with its quantities by state (active, assembling, reserved, available, incoming, pending output), unit cost and price, alert thresholds and the value of its active stock. As of now only. Use for stock levels, stock value and products under or over their thresholds. For stock by location, batch or package, or as of a past date, use distru-report-inventory-assets; for stock movements use distru-report-inventory-transaction-history. activeQuantity is only stock free in inventory, so stock being assembled, sold, returned or transferred is already out of it; never subtract assemblingQuantity from it. activeQuantityPassedTesting is the part of activeQuantity held in packages whose lab test or retest passed, not listed in meta.columns; null for batch- and product-tracked products. availableQuantity is active minus reserved and can be negative; incomingQuantity is ordered on purchases but not yet received, drafts included; pendingOutputQuantity is still owed by open assemblies and not yet in active. Every matching active product gets a row, with 0 quantities when it has no stock. Rows come by available quantity, highest first. Every value is a numeric string. Returns 500 rows by default (maxRowsLimit, up to 5000). When meta.truncated is true more rows exist: repeat the call with the same filters, any date range made explicit so every page covers the same one, and cursor set to nextCursor — or narrow the filters when you need a summary rather than every row.