Request Details

Method Controller Resource Parameters
PUT product change outlet_id /product_id : product_name : product_desc : image : price : discount : qty : reorder_level : delivery_type : weight : shipping_cost : availability : promo_price : promo_start_date : promo_end_date

Parameters Guide

Parameter Accepts
outlet_id int outlet id as provided by BeepXtra
product_id int The existing product id you wish to use for this outlet
product_name string Product name in alphanumeric latin characters only (Regex [a-zA-Z0-9_] )
product_desc string Product description in alphanumeric latin characters only (Regex [a-zA-Z0-9_] )
image string default value of "image" required
price double Sale Price of product
discount double Discount percentage for Beep Cashback (0 for no discount or minimum 2.50)
qty int current quantity in stock
reorder_level int The minimum stock level to trigger a reminder to the outlet
delivery_type string pickup shiplocal shipintl
weight double weight of product or 0 to disable
shipping_cost double Cost amount for shipping or 0 to disable
availability tinyint 0 for N/A or 1 for Available
promo_price double Price override if special promo enabled (See dates below)
promo_start_date date Starting Date of special pricing override
promo_end_date date Ending Date of special pricing override

Example Request Format

Direct Url https://api.beepxtra.com/product/change/391/123:dog shoes:doggy shoes, size 53:image:100.05:2.5:10:2:pickup:0:1:1:0:0:0
Curl CURL -A "YOURAPPNAME|1.0|AppID|AppKEY|product" -X PUT https://api.beepxtra.com/product/change/391/123:dog shoes:doggy shoes, size 53:image:100.05:2.5:10:2:pickup:0:1:1:0:0:0
PHP SDK $beepapi->request('put', 'product', 'change/391/1275:dog shoes:doggy shoes:image.jpg:100.25:2.5:10:2:pickup:0:1:1:0:0:0');

Sample Response

Success
{  
   "success":true,
   "request":{  
      "method":"PUT",
      "controller":"product",
      "resource":"change",
      "parameters":"\/product\/change\/391\/1275:dog+shoes:doggy+shoes:image_jpg:100_25:2_5:10:2:pickup:0:1:1:0:0:0",
      "url_elements":[  
         "product",
         "change",
         "391",
         "1275:dog shoes:doggy shoes:image.jpg:100.25:2.5:10:2:pickup:0:1:1:0:0:0"
      ]
   },
   "error":{  
      "errorid":0,
      "message":0
   },
   "data":{  
      "success":"true"
   }
}
Error
{  
   "success":false,
   "request":{  
      "method":"PUT",
      "controller":"product",
      "resource":"change",
      "parameters":"\/product\/change\/391\/125:dog+shoes:doggy+shoes:image_jpg:100_25:2_5:10:2:pickup:0:1:1:0:0:0",
      "url_elements":[  
         "product",
         "change",
         "391",
         "125:dog shoes:doggy shoes:image.jpg:100.25:2.5:10:2:pickup:0:1:1:0:0:0"
      ]
   },
   "error":{  
      "message":"This product is currently not used in this outlet",
      "errorid":1000
   },
   "data":{  
      "error":"This product is currently not used in this outlet",
      "errorid":1000,
      "errormsg":"This product is currently not used in this outlet"
   }
}

Response Guide

Parameter Type Details
error String Returns Error Object with errorid and errormsg
success boolean Returns true if successful