Search.../
  1. Home
  2. Getting Started
  3. Overview
Generate a test token to explore our APIs

Update Inventory Variants

Updates product inventory, including total quantity, whether the product is in stock, and whether the product inventory is tracked

Authorization

This endpoint requires an authorization header - pass the access token from the OAuth installation flow.

Permissions

This endpoint requires the Manage Products permission scope.

PATCH

https://www.wixapis.com/stores/v2/inventoryItems/{inventoryItem.id}

Path Params

NAME
TYPE
DESCRIPTION
inventoryItem.id
Required

string

Inventory item ID

Body Params

NAME
TYPE
DESCRIPTION
inventoryItem
Required

object

Response Object

Returns an empty object.

Status/Error Codes

The response will include an HTTP status code.

Was this helpful?

Example 1

Request

curl

Copy Code
1curl -X PATCH https://www.wixapis.com/stores/v2/inventoryItems/0ff8f8b0-2857-5974-193e-8283c21fde00 \
2 -H 'Content-Type: application/json' \
3 -H 'Authorization: <AUTH>' \
4 --data-binary '
5 {
6 "inventoryItem": {
7 "trackQuantity": false,
8 "variants": [
9 {
10 "variantId": "00000000-0000-0001-0005-9a596c8e6f10",
11 "inStock": true
12 },
13 {
14 "variantId": "00000000-0000-0002-0005-9a596c8e6f10",
15 "inStock": true
16 }
17 ]
18 }
19 }'

Response

json

1
2{}
Example 2
Example 3