Skip to Content
Riferimento APICategorieOggetto categoria

L’oggetto categoria

L’oggetto categoria è un oggetto JSON con le seguenti proprietà:

{ "id": string, "title": string, "slug": string, "description": string, "workspace": string, "parent": object | string, // absent on a root category "path": [ { "id": string, "doc": string, // category id this crumb points at; sometimes absent on create "url": string, "label": string } ], "pathLabel": string, // breadcrumb titles joined with " / " "videoCount": number, "videoCountWithSubcategories": number, "createdAt": Date, "updatedAt": Date }

parent è la categoria padre. Con il depth predefinito è un oggetto categoria. Con depth=0 è un id. Una categoria radice omette parent. path è l’array breadcrumb. pathLabel unisce quei titoli con /. videoCount è il numero di video in questa categoria. videoCountWithSubcategories include i video nelle categorie figlie.

I campi scrivibili sono title (max 100), slug, description (max 2000) e parent (un id di categoria). Quando crei una categoria senza slug, viene generato da title.