Get list of product categories

The Get list of product categories method returns the list of product categories of the current reseller or any of its downstream resellers.

An API token of a manager is required for authorization. To get an API token via the Operator Control Panel, see Viewing and updating Manager's information

The manager's API token specified in an API request determines:

  • The role and access level of the manager, which determine the availability of a method.
  • The current reseller and downstream resellers accessible within a method.

GET {base_url}/api/v3/customer_store/resellers/{reseller_id}/product_categories

Arguments

Name

Parameter Type

Data type

Required/Optional

Description

X-Api-TokenheaderstringRequiredAPI token of a manager that performs the operation (see Viewing and updating Manager's information)
Content-TypeheaderstringRequiredMedia type of the request. Specify the following: application/vnd.api+json
AcceptheaderstringRequired

Supported media types of the answer. Specify the following: application/vnd.api+json

base_urlpathstringRequiredActivePlatform URL
reseller_idpathintegerRequiredID of the current reseller or any of its downstream resellers (see Viewing and updating Reseller general information)
per_pagequeryintegerOptionalPage navigation: number of elements per page
pagequeryintegerOptionalPage navigation: page number

Response model

NameData typeDescription
dataarray of objectsResponse data


id

string

Product category ID

typestringData type

attributesobjectProduct category information


created_at

string

Date and time of the product category creation


updated_at

string

Date and time when the product category was updated


keystringProduct category key


namestringProduct category name


descriptionstringDescription of the product category


priorityintegerProduct category priority


publicboolIndicates whether a product category is displayed in Reseller Store (see Main page and Catalog), Storefront of Customer Store (see Catalog page and Viewing Category pages list), and all related public products are available for ordering via the Customer Control Panel (see details in Creating a Product category)


logostringLink to the product category logo file

Request example

GET /api/v3/customer_store/resellers/1/product_categories
Host: https://test.activeplatform.com
Content-Type: application/vnd.api+json
X-Api-Token: vY5fwetestK3gJXZH5uHCw
Accept: application/vnd.api+json

Response example

{
    "data": [
        {
            "id": "5",
            "type": "product_categories",
            "attributes": {
                "created_at": "2017-07-11T10:58:21.037+03:00",
                "updated_at": "2017-07-13T13:01:24.431+03:00",
                "key": "default",
                "name": "default",
                "description": "",
                "priority": 1,
                "public": false,
                "logo": null
            }
        },
        {
            "id": "6",
            "type": "product_categories",
            "attributes": {
                "created_at": "2017-07-11T10:58:35.864+03:00",
                "updated_at": "2017-07-13T13:01:33.474+03:00",
                "key": "new",
                "name": "new",
                "description": "000",
                "priority": 2,
                "public": true,
                "logo": null
            }
        }
    ]
}