Storeden Developers

Inventory API

Current version: v1.1

Get global inventory status

GET
/inventory/list.json
Get global inventory status Request

$storeden = new Storeden\Storeden($config);
$result = $storeden->get('/inventory/list.json');
					
Get global inventory status Response

[
    {
        "sku": "a58",
        "uid": 49532,
        "quantity": 0,
        "unlimited": false,
        "has_child": true,
        "childs": [
            {
                "sku": "0000125452",
                "quantity": 1005,
                "superkey": "40"
            },
            {
                "sku": "0000125453",
                "quantity": 1005,
                "superkey": "42"
            }
        ]
    },
    ...
    {
        "sku": "79",
        "uid": 49649,
        "quantity": null,
        "unlimited": false,
        "has_child": false
    }
]
					

Update Product quantity

PUT
/inventory/inventory.json
sku required (string) Unique id of your post
quantity required (int)
is_child (int) Accept 1 or 0 as value. If the specified SKU is a product-variant SKu, you must set this field to 1.
Update Product quantity Request

$storeden = new Storeden\Storeden($config);

$payload = array();
payload['sku'] = '0000125452';
payload['quantity'] = 1005;
payload['is_child'] = 1;

$result = $storeden->put('/inventory/inventory.json', $payload);
					
Update Product quantity Response

{
    "is_child": true,
    "inventory_updated": 1,
    "err": null
}