Update WooCommerce Product
woocommerce_update_productUpdate specific fields of an existing WooCommerce product. Change status, price, stock, or other attributes without affecting other fields.
Instructions
Update fields on an existing product. Only the fields you provide are changed; all other fields are left untouched.
Args:
product_id (number, required)
Any subset of: name, status, description, short_description, sku, regular_price, sale_price, manage_stock, stock_quantity, stock_status, category_ids, tag_ids, weight
response_format ('markdown'|'json'): default 'markdown'
Returns: The updated product object.
Examples:
Use when: "mark product 42 as out of stock" -> product_id=42, stock_status="outofstock"
Use when: "put product 42 on sale for $15" -> product_id=42, sale_price="15.00"
Error Handling:
Returns "Error: Resource not found (404)" if product_id doesn't exist.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sku | No | ||
| name | No | ||
| status | No | ||
| weight | No | ||
| tag_ids | No | Replaces the product's tag assignments | |
| product_id | Yes | The numeric WooCommerce product ID to update | |
| sale_price | No | ||
| description | No | ||
| category_ids | No | Replaces the product's category assignments | |
| manage_stock | No | ||
| stock_status | No | ||
| regular_price | No | ||
| stock_quantity | No | ||
| response_format | No | Output format: 'markdown' for human-readable text or 'json' for machine-readable structured data | markdown |
| short_description | No |