Get category tree
Hierarchy of parent and children categories form a tree structure. This endpoint returns a tree of categories rooted in the category identified by id
or nodeId
.
Note:
1) If parent category does not exist in the system, you’ll get a 404 - Not found
error
2) If a child category does not exist for the given parent, you’ll get a success response but children
property will show a blank array.
Authorizations
S2S access token (JWT) from fabric Identity service (during Login)
Headers
The x-site-context
header is a JSON object that contains information about the source you wish to pull from. The mandatory account
is the 24 character identifier found in Copilot. The channel
(Sales channel ID), stage
(environment name), and date
attributes can be used to further narrow the scope of your data source.
Query Parameters
A 24-character system-generated ID of root category. Either id
or nodeId
must be specified.
Numeric category ID. Either id
or nodeId
must be specified.
Limits the size of the hierarchical category tree returned in the response. Depth of 0 means no children categories, attributes, or breadcrumbs, are included in the response. Unless depth is specified, entire category is returned up to the last set of categories (that have no more children categories).
Set true
to exclude attributes from both parent and children objects or false to include attributes in both parent and children details. <br /> The default setting false.
Set true
to exclude breadcrumbs from both parent and children objects or false to include breadcrumbs in both parent and children details. <br /> The default setting false.
Set true
to exclude item IDs from both parent and children objects or false to include item IDs in both parent and children details. <br /> The default setting false.
Attributes are included based on their exact, case-sensitive names. For example, if you specify the values as xyZ and Abc, the response will include these attributes in both parent and child objects.
Response
A 24-character system-generated category ID
Numeric category ID
Category name
Category type
PRIMARY
, ALTERNATE
true: Category is Active <br /> false: Category is Inactive <br /> Note: Inactive status is not applicable for Primary category.
Details of attributes belonging to this category
Children categories of this category
Time of category creation (UTC format)
Time when category was last updated (UTC format)
Was this page helpful?