cancel
Showing results for 
Search instead for 
Did you mean: 

SOAP API v1 - cataloginventory_stock_item.update seems to ignore some values

SOAP API v1 - cataloginventory_stock_item.update seems to ignore some values

hi everyone,

 

i hope you guys could help me out a bit. i've been trying to figure out what's wrong with my api call to update inventory information. basically im using SOAP v1 under Magento 1.9.1.

 

i tried running the script that was demostrated here:

http://www.magentocommerce.com/api/soap/catalogInventory/cataloginventory_stock_item.update.html

 

but it seems it ignores some values (specific interest is 'use_config_min_qty' and 'min_qty') - i was able to update qty, manage_stock, but not the 'use_config_min_qty' and 'min_qty'. There was no exception and values returned for the update is TRUE.

 

I'm using PHP with the regular api calls (this is a Standard SoapClient call, i just created a library for magento Smiley Happy

 

 

			$stockItemData = array(
				'qty' => '100',
				'is_in_stock ' => 1,
				'manage_stock ' => 1,
				'use_config_manage_stock' => 1,
				'min_qty' => 2,
				'use_config_min_qty' => 0,
				'min_sale_qty' => 1,
				'use_config_min_sale_qty' => 0,
				'max_sale_qty' => 10,
				'use_config_max_sale_qty' => 0,
				'is_qty_decimal' => 0,
				'backorders' => 1,
				'use_config_backorders' => 1,
				'notify_stock_qty' => 10,
				'use_config_notify_stock_qty' => 0
			);
			
			$param = Array($product_id, $stockItemData);
			return $this->CallMethod('product_stock.update', $param);			

Hope anyone can help me Smiley Indifferent