Skip to main content Link Menu Expand (external link) Document Search Copy Copied

Module: Mage_Catalog

The Mage_Catalog module allows you to manage categories and products.

Category Attributes

Allows you to retrieve the list of category attributes and options.

Resource Name: catalog_category_attribute

Aliases:

  • category_attribute

Methods:

Faults

Fault CodeFault Message
100Requested store view not found.
101Requested attribute not found.

Examples

Example 1. Retrieving attributes and options
$proxy = new SoapClient('http://magentohost/api/soap/?wsdl');
$sessionId = $proxy->login('apiUser', 'apiKey');
$attributes = $proxy->call($sessionId, 'category_attribute.list');
foreach ($attributes as &$attribute) {
   if (isset($attribute['type'])
       && ($attribute['type'] == 'select' || $attribute['type'] == 'multiselect')) {
       $attribute['options'] = $proxy->call($sessionId, 'category_attribute.options', $attribute['code']);
   }
}
var_dump($attributes);

Table of contents