List the organization's preps

Changed on

Every live prepared product of the organization by name, a prep never published included: its id, name, photo, category name and base unit; ingredientCount and output, what one batch makes, by its current recipe (0 and null before its first publish); and usedBy, how many live dishes and prepared products take it by their current recipe, a dish once however many of its sizes do, with the first by name. With locationId, its stock at that venue: onHand over every storage, an integer string of thousandths, null where it has no stock row there; isLow as the Stock page marks it; and useBy, the earliest use-by of its batches there with stock left as its Stock row reads it — the day, days left, total days and whether it is estimated from the product's shelf life — null when none has one. Every stock field is null without locationId or without inventory read at that venue. NOT_FOUND for a locationId outside the organization. Refused with FORBIDDEN as inventoryDisabled while the inventory flag is off. Refused with FORBIDDEN as paywallLocked when the caller is an Owner or Manager of a business the merchant Paywall locks: one with no verified subscription that has taken 5 orders while the Paywall's rollout reaches it, an order counting from its first saved line, whether or not it is paid or completed, until it is archived or cancelled before activation. Nothing is read or written; a verified subscription lifts the lock.

post/api/public/v1/inventoryRecipes/preps

Request

  • Base URL
    https://app.fortuneos.ai
  • Auth
    none declared

Request body

object required
organizationId, string required
locationId, string

Response

OK

object[] required
stockItemId, string required
name, string required
imageUrl, string nullable required
categoryName, string nullable required
baseUnit, 'g' | 'ml' | 'pcs' required
ingredientCount, integer required
output, object nullable required
usedBy, object required
onHand, string nullable required
isLow, boolean nullable required
useBy, object nullable required

Changes