The Low Stock endpoint filters the ingredients of a given pantry and returns only those whoseDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/NicolasMPP/restorante-springboot/llms.txt
Use this file to discover all available pages before exploring further.
cantidadStock is at or below a caller-supplied threshold. Because the threshold is a request parameter, you can tune the alert level to match your kitchen’s reorder cadence — query conservatively to catch items before they run out, or more aggressively to bulk-order less frequently. An empty array is returned when all ingredients are above the threshold.
Endpoint
Parameters
The unique identifier of the pantry to inspect. Must correspond to an existing
Despensa record.The stock threshold. Any ingredient whose
cantidadStock is less than or equal to this value will be included in the response. Must be a non-negative integer.Request Example
Response — 200 OK
Returns a JSON array ofIngrediente objects matching the threshold condition. The array may be empty if all pantry ingredients have stock above umbral.
Response Fields
Unique identifier of the ingredient.
Human-readable name of the ingredient (max 100 characters).
Current stock quantity for this ingredient. Guaranteed to be ≤ the requested
umbral.Threshold vs. Statistics
This endpoint accepts a customumbral per request, so different clients or dashboards can use different thresholds simultaneously. The stockBajo counter returned by GET /api/despensa/{id}/estadisticas uses a fixed internal threshold of 10 units (cantidadStock < 10) and cannot be changed at runtime. Use this endpoint whenever you need flexible threshold control.