Skip to main content
Naga_Seran
Level 2
Jul 20, 2023 1:28 PM UTC
Question

AEM Asset API not updating jcr:lastModified and jcr:lastModifiedBy of content fragment

Hi All, We have an internal tool to update content fragment using Asset API. We found that jcr:lastModified and jcr:lastModifiedBy information is not updating while making updates to content fragment using AEM asset api. We tried to add modifiedBy & modified properties in request body but no luck. Could you please advise on this method: 'put', url: '/api/assets/', data: '{"properties":{"modifiedBy":"admin","modified":"","contentFragment":true,"elementsOrder":["state","plan"],"elements":{"state":{":type":"string","title":"State","multiValue":true,"dataType":"string","value":["NY"]},"plan":{":type":"string","title":"Plan","multiValue":true,"dataType":"string","value":["1234"]}}}}', Thanks, Seran
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

5 replies

DPrakashRaj
Community Advisor
Community Advisor
Jul 21, 2023 12:41 AM UTC

Modified and modified by property are protected property in aem. These properties values are maintained by aem and can’t be modified by any script or even via crx/de

Translate
Jul 21, 2023 6:27 AM UTC

Thank You for your reply PraksahRaj. Do we have a way to get these values updated when an update happened to content fragment from AEM asset api

Translate
kautuk_sahni
Level 9
Oct 18, 2024 10:24 AM UTC

@naga_seran If you have successfully found a solution on your own, we kindly ask that you share it with the community for future reference and mark it as the correct answer.

Translate
Kautuk Sahni