get
https://{subdomain}.myshoplaza.com/openapi/2025-06/categories
List all categories in the shop
Requiresread_productaccess scope. More access scope
The List Categories API retrieve a list of all product categories in the shop.
This API is especially useful for:
- Fetching a complete hierarchy of product categories.
- Filtering categories by parent ID or specific category IDs.
- Building navigation menus or category-based product filters.
Request Parameters
Public Request Parameters
Path Parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
pid | string | No | Parent category ID to filter child categories | pid=12345 |
ids | array of strings | No | Specific category IDs to retrieve | ids=["1001","1002"] |
Response Explanation
Public Response Parameters
Successful Response
| Parameter | Type | Example | Description |
|---|---|---|---|
code | string | "success" | Status code of the API response |
message | string | "Categories retrieved successfully" | Descriptive message about the response |
data.categories | array of objects | - | Array containing all category objects |
data.categories.id | string | "1001" | Unique identifier for the category |
data.categories.name | string | "Electronics" | Display name of the category |
data.categories.pid | string | "12345" | Parent category ID (empty for root categories) |
data.categories.level | int32 | 2 | Depth level in category hierarchy |
data.categories.position | int32 | 3 | Sort order position within its level |
data.categories.path | string | "1.12.1001" | Full hierarchical path of the category |
data.categories.google_id | int32 | 123456789 | Corresponding Google product category ID |
Error Response
| Field | Type | Example | Description |
|---|---|---|---|
code | string | InvalidParameter | Error http message |
message | string | `` | Error message |
