Skip to main content
Published: August 07 2006, 11:33:00 PMUpdated: November 28 2020, 2:22:08 PM

Can I add multiple store categories using SetStoreCategories?

Yes, you can add multiple Store Categories in a single call to SetStoreCategories. However, you can only add categories of the same level, that is, with the same ParentID together in a single call. You cannot use the ChildCategory node, to add multiple levels of categories within a single SetStoreCategories call.

For example, if you are adding 3 levels of categories, you need to add each level, individually. Additionally, only a single group of child categories with the same ParentCategoryID can be added at the same time.

When callling SetStoreCategories, do not specify a CategoryID, as this value is internally assigned by eBay. Only specify the DestinationParentCategoryID, and specify the Name and Order for each CustomCategory. After calling SetStoreCategories, you will need to call GetStore, to retrieve the new Category IDs, before proceeding to create child categories.

A sample SetStoreCategoriesRequest, setting 2 categories, is shown below.

<?xml version="1.0" encoding="utf-8"?>
<SetStoreCategoriesRequest xmlns="urn:ebay:apis:eBLBaseComponents">
<DetailLevel>ReturnAll</DetailLevel>
<Version>455</Version>
<Action>Add</Action>
<ItemDestinationCategoryID>0</ItemDestinationCategoryID>
<DestinationParentCategoryID>5658</DestinationParentCategoryID>
<StoreCategories>
<CustomCategory>
<Name>Level 2a</Name>
<Order>0</Order>
</CustomCategory>
<CustomCategory>
<Name>Level 2b</Name>
<Order>1</Order>
</CustomCategory>
</StoreCategories>
<RequesterCredentials>
<eBayAuthToken>x</eBayAuthToken>
</RequesterCredentials>
</SetStoreCategoriesRequest>

How well did this answer your question?
Answers others found helpful