We can call the products list by soap api as a whole without passing any parameters to the api call. But when we need to filter the products based on attributes we must pass the multiple attributes as an array.Here we are discussing about how to get the products list filtered by attributes soap api magento

$proxy = new SoapClient('http://magentohost/api/soap/?wsdl');
$sessionId = $proxy->login('apiUser', 'apiKey');
 
$filters = array(array('sku' => array('like'=>'zol%'),array('name' => array('like'=>'zol%'))
);
 
$products = $proxy->call($sessionId, 'product.list', $filters);
 
var_dump($products);

hope this will help you to get products list filtered by attributes soap api magento

2 Comments on “Products list filtered by attributes soap api magento

  1. magento hosting optimized
    February 6, 2014

    That is pretty attention-grabbing, You’re an exceedingly specialist blog writer. We have registered your current feed and stay way up regarding trying to get more of your current superb submit. In addition, We’ve contributed your website within my social networking sites

  2. lou
    June 7, 2019

    Hi, this kind of filter is for AND condition. Is there a way to build an OR condition too?

Leave a Reply

Your email address will not be published.