This method returns a list of the categories available to the API.
http://api.shopstylecollective.com/api/v2/categories?pid=YOUR_API_KEY
cat | The ID of the category to use as the starting point. By default, the global root of the category tree is used |
depth | The number of levels from the root to include in the response. By default all the levels are included. |
RESPONSE
A list of all categories, with id, name, and parent id.
SAMPLE JSON
{ "metadata": { "root": { "id": "clothes-shoes-and-jewelry", "name": "Clothes and Shoes", "shortName": "All Categories", "localizedId": "clothes-shoes-and-jewelry", "hasHeelHeightFilter": false, "hasSizeFilter": false, "hasColorFilter": true, "numId": 1 }, "maxDepth": 20 }, "categories": [ { "id": "women", "name": "Women's Fashion", "shortName": "Women", "localizedId": "women", "parentId": "clothes-shoes-and-jewelry", "hasHeelHeightFilter": false, "hasSizeFilter": false, "hasColorFilter": true, "numId": 2, "image": "http:\/\/resources.shopstyle.com\/pim\/d7\/d7\/d7d757b5a0bfbd4f480e095a137e52aa_smallmed.jpg" } ] }
SAMPLE XML
<List> <metadata> <root> <id>clothes-shoes-and-jewelry</id> <name>Clothes and Shoes</name> <shortName>All Categories</shortName> <localizedId>clothes-shoes-and-jewelry</localizedId> <hasHeelHeightFilter>false</hasHeelHeightFilter> <hasSizeFilter>false</hasSizeFilter> <hasColorFilter>true</hasColorFilter> <numId>1</numId> </root> <maxDepth>20</maxDepth> </metadata> <categories> <category> <id>women</id> <name>Women's Fashion</name> <shortName>Women</shortName> <localizedId>women</localizedId> <parentId>clothes-shoes-and-jewelry</parentId> <hasHeelHeightFilter>false</hasHeelHeightFilter> <hasSizeFilter>false</hasSizeFilter> <hasColorFilter>true</hasColorFilter> <numId>2</numId> <image>http://resources.shopstyle.com/pim/d7/d7/d7d757b5a0bfbd4f480e095a137e52aa_smallmed.jpg</image> </category> </categories> </List>