My goal is to get and display all additional attributes for a Magento product using the SOAP API. For example, gender, shirt size and color for t-shirts. But the program does not need to know the names of the attributes.
SOAP Call: catalogProductInfo has an additional attribute parameter, and it looks like I should explicitly specify additional attribute names.
I use Java and Apache Axis to connect to the Mangeto SOAP API, and the following code:
stub.catalogProductInfo(sessionId, "118", null, null); call declaration: public com.magentocommerce.api.CatalogProductReturnEntity catalogProductInfo(java.lang.String sessionId, java.lang.String productId, java.lang.String storeView, com.magentocommerce.api.CatalogProductRequestAttributes attributes) throws java.rmi.RemoteException { attributes parameter constructor declaration: public CatalogProductRequestAttributes( java.lang.String[] attributes, java.lang.String[] additional_attributes) {
But I have to specify the last parameter to get all the additional attributes. Is this possible using the SOAP API?
Refresh : "*" because the attribute is not working
CatalogProductRequestAttributes attrs = new CatalogProductRequestAttributes(); attrs.setAttributes(new String[] {"*"}); attrs.setAdditional_attributes(new String[] {"*"});
The resulting object is not populated with either standard attributes or additional attributes.
source share