edit-icon download-icon

CategoryTree

Last Updated: Feb 09, 2018

Description

The CategoryTree API retrieves a category tree.

Request parameters

Parameter Type Required or not Description
Action String Yes API of the action, system required parameter. Set this parameter to CategoryTree.

Return parameters

Name Type Description
CategoryTree String Category tree

Example

Request example

  1. http://mts.cn-hangzhou.aliyuncs.com/?Action=CategoryTree&<publiv parameter>

Return example

XML

  1. <CategoryTreeResponse>
  2. <CategoryTree>[{"CateId":3659747,"CateName":"Adult education","ParentId":-1,"Level":0,"SubcateList":[{"CateId":8102754,"CateName":"aaa","ParentId":3659747,"Level":1}]},{"CateId":4154805,"CateName":"this is a new cate","ParentId":-1,"Level":0},{"CateId":7503631,"CateName":"Not suitable for children","ParentId":-1,"Level":0}]</CategoryTree>
  3. <RequestId>A68615EA-0CF5-420E-AB19-ACFABF794745</RequestId>
  4. </CategoryTreeResponse>

JSON

  1. {
  2. "CategoryTree": "[{\"CateId\":3659747,\"CateName\":\"Adult education\",\"ParentId\":-1,\"Level\":0,\"SubcateList\":[{\"CateId\":8102754,\"CateName\":\"aaa\",\"ParentId\":3659747,\"Level\":1}]},{\"CateId\":4154805,\"CateName\":\"this is a new cate\",\"ParentId\":-1,\"Level\":0},{\"CateId\":7503631,\"CateName\":\"Not suitable for children\",\"ParentId\":-1,\"Level\":0}]",
  3. "RequestId": "B74DFDF2-3214-43FD-9051-4E1A1544CF92"
  4. }
Thank you! We've received your feedback.