function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Daeus TangDaeus Tang 

[Issue] Retrieving Data Categories failure in REST API

User-added image

[
    {
        "errorCode": "INVALID_FIELD",
        "message": "Invalid sObjectName specified in query string. Only KnowledgeArticleVersion is supported."
    }
]
 


Hi, 
There's a new method introduced in v38 to retrieve data category. (https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/resources_knowledge_support_dcgroups.htm)

However, I keep getting the above error no matter what sObjectName I have provided to. Can anyone tell me what's wrong with that? 

 

Dmitry Loktevich 9Dmitry Loktevich 9
Hi, there is no issues, but you need to use your Category Group name instead of Doc:
services/data/v40.0/support/dataCategoryGroups/YourCategoryGroupName/dataCategories/All?sObjectName=KnowledgeArticleVersion