Categories tools

list_categories

Lists the categories in your product taxonomy, the structure that powers category-page navigation. For example, a category path might read Home > Clothing > Shoes.

The response gives you every category with its IDs, display name, full path, and domain key. Use site_group_id=-1, the default, for account-level categories, or a specific site group ID for site-level categories. For rule-based categories whose membership is set by conditions, use list_dynamic_categories.

Request parameters

NameTypeRequired?Description
site_group_idstrNoThe site group ID. Use -1 for account-level categories, the default, or a specific site group ID for site-level categories.

Response parameters

The tool returns a CategoriesResponse object with the following parameters:

ParameterTypeDescription
successboolWhether the request succeeded.
datalist[CategoryItem]The categories in the taxonomy.
countintThe total number of categories.
errorstr | nullError message if the request failed.

The CategoryItem object has the following fields:

FieldTypeDescription
idstr | nullThe internal category record ID.
accountIdstr | nullThe account this category belongs to.
siteIdint | nullThe site this category belongs to.
categoryIdstr | nullThe category ID used in search queries.
categoryPathsstr | nullThe full category path, for example Home/Clothing/Shoes.
displayNamestr | nullThe category's display name.
domainKeystr | nullThe domain key this category belongs to.
originalCategoryIdstr | nullThe original category ID from the catalog feed.
extendedCategoryPathlist[ExtendedCategoryPath]The structured category path segments.

The ExtendedCategoryPath object has the following fields:

FieldTypeDescription
idstr | nullThe category path segment ID.
namestr | nullThe category path segment display name.

list_dynamic_categories

Lists the dynamic categories in an account. Dynamic categories are rule-based: their product membership comes from conditions rather than manual curation, so products move in and out as they match the rules.

The response gives you paginated summaries with each category's name, associated catalog, conditions, and sync status. Use get_dynamic_category when you need the full definition of one category. For the manually curated taxonomy, use list_categories.

Request parameters

NameTypeRequired?Description
account_namestr | nullNoThe account name. Required if you have access to more than one account.
site_group_idstr | int | nullNoA site group ID or site name. Defaults to the account level (-1).
pageintNoThe page number, zero-based. Defaults to 0.
limitintNoThe number of results per page. Defaults to 10.
sort_bystrNoThe field to sort by. Defaults to lastModifiedAt.
sort_orderstrNoThe sort direction, ASC or DESC. Defaults to DESC.
querystr | nullNoA search term to filter categories by name.
catalog_namestr | nullNoA catalog name to filter by.

Response parameters

The tool returns a DynamicCategoriesResponse object with the following parameters:

ParameterTypeDescription
successboolWhether the request succeeded.
datalist[DynamicCategorySummary]The dynamic categories in the account.
errorstr | nullError message if the request failed.

The DynamicCategorySummary object has the following fields:

FieldTypeDescription
idintThe dynamic category's unique ID.
categoryIdstr | nullThe category identifier.
categoryNamestr | nullThe category's display name.
categoryNotestr | nullAn optional note.
catalogNamestr | nullThe associated catalog name.
merchantIdint | nullThe merchant this category belongs to.
groupIdint | nullThe group ID used to group dynamic categories.
createdAtint | nullUnix timestamp in milliseconds of when the category was created.
createdBystr | nullThe user who created the category.
lastModifiedAtint | nullUnix timestamp in milliseconds of the last modification.
lastModifiedBystr | nullThe user who last modified the category.
syncedAtint | nullUnix timestamp in milliseconds of the last sync.
toBeDeletedbool | nullWhether the category is marked for deletion.
productIdslist[str]The product IDs included in this category.
conditionConfigany | nullThe condition rules, as a query and filter configuration.
pathslist[list[CategoryPathNode]] | nullThe category hierarchy paths.

get_dynamic_category

Returns the full definition of a single dynamic category, including its condition rules, product IDs, hierarchy paths, catalog association, and sync status. Use list_dynamic_categories first to find the category ID you want.

Request parameters

NameTypeRequired?Description
category_idintYesThe category ID returned by list_dynamic_categories.
account_namestr | nullNoThe account name. Required if you have access to more than one account.
site_group_idstr | int | nullNoA site group ID or site name. Defaults to the account level (-1).

Response parameters

The tool returns a DynamicCategoryResponse object with the following parameters:

ParameterTypeDescription
successboolWhether the request succeeded.
dataDynamicCategorySummary | nullThe full dynamic category record.
errorstr | nullError message if the request failed.

The DynamicCategorySummary object has the fields documented under list_dynamic_categories.

Each entry in the paths field is a list of CategoryPathNode objects, which have the following fields:

FieldTypeDescription
idstr | nullThe category path node ID.
namestr | nullThe category path node display name.

© Bloomreach, Inc. All rights reserved.