0

I have two stock_ids (1,3) in cataloginventory_stock_item table for product admin inventory quantity fields, While iam creating the product using apis, i wants to create product by multiple stockids for different quantity value fields, in magento1.9

for single stock iam creating by below code:

$stockItemData = array('manage_stock ' => 1,
    'use_config_manage_stock' => 1, 
    'stock_id' =>  1,
    'qty' => 5,
    'is_in_stock ' => 1


);

In the above code need to pass multiple stockid for creating product through soap api.

Thanks

3
  • The core API does not provide this feature. We would need to know which extension you are using for this multi-warehouse feature?
    – Olivier
    Jul 3, 2018 at 14:59
  • it's generating while creating add specific store only, it's getting from wholesale folio theme Jul 3, 2018 at 16:21
  • I need to pass both values while creating product from soap api Jul 3, 2018 at 16:22

1 Answer 1

0

As you can see from the Magento documentation, the core API does not support updating the stock_id attribute: https://devdocs.magento.com/guides/m1x/api/soap/catalogInventory/cataloginventory_stock_item.update.html

In order to update multiple stock_id from the same SOAP call, you will have to create your own API function, as documented here: https://devdocs.magento.com/guides/m1x/api/soap/create_your_own_api.html

Usually, the extension that provides the multi-warehouse functionality offers its own API to work with various stock_id

2
  • Hi Olivier's thanks for your support I have different stock IDs but I wants to update the qty values of those stock ids Jul 3, 2018 at 17:05
  • @shivashankarm Yeah, this is not possible with the core SOAP API, it always only updates stock_id = 1. In order to do what you want, you need to code it or look for a third-party extension.
    – Olivier
    Jul 3, 2018 at 17:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.