Posts

Showing posts with the label Entities List

Get a List of all Content Entities of the Same Content Type in Sitecore Content Hub

Image
While working on the Content Hub project I received the requirement to get all the Content Entities of a specific Content Type from the Content Hub. For instance, if your Content Hub contains various types of content entities such as a Blog, Article, and News type and there are multiple entities of each content type. Here I am taking an example of retrieving all the Content Entities of the Blog type. To get the list of all the content types, you can use  Web Client SDK , there is a method to retrieve the single entity using the  Get entities method. Solution: 1. Create a sample console/web application in Visual Studio and add a reference to the Web Client SDK NuGet package (Stylelabs.M.Sdk.WebClient) to your project.  2. Before beginning to write the logic, you should have the Parent ID of the Content Entities that represent the ID of the Content-Type. To find the Content Type ID or Parent ID of a content entity from the Conten...

Custom Button on Content Details Page in Sitecore Content Hub

Image
In this blog post, I will discuss how to add a custom button on the Content Details page in the Sitecore Content Hub. To understand the use case of this feature, suppose you have a client requirement to perform any business logic on that particular entity for instance updating field values or applying auto-tagging, etc. 1. Go to the pages option from the Manage button in the top right corner of the Home page. 2. In the pages, search for the Content Details page: 3. On the Content Details page, locate the operations/entity operations, in the Header Zone (Right). By default, it can be disabled so enable it by system settings. 4. After that, it will be enabled, and click on the Operation/Entity Operations it navigates to the entity operation component. 5. We will add a new operation, click on the Add operation button on the top left and find the custom External Action. 6. Name it as per your requirement, I am naming it AI Tagging, to change the ...