Get category navigation tree
GET
/merchants/{merchantCode}/pathCategories
const url = 'https://catalog.shopgate.io/v1/merchants/example/pathCategories?getOriginalImageUrls=false';const options = {method: 'GET'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://catalog.shopgate.io/v1/merchants/example/pathCategories?getOriginalImageUrls=false'Get category navigation tree. Returns root categories with empty children when no categoryCode is provided. When categoryCode is provided, expands every ancestor on the path from root to target (showing their siblings) and loads the target’s immediate children.
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”merchantCode
required
string
Query Parameters
Section titled “Query Parameters”categoryCode
string
Optional category code to expand path to
localeCode
string
Locale code to change the language of the name, descriptions, properties and media
catalogCode
string
getOriginalImageUrls
boolean
Responses
Section titled “Responses”Returns category tree.
Media typeapplication/json
object
categories
Array<object>
object
code
Human readable code of the entity
string
parentCategoryCode
Human readable code of the entity
string
image
null | string
name
string
url
Url of the category in the desktop shop
null | string
description
Description which is shown to the customer
null | string
externalUpdateDate
null | string format: date-time
status
string
path
Category path based on the category code of the parents
Array<string>
sequenceId
By default this creates an ascending order of categories meaning 0 is the first.
integer
productCount
integer
categoryCount
integer
children
Array<object> recursive
Example
{ "categories": [ { "code": "clothes", "parentCategoryCode": null, "name": "Clothes", "description": "This category contains clothing", "image": null, "url": "https://awesomeShop.com/c/clothes", "externalUpdateDate": "2019-01-12T00:00:00.114Z", "status": "active", "path": [], "sequenceId": 0, "productCount": 0, "categoryCount": 2, "children": [] } ]}Merchant or category not found
Media typeapplication/json
object
statusCode
number
code
required
string
message
required
string
Example
{ "code": "NotFound", "message": "Merchant not found"}
