NOTE: This is an article for the legacy API. For the current endpoint, see the HTML guide attached to the bottom of the REST API Access article.
Description: Returns the Current Stock Outs grid from the Stock Outs screen in the Inventory module.
Resource: StockOutsDetail/
Verb: GET
Returns: JSON array of stock out objects
Query String Arguments:
- numberOfDaysToCheckForRecentStockouts (optional)- Number. How many days back StockIQ counts recent stock outs for NumberOfTimesHaveBeenOut. Defaults to 90.
- itemIds, siteIds, primarySupplierIds, buyerIds, shipperIds (optional)- Lists of ids to filter by.
- abcClasses, xyzClasses (optional)- Lists of class codes to filter by.
- orderPolicies, itemStatuses, bomPositions (optional)- Lists of numeric values to filter by.
- itemSiteCategory1Ids ... itemSiteCategory8Ids (optional)- Lists of item-site category ids to filter by.
NOTE: Which stock outs are returned (items with non-stock order policies, zero safety stock, replaced items and never-stocked items) follows your organization's Stock Out Policy on the Global Inventory Limits screen. The old includeNonStockPolicies, includeItemsWithZeroSafetyStock and includeReplacedItems arguments are ignored if sent.
Example JSON:
[{
"AlertKeyId": 14,
"AlertType": 1,
"PrimaryId": 14,
"PrimaryIdProperty": 1,
"NumberOfTimesHaveBeenOut": 0,
"ProjectedInStockDate": "2024-07-02T00:00:00",
"IsOutOfStockInSiteGroup": true,
"ItemSiteId": 14,
"OutOfStockQuantity": 0.00000,
"ShipperId": 4,
"ItemId": 13,
"SiteId": 13,
"PrimarySupplierId": 31,
"ItemCode": "0101010",
"SiteCode": "261",
"SiteGroupName": "Asia",
"BuyerName": "Lewis Hamilton",
"ItemDescription": "Contoso 4G MP3 Player E400 Green",
"ActiveOrderPolicy": 4,
"ResolvedItemStatus": 1,
"ActiveSafetyStock": 462.00000,
"AbcClass": "C",
"XyzClass": "Y",
"CurrentCost": 5.00000,
"StandardCost": 5.00000,
"StandardPrice": 8.00000,
"PrimarySupplierName": "Eisen Wholesale",
"TargetServiceLevel": 0.900000,
"LeadTime": 15,
"TotalOnHandQuantity": 0.00000,
"TotalAvailableQuantity": 0.00000,
"TotalAvailableQuantityAtLeadTime": 0.00000,
"TotalOnOrderQuantity": 0.00000,
"TotalHistoricalDailyUsage": 0.0,
"InventoryPosition": 1,
"LostRevenuePerDay": 0.0,
"TotalOnDemandOrderQuantity": 0.00000,
"TotalOnDemandValue": 0.00000,
"ItemSiteCategory1Name": "Audio",
"ItemSiteCategory2Name": "MP4&MP3",
"ItemSiteCategory3Name": "Unassigned",
"ItemSiteCategory4Name": "Unassigned",
"ItemSiteCategory5Name": "Unassigned",
"ItemSiteCategory6Name": "Unassigned",
"ItemSiteCategory7Name": "Unassigned",
"ItemSiteCategory8Name": "Unassigned",
"SiteGroupInventoryPosition": 1,
"SiteGroupUsagePattern": 2,
"SiteGroupOnHandQuantity": 0.00000,
"SiteGroupAvailableQuantity": 0.00000,
"ReplacementFlags": 0,
"IsOnHandCopied": false,
"ItemSiteCategory1Id": 3,
"ItemSiteCategory2Id": 31,
"ItemSiteCategory3Id": 1,
"ItemSiteCategory4Id": 1,
"ItemSiteCategory5Id": 1,
"ItemSiteCategory6Id": 1,
"ItemSiteCategory7Id": 1,
"ItemSiteCategory8Id": 1,
"BuyerId": 2,
"BoMPosition": 0,
"SupplierItemCode": "0101010",
"AlertSummaryId": 0,
"DateCreated": "0001-01-01T00:00:00",
"DateUpdated": "0001-01-01T00:00:00+00:00",
"ASt": 0,
"APri": 0,
"AlertTypeName": "StockOut"
}, ...]