
xdmp.documentAddPermissions( uri as String, permissions as Object[] ) as null
Adds the given permissions to the given document or directory. The user must have update or insert permissions on the document.
| Parameters | |
|---|---|
| uri | The document URI. |
| permissions | Permission objects. |
declareUpdate();
xdmp.documentAddPermissions(
"/example.json", [
xdmp.permission("development", "update"),
xdmp.permission("qa", "read")
]);