update_addon_product_quantity
Set a new absolute stock quantity for an addon product using its ID, overwriting the current inventory immediately.
Instructions
[WRITE] 更新加購商品庫存數量。
【用途】 直接以 ID 更新指定加購商品的庫存數量。
【呼叫的 Shopline API】
PUT /v1/addon_products/{addon_product_id}/quantity
【回傳結構】 dict 含 success: bool, resource_id: str, message: str。
【副作用】
指定加購商品的庫存數量將被覆蓋為新值
庫存變動立即生效
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"addon_product_id": "<addon_product_id>",
"quantity": "<quantity>"
},
"name": "update_addon_product_quantity"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| quantity | Yes | 新的庫存數量(絕對值,非差異) | |
| addon_product_id | Yes | 加購商品 ID |