cancel
Showing results for 
Search instead for 
Did you mean: 

Do we have or how can we implement API for getting the "like" of the content or post "Like" to content?

tanmaysalve
Champ on-the-rise
Champ on-the-rise

We are creating custom application, in which we want documents or our images to be "liked" using the like button.

Is here any exposed API of alfresco or share application that we can use in our custom application?

1 ACCEPTED ANSWER

afaust
Legendary Innovator
Legendary Innovator

The Java API of Alfresco includes the RatingService with which you can access the "Likes" of a content item and also add/remove to them. You cannot call it from JavaScript-backed web scripts in standard Alfresco unfortunately, so you have to use a Java-backed web script.

View answer in original post

2 REPLIES 2

afaust
Legendary Innovator
Legendary Innovator

The Java API of Alfresco includes the RatingService with which you can access the "Likes" of a content item and also add/remove to them. You cannot call it from JavaScript-backed web scripts in standard Alfresco unfortunately, so you have to use a Java-backed web script.

janv
Elite Collaborator
Elite Collaborator

Hi,

In addition to Axel's reply, you might also consider using the public Node Ratings REST API (Alfresco Content Services REST API Explorer) with "likes" rating scheme id.

IIRC, this is available since Alfresco 4.2 (to 5.2) and is used by our current iOS & Android mobile clients. You can look at how they use the API or refer to some tests for some example usage.

Regards,

Jan