Hello,
i would like to know, how can i get a list of favorites files from specific folder, for example i have folder in Sites/Home/documentLibrary/Documents and i need to get only favorites files via API aka
/alfresco/api/-default-/public/alfresco/versions/1/node/{nodeId}/children
Can i specify where query or use different API? Thanks
This is working for me:
curl --location --request GET \
'http://127.0.0.1:8080/alfresco/api/-default-/public/alfresco/versions/1/nodes/-root-/children?skipCount=0&maxItems=100&include=isFavorite' \ --header 'Content-Type: application/json' \ --header 'Authorization: Basic YWRtaW46YWRtaW4='
What Alfresco version are you using?
Ok sorry, i thought ONLY favorite files. I'm using ACS 6.2
Add "&where=(isFile%3Dtrue)" the the URL I gave you before and it will return files with the "isFavorite" property.
Sorry, my english is maybe not good, but my goal is not to get property, but to get ONLY favorite files. For example, i need to show last 25 favorite files sorted by createdAt in folder sites/Test/documentLibrary/Documents and that what you are describing will get all files but with property isFavorite and what i need to do if i need to show last 25 favorite files? I have to paging and count isFavorite. And if the user would like see next page, next 25 favorite files, what i need to do? The same process.
Therefore i'm looking for possibility how to get ONLY favorite files via API children or Search API.
Thanks
Ask for and offer help to other Alfresco Content Services Users and members of the Alfresco team.
Related links:
By using this site, you are agreeing to allow us to collect and use cookies as outlined in Alfresco’s Cookie Statement and Terms of Use (and you have a legitimate interest in Alfresco and our products, authorizing us to contact you in such methods). If you are not ok with these terms, please do not use this website.