Helcim Logo Support & Tutorials

© Copyright 2006-2018 Helcim Inc.

All Rights Reserved.

Helcim Commerce API » Inventory »

View a Category

This API call let's you retrieve a category. The response is an XML of the category's information.

Request Fields

Field Name Type Required Description
action String Yes categoryView
accountId Integer Yes The Helcim Commerce account ID.
apiToken String Yes API token used for authentication and access control. 
categoryId Integer Yes  The category ID you wish to view.

Response Fields (XML)

Field Name Type Description
categories - XML structure
category - XML structure
id Integer The category ID.
name String The category name.
availability Integer 1 or 0 - Whether the product is available for sale.
description String The category description
picture String The URL location of the category picture.
products - XML structure
product - XML structure
id Integer The product ID.
name String The product name.
sku Integer The product SKU.
stock Integer The number of items in stock.
price Decimal The product price.
salePrice Decimal The product sale price.
availability Integer 1 or 0 - Whether the product is available for sale.
availabilityOnline Interger 1 or 0 - Whether the product is available for sale online.
picture String The URL location of the product picture.

Errors

For all API requests, there are also generic API authentication and user access restriction errors.
Response Code Error Code Message Description
0 - Invalid Category ID The category ID you provided could not be found.

Code Samples

Sample Category View Response XML

<?xml version="1.0"?>
<categories>
    <category>
        <id>4</id>
        <name>Things</name>
        <availability>1</availability>
        <description></description>
        <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-category4-148766936029.jpg</picture>
        <products>
            <product>
                <id>211</id>
                <name>Beach bags</name>
                <sku>123654</sku>
                <stock>92</stock>
                <price>20.00</price>
                <salePrice>15.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product211-149099048082.jpg</picture>
            </product>
            <product>
                <id>363</id>
                <name>Beach Chairs</name>
                <sku>369852</sku>
                <stock>-109</stock>
                <price>45.00</price>
                <salePrice>40.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product363-149098879352.jpg</picture>
            </product>
            <product>
                <id>375</id>
                <name>Beach Drink</name>
                <sku>7896</sku>
                <stock>-91</stock>
                <price>8.00</price>
                <salePrice>7.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product375-149098939534.jpg</picture>
            </product>
            <product>
                <id>380</id>
                <name>Beach Elephant</name>
                <sku>3698741</sku>
                <stock>-83</stock>
                <price>50.00</price>
                <salePrice>50.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product380-149099942759.jpg</picture>
            </product>
            <product>
                <id>24</id>
                <name>Beach Sand</name>
                <sku>BS001</sku>
                <stock>96</stock>
                <price>5.00</price>
                <salePrice>4.95</salePrice>
                <availability>1</availability>
                <availabilityOnline>0</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product24-148805251442.jpg</picture>
            </product>
            <product>
                <id>2324</id>
                <name>Bindings</name>
                <sku>978845</sku>
                <stock>1</stock>
                <price>400.00</price>
                <salePrice>399.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product2324-149695276561.png</picture>
            </product>
            <product>
                <id>2328</id>
                <name>Boots</name>
                <sku>94514114</sku>
                <stock>1</stock>
                <price>200.00</price>
                <salePrice>199.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product2328-149695475588.png</picture>
            </product>
            <product>
                <id>379</id>
                <name>Flip Flops</name>
                <sku>35775</sku>
                <stock>-109</stock>
                <price>6.00</price>
                <salePrice>5.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product379-149098984053.jpg</picture>
            </product>
            <product>
                <id>18</id>
                <name>freebirds</name>
                <sku>97814767716101</sku>
                <stock>1</stock>
                <price>150.00</price>
                <salePrice>111.11</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product18-148797471763.jpg</picture>
            </product>
            <product>
                <id>22</id>
                <name>Golden Retriever Collar</name>
                <sku>CM1</sku>
                <stock>154</stock>
                <price>50.00</price>
                <salePrice>25.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product22-148805154236.jpg</picture>
            </product>
            <product>
                <id>1775</id>
                <name>Installation Fee</name>
                <sku>INSTALL25</sku>
                <stock>0</stock>
                <price>25.00</price>
                <salePrice>25.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>0</availabilityOnline>
                <picture>https://team.myhelcim.com/images-generic/smHcmComm-NoPicture.png</picture>
            </product>
            <product>
                <id>1771</id>
                <name>Internet 15</name>
                <sku>INT15</sku>
                <stock>-1</stock>
                <price>65.00</price>
                <salePrice>65.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>0</availabilityOnline>
                <picture>https://team.myhelcim.com/images-generic/smHcmComm-NoPicture.png</picture>
            </product>
            <product>
                <id>26</id>
                <name>Little Pupper</name>
                <sku>5757</sku>
                <stock>-54</stock>
                <price>1000.00</price>
                <salePrice>1000.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product26-148805277890.jpg</picture>
            </product>
            <product>
                <id>11</id>
                <name>New Product</name>
                <sku>NP1</sku>
                <stock>2</stock>
                <price>100.00</price>
                <salePrice>100.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product11-148771738725.jpg</picture>
            </product>
            <product>
                <id>2068</id>
                <name>Notebook</name>
                <sku>78346787893</sku>
                <stock>-14</stock>
                <price>10.00</price>
                <salePrice>10.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images-generic/smHcmComm-NoPicture.png</picture>
            </product>
            <product>
                <id>359</id>
                <name>Pink Shell</name>
                <sku>123456</sku>
                <stock>-97</stock>
                <price>10.00</price>
                <salePrice>8.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product359-149098851089.jpg</picture>
            </product>
            <product>
                <id>351</id>
                <name>Sea Shells</name>
                <sku>987654</sku>
                <stock>-93</stock>
                <price>10.00</price>
                <salePrice>8.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>0</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product351-149098722477.jpg</picture>
            </product>
            <product>
                <id>62</id>
                <name>Stuff</name>
                <sku>IL3993</sku>
                <stock>-26</stock>
                <price>30.00</price>
                <salePrice>15.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product62-148866000685.jpg</picture>
            </product>
            <product>
                <id>61</id>
                <name>Super Fancy Thing Extreme</name>
                <sku>SFTE1</sku>
                <stock>-10</stock>
                <price>20.00</price>
                <salePrice>14.99</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product61-148865997618.jpg</picture>
            </product>
            <product>
                <id>367</id>
                <name>Thatched Umbrella</name>
                <sku>15996</sku>
                <stock>-108</stock>
                <price>90.00</price>
                <salePrice>79.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product367-149098912537.jpg</picture>
            </product>
            <product>
                <id>4</id>
                <name>Thing Number 1</name>
                <sku>SKU123</sku>
                <stock>-65</stock>
                <price>49.00</price>
                <salePrice>49.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product4-148766943380.jpg</picture>
            </product>
            <product>
                <id>2320</id>
                <name>Vega</name>
                <sku>465465456</sku>
                <stock>1</stock>
                <price>300.00</price>
                <salePrice>299.00</salePrice>
                <availability>1</availability>
                <availabilityOnline>1</availabilityOnline>
                <picture>https://team.myhelcim.com/images/9/smHelcimCommerce-product2320-149695197558.png</picture>
            </product>
        </products>
    </category>
</categories>

HTML Form Sample Code

<input type="hidden" name="accountId" value="YOUR-ACCOUNT-ID">
<input type="hidden" name="apiToken" value="YOUR-API-TOKEN">
<input type="hidden" name="action" value="categoryView">
<input type="hidden" name="categoryId" value="4">