Data Category Detail

Gets data category details and the child categories by a given category. This resource can be used in API version 38.0 and later.

Salesforce Knowledge must be enabled in your organization. Use the language code format used in Which Languages Does Salesforce Support?.

URI

/services/data/vXX.X/support/dataCategoryGroups/group/dataCategories/category

Method

GET

Formats

JSON, XML

Authentication

Authorization: Bearer token

HTTP Headers

Accept: Optional. Can be either application/json or application/xml.

Accept-language: Optional. Language to translate the categories. Any ISO-639 language abbreviation, and an ISO-3166 country code subtag in the HTTP Accept-Language header. Only one language accepted. If no language specified, the non-translated labels are returned.

Input

string sObjectName: Required. KnowledgeArticleVersion only.

Output

Details of the category and a list of child categories (name, label, etc.).

Data Category Detail

Used for situations where the hierarchical representation of data categories is important. The child property contains a list of child data categories.

1{
2    "name": String, // the unique name of the category
3    "label":  String, // returns the translated version if it is available
4    "url":  URL,
5    "childCategories": [ Data Category Summary, ....],
6}

If the category isn't visible to the current user the return is empty.

Note

Example Request

1curl https://MyDomainName.my.salesforce.com/services/data/v66.0/support/dataCategoryGroups/Doc/dataCategories/All?sObjectName=KnowledgeArticleVersion -H "Authorization: Bearer token"

Example Response Body

1{
2  "childCategories" : [ {
3    "childCategories" : null,
4    "label" : "Help",
5    "name" : "Help",
6    "url" : "/services/data/v66.0/support/dataCategoryGroups/Doc/dataCategories/Help?sObjectName=KnowledgeArticleVersion"
7  }, {
8    "childCategories" : null,
9    "label" : "QA",
10    "name" : "QA",
11    "url" : "/services/data/v66.0/support/dataCategoryGroups/Doc/dataCategories/QA?sObjectName=KnowledgeArticleVersion"
12  } ],
13  "label" : "All",
14  "name" : "All",
15  "url" : "/services/data/v66.0/support/dataCategoryGroups/Doc/dataCategories/All?sObjectName=KnowledgeArticleVersion"
16}