Skip to main content
PUT
/
inventory
/
{id}
/
threshold
Set the low-stock threshold for an item
curl --request PUT \
  --url https://api.autoprintfarm.com/public/v1/inventory/{id}/threshold \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "low_stock_threshold": 1
}
'
{
  "success": true,
  "data": {
    "id": "<string>",
    "product_sku_id": "<string>",
    "sku": "<string>",
    "color": "<string>",
    "material": "<string>",
    "ready_stock": 123,
    "low_stock_threshold": 123,
    "status": "<string>",
    "image_url": "<string>",
    "is_active": true,
    "created_at": "<string>",
    "updated_at": "<string>"
  }
}

Authorizations

Authorization
string
header
required

API keys are minted in the AutoPrintFarm web app under Settings → API Keys. Send as Authorization: Bearer apf_live_.... Keys are shown exactly once at creation and can be revoked at any time.

Path Parameters

id
string
required

Finished-good row id.

Body

application/json
low_stock_threshold
integer
required

New alert threshold (non-negative integer). The item's status is recomputed against ready_stock and quantity_needs_assembly.

Required range: x >= 0

Response

Threshold updated

success
enum<boolean>
required
Available options:
true
data
object
required