List low stock alerts
Any signed in user. Returns active medicines at or below their threshold, thinnest first. Each row carries the shortfall, so the caller orders against the gap, not recomputing it.
GET
/api/v1/alerts/low-stockAuthorization
AuthorizationBearer token (JWT) · headerrequiredJWT from POST /api/v1/auth/login sent as Authorization Bearer.
Query parameters
branch_idstringCount stock for one branch only. Omitted means every branch.
Responses
200
Medicines at or below their threshold
alertsobject[]requiredShow propertiesHide properties
Array of
objectmedicine_idstringrequirednamestringrequiredstock_quantitynumberrequiredlow_stock_thresholdnumberrequireddeficitnumberrequiredcountintegerrequiredmin -9007199254740991 · max 9007199254740991
401
Not authenticated
detailstringrequired