BigCommerce
Catalog API
Category Trees

Catalog - Category Trees

The Catalog API manages products, categories, brands, bulk pricing rules, and more. To learn more about catalog resources, see the Catalog Overview.

Our Catalog Category Trees and their Categories endpoints are the more modern and performant counterparts to the Categories (deprecated) endpoints. Although the Category Trees endpoints and objects are designed to center an MSF-compatible, multi-tenant category tree architecture, the endpoints work just as well in a single storefront context and support batch requests. Use Catalog Trees Categories endpoints, instead of Categories (deprecated) endpoints.

The Category Trees endpoints let you get the Categories for a specific tree, and bulk create, bulk update, and bulk delete Categories. You can also bulk update the properties of Category Trees, which includes changing the channels to which a Tree is assigned.

The terms "category tree" and "catalog tree" are used interchangeably throughout the documentation.

To learn more about authenticating Catalog endpoints, locate the Authentication section at the top of each endpoint, then click Show Details.

Resources

Webhooks

Learn more about Category Tree webhook events.

Additional Catalog endpoints

Get All Category Trees

GET /catalog/trees

Request

Returns a list of Category Trees.

Authentication

  • X-Auth-Token in header - required

Parameters

  • store_hash in path - string
  • Accept in header with default of application/json - string - required

    The MIME type of the response body.

  • id:in in query - string
  • channel_id:in in query - string

example

Response

List of category trees.

Body

object | application/json
  • data
    array[object]

  • meta
    object

example

Upsert Category Trees

PUT /catalog/trees

Request

Upserts Category Trees.

This single endpoint updates and creates category trees. If a tree object contains an ID, it is processed as an update operation using that ID. If you do not provide an ID, a new tree is created. The category tree name field is required to create trees, but is not required on the update.

Usage Notes

  • channel_id is required to create a Category Tree. You can assign one channel_id to one category tree.

Authentication

  • X-Auth-Token in header - required

Parameters

  • store_hash in path - string
  • Content-Type in header with default of application/json - string - required

    The MIME type of the request body.

Body

array | application/json
  • id
    integer

  • name
    string

    >= 1 characters<= 255 characters
  • channels
    array[integer]

example

Response

Created a category tree.

Body

object | application/json
  • data
    array[object]

  • meta
    object

    Response metadata.

example

Delete Category Trees

DELETE /catalog/trees

Request

Deletes Category Trees. A filter must be supplied with the endpoint.

Authentication

  • X-Auth-Token in header - required

Parameters

  • store_hash in path - string
  • Accept in header with default of application/json - string - required

    The MIME type of the response body.

  • id:in in query - string

example

Response

Deleted

Get a Category Tree

GET /catalog/trees/{tree_id}/categories

Request

Returns a Category Tree.

Authentication

  • X-Auth-Token in header - required

Parameters

  • store_hash in path - string
  • Accept in header with default of application/json - string - required

    The MIME type of the response body.

  • tree_id in path - string - required

    The ID of the Category Tree.

  • depth in query - integer

    Max depth for a tree of categories.

example

Response

Categories tree

Body

object | application/json
  • data
    array[object]

  • meta
    object

    Response metadata.

example

Did you find what you were looking for?