Categories

Endpoints for the currently authenticated user's categories.

List categories visible to this user

Request

Only available to Buyer Users.

Security
OAuth2(Required scopes: FullAccessShopper)
Query
depthstring

Indicates how deep down the hierarchy to return results. Valid values are a number of 1 or greater, or 'all'. Relative to ParentID if specified. Default is 1.

Default:"1"
catalogIDstring

The user’s default CatalogID will be used to return categories if you do not pass another CatalogID explicitly. Listing categories across multiple catalogs is not supported.

productIDstring

ID of the product.

searchstring

Word or phrase to search for.

searchOnArray of strings

Comma-delimited list of fields to search on.

Items Enum:"ID""Name""Description"
sortByArray of strings

Comma-delimited list of fields to sort by.

Items Enum:"ID""Name""!ID""!Name"
pageinteger

Page of results to return. When paginating through many items (> page 30), we recommend the "Last ID" method, as outlined in the Advanced Querying documentation.

Default:1
pageSizeinteger, <= 100

Number of results to return per page.

Default:20
filtersobject

An object or dictionary representing key/value pairs to apply as filters. Valid keys are top-level properties of the returned model or 'xp.???'

curl -i -X GET \
  'https://api.ordercloud.io/v1/me/categories?depth=1&catalogID=string&productID=string&search=string&searchOn=ID&sortBy=ID&page=1&pageSize=20&filters=' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

Only available to Buyer Users.

Bodyapplication/json
ItemsArray of objects(Category)
Example:
[ { "ID": "", "Name": "", "Description": "", "ListOrder": 1, "Active": false, "ParentID": "", "ChildCount": 0, "xp": {} } ]
Metaobject(Meta)
Response
{ "Items": [ { … } ], "Meta": { "Page": 0, "PageSize": 0, "TotalCount": 0, "TotalPages": 0, "ItemRange": [ … ], "NextPageKey": "string" } }