Fetch categories

Categories are used for organising products in the product library. Categories can be created by merchants from the user interface. Alternatively, categories can be managed programmatically through the Product Library API.

Prerequisites

  • Authorisation setup with the correct scope, and a valid authorisation token. See Product library concept.
  • Required access right: READ:PRODUCT.

Fetch all categories

This request returns all available categories in the product library.

1
GET /organizations/self/categories/v2

Example: This example retrieves all categories available in the product library for a specific merchant's organisation. The organisation UUID is provided through the access token in the request header.

Response

1
{
2
"categories": [
3
{
4
"uuid": "eeee19e0-4f24-11ea-b7fa-7d966b08f680",
5
"name": "Shirts"
6
},
7
{
8
"uuid": "b1643140-516d-11ea-af5d-edbd833b37a9",
9
"name": "Fashion"
10
},
11
{
12
"uuid": "bb313b10-8a1a-11ea-9e3b-c100d28de5fe",
13
"name": "T Shirt"
14
},
15
{
16
"uuid": "bcd17d90-8a1a-11ea-a0cb-b51adc2a1a07",
17
"name": "Jumpers"
18
},
19
{
20
"uuid": "a5cc8f20-b6f9-11ea-8d3f-8f7e2cb61adb",
21
"name": "Shoes"
22
},
23
{
24
"uuid": "3287dc55-6aba-4a07-a5c6-cd50b13adbb5",
25
"name": "Tops"
26
},
27
{
28
"uuid": "76646c1e-fed4-4565-aa45-413c9fea08ef",
29
"name": "Boots"
30
},
31
]