POST UpdateProduct
Create/Update a product.
This feature must be enabled for your account.
Input and output parameters
*denotes required field.
    
        | Input Parameter Name | 
        Type/Info | 
    
    
        | id | 
        id of the product in the system, provide this if you want to update. | 
    
    
        | sku* | 
        sku of the product. If no "id" is provided, we'll use this to update your product. | 
    
    
        | api_reference_id* | 
        your reference to identify the product. | 
    
    
        | group_type* | 
        parent-product|child-product|standalone-product. | 
    
    
        | name* | 
        Name of product. | 
    
    
        | description* | 
        Product details. | 
    
    
        | barcode | 
        Product barcode. | 
    
    
        | uri | 
        URL path to product in your system. | 
    
    
        | price_tax | 
        Cost of the tax applied to product. | 
    
    
        | original_price | 
        Cost of product, ie RRP. | 
    
    
        | price* | 
        Cost of product. | 
    
    
        | price_inc_tax* | 
        Product price with tax. | 
    
    
        | weight | 
        float quantity of weight specified by weight_unit. | 
    
    
        | weight_unit | 
        kg|g|lb|oz. | 
    
    
        | stock_quantity | 
        Integer of items in stock. | 
    
    
        | product_create_date* | 
        Date product created in your system YYYY-MM-DD HH:MM:SS. | 
    
    
        | product_update_date* | 
        Date product updated in your system YYYY-MM-DD HH:MM:SS. | 
    
    
        | visibility* | 
        not-individually|public|private. | 
    
    
        | status* | 
        active|disabled|deleted|partial. | 
    
    
        | product_links | 
        
            Array of links.
            
                - link_product_sku - link to product by sku.
 
                - link_type - associated|crosssell|related|upsell
 
             
         | 
    
    
        | product_options | 
        
            Array of options.
            
                - name - Option name, ie size, colour etc.
 
                - value - Option value, ie 12, 14, Small, Large, red, yellow.
 
                - position - order of options (optional).
 
             
         | 
    
    
        | product_images | 
        
            Array of images.
            
                - uri - path to the image.
 
                - name - Assign a name to this image.
 
                - position - order of images (optional), lowest will be used as product main image.
 
             
         | 
    
    
        | product_categories | 
        
            Array of categories.
            
                - name - category name.
 
                - path - category structure, ie /mens/shoes/, /sale/womens/shoes/.
 
                - client_reference - (optional) your reference for the category.
 
             
         | 
    
    
        | parent_variation_skus | 
        
            
                - array containting the sku of the parent products.
 
             
         | 
    
    
        | child_variation_skus | 
        
            
                - array containing the sku of the child products.
 
             
         | 
    
    
        | custom_fields | 
        
            Array of key value pairs for any custom fields data 
            Key is the field name then value assigned: 
            
         | 
    
    
         | 
    
    
        | Outputs: | 
         | 
    
    
        
            
                - id - system id for the product
 
                - message - created|updated
 
             
         | 
    
Examples
curl --request POST \
  --url https://api.wiredplus.com/v1/UpdateProduct \
  --header 'content-type: application/json' \
  --data '{"id":"abc","api_reference_id":"1234","sku":"ABCD-1234","group_type":"standalone-product","name":"Myproduct","description":"Allaboutmyfantasicproduct.","barcode":"11223344","uri":"http://your-site.com/products/ABCD-1234","price_tax":"20.00","original_price":"16.00","price":"20.00","price_inc_tax":"24.00","weight":"5","weight_unit":"lb","stock_quantity":"100","product_create_date":"2019-08-0914:02:10","product_update_date":"2019-08-0914:02:10","visibility":"public","status":"active","product_links":[{"link_product_sku":"ABCD-1234","link_type":"crosssell"}],"product_options":[{"name":"Size","value":"S","position":0},{"name":"Size","value":"M","position":1}],"product_images":[{"uri":"http://your-site.com/imgs/products/ABCD-1234-1.png","name":"Frontimage","position":0,},{"uri":"http://your-site.com/imgs/products/ABCD-1234-2.png","name":"Backimage","position":1,}],"product_categories":[{"name":"Sales","path":"/sales/","client_reference":"1111"},{"name":"SaleShoes","path":"/sales/shoes/","client_reference":"2222"}],"parent_variation_skus":["111", "222"],"child_variation_skus":["abc","def"],"custom_fields":{"Favorite Colour": "Blue"}}'
    
    
    
$curl = curl_init();
curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.wiredplus.com/v1/UpdateProduct",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_POSTFIELDS => '{"id":"abc","api_reference_id":"1234","sku":"ABCD-1234","group_type":"standalone-product","name":"Myproduct","description":"Allaboutmyfantasicproduct.","barcode":"11223344","uri":"http://your-site.com/products/ABCD-1234","price_tax":"20.00","original_price":"16.00","price":"20.00","price_inc_tax":"24.00","weight":"5","weight_unit":"lb","stock_quantity":"100","product_create_date":"2019-08-0914:02:10","product_update_date":"2019-08-0914:02:10","visibility":"public","status":"active","product_links":[{"link_product_sku":"ABCD-1234","link_type":"crosssell"}],"product_options":[{"name":"Size","value":"S","position":0},{"name":"Size","value":"M","position":1}],"product_images":[{"uri":"http://your-site.com/imgs/products/ABCD-1234-1.png","name":"Frontimage","position":0,},{"uri":"http://your-site.com/imgs/products/ABCD-1234-2.png","name":"Backimage","position":1,}],"product_categories":[{"name":"Sales","path":"/sales/","client_reference":"1111"},{"name":"SaleShoes","path":"/sales/shoes/","client_reference":"2222"}],"parent_variation_skus":["111", "222"],"child_variation_skus":["abc","def"],"custom_fields":{"Favorite Colour": "Blue"}}',
  CURLOPT_HTTPHEADER => array(
    "content-type: application/json"
  ),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
    echo "cURL Error #:" . $err;
} else {
    echo $response;
}
    
    
var data = {
    "id": "abc",
    "api_reference_id": "1234",
    "sku": "ABCD-1234",
    "group_type": "standalone-product",
    "name": "My product",
    "description": "All about my fantasic product.",
    "barcode": "11223344",
    "uri": "http://your-site.com/products/ABCD-1234",
    "price_tax": "20.00",
    "original_price": "16.00",
    "price": "20.00",
    "price_inc_tax": "24.00",
    "weight": "5",
    "weight_unit": "lb",
    "stock_quantity": "100",
    "product_create_date": "2019-08-09 14:02:10",
    "product_update_date": "2019-08-09 14:02:10",
    "visibility": "public",
    "status": "active",
    "product_links": [
        {
            "link_product_sku": "ABCD-1234",
            "link_type": "crosssell"
        }
    ],
    "product_options": [
        {
            "name": "Size",
            "value": "S",
            "position": 0
        },
        {
            "name": "Size",
            "value": "M",
            "position": 1
        }
    ],
    "product_images": [
        {
            "uri": "http://your-site.com/imgs/products/ABCD-1234-1.png",
            "name": "Front image",
            "position": 0,
        },
        {
            "uri": "http://your-site.com/imgs/products/ABCD-1234-2.png",
            "name": "Back image",
            "position": 1,
        }
    ],
    "product_categories": [
        {
            "name": "Sales",
            "path": "/sales/",
            "client_reference": "1111"
        },
        {
            "name": "Sale Shoes",
            "path": "/sales/shoes/",
            "client_reference": "2222"
        }
    ],
    "parent_variation_skus":[
        "111",
        "222"
    ],
    "child_variation_skus":[
        "abc",
        "def"
    ],
    "custom_fields": {
        "Favorite Colour": "Blue"
    }
};
var settings = {
  "async": true,
  "crossDomain": true,
  "url": "https://api.wiredplus.com/v1/UpdateProduct",
  "method": "POST",
  "headers": {},
  "processData": false,
  "contentType": false,
  "mimeType": "application/json",
  "data": JSON.stringify(data)
}
$.ajax(settings).done(function (response) {
  console.log(response);
});
    
    
Result Format JSON