I have a directory in content database with some 200 XML documents and I want to add an additional permission to all the documents under this directory.
I tried using xdmp:document-add-permissions as xdmp:document-add-permissions("/dir/",(xdmp:permission("ml-reader", "read", "object")) but this does not seem to be working and giving below error message.
XDMP-DOCNOTFOUND: xdmp:document-add-permissions("/dir/", (json:object(<json:object xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" .../>), json:object(<json:object xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" .../>), json:object(<json:object xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" .../>), ...)) -- Document not found
Could someone please guide me on how to use this function to add permissions for directory?