Returns the department tree.
If a customer key is given, the returned departments may vary according to custormer's group, otherwise according to the default customer group.
HTTP POST/api/v10/storefront.departments
{
"language" : "en", // language ( ISO code ) of the texts to return - string(2)
"fields" : [ "id", "ancestors", … ] // fields to return - string
}
{
"status" : "ok",
"departments" : [ {
"id" : 91, // identifier - int(1…)
"ancestors" : [ 12, 39, … ], // ancestor departments (id) - int(1…)
"name" : "Books", // name - string(0…60)
"description" : "", // description - string(0…65535)
"seo" : {
"title" : "", // title for SEO - string(0…255)
"description" : "" // description for SEO - string(0…255)
},
"canonicalURL" : "https://…", // canonical URL - string(10…)
"templateFile" : "department-shirts.html", // template file used for the site - string(15…255)
"departmentColumns" : 3, // number of columns in which the sub-departments are displayed - int(1…5)
"productsLayout" : { // layout of the products on the department page
"products" : 12, // number of products per page, can be 0, 12, 24, 36, 48 or 72 - int
"columns" : 4, // columns, can be 1, 2, 3, 4 or 6 - int
"sortOrder" : "-Price", // sort order, can be "Position", "Name", "-Name", "Price", "-Price" or "Date" - string
"imageSize" : "Optimal", // image size, can be "Optimal", Small", "Medium" or "Large" - string
"showDescription" : false // indicates if the description is displayed - bool
},
"smallImage" : { // small image (can be null)
"url" : "https://domain/path", // URL - string(53…255)
"width" : 150, // width in pixel - int(1…255)
"height" : 139 // height in pixel - int(1…255)
},
"largeImage" : { // large image (can be null)
"url" : "https://domain/path", // URL - string(53…255)
"width" : 150, // width in pixel - int(1…2500)
"height" : 139, // height in pixel - int(1…2500)
"align" : "Left" // alignment, can be "Left", "Center" or "Right" - string
},
"subdepartments" : [ … ] // subdepartments
}, … ]
}