This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.
Retrieves a list of up to 1,000 categories, given the provided filtering, sorting, and cursor paging.
Pass supported values to the fields
array in the request to include those fields in the response.
For field support for filters and sorting, see Categories: Supported Filters and Sorting.
To learn about working with Query endpoints, see API Query Language, and Sorting and Paging.
Query options.
Category tree reference details.
Whether to return non-visible categories.
Default: false
(only visible categories are returned)
Fields to include in the response.
List of categories.
Paging metadata.
Query categories with filter by ids and sort by creation date
curl -X POST \
'https://www.wixapis.com/categories/v1/categories/query' \
-H 'Content-Type: application/json' \
-H 'Authorization: <AUTH>' \
-d '{
"query": {
"filter": {
"id": {
"$in": [
"bbd52b32-21d2-4dbe-bfc5-d320f93f8911",
"df55a225-a5a6-42da-a4f9-7c805c5b3188"
]
}
}
},
"sort": [{"field_name": "createdDate", "order": "DESC"}],
"treeReference": {
"appNamespace": "@wix/stores",
"treeKey": null
},
"returnNonVisibleCategories": false
}'
{
"categories": [
{
"id": "bbd52b32-21d2-4dbe-bfc5-d320f93f8911",
"revision": "3",
"createdDate": "2024-06-26T09:41:27.160Z",
"updatedDate": "2024-06-26T11:10:35.577Z",
"name": "Drink Containers",
"itemCounter": 0,
"totalItemCounter": 0,
"visible": true,
"parentCategory": {
"index": 8
},
"slug": "drinkware-2",
"treeReference": {
"appNamespace": "@wix/stores"
}
},
{
"id": "df55a225-a5a6-42da-a4f9-7c805c5b3188",
"revision": "2",
"createdDate": "2024-08-05T09:16:17.442Z",
"updatedDate": "2024-08-18T10:07:17.617Z",
"name": "Cups",
"itemCounter": 0,
"totalItemCounter": 0,
"visible": true,
"parentCategory": {
"id": "bbd52b32-21d2-4dbe-bfc5-d320f93f8911",
"index": 2
},
"slug": "skincare",
"treeReference": {
"appNamespace": "@wix/stores"
}
}
],
"pagingMetadata": {
"count": 2,
"cursors": {}
}
}
This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.