REST API to configure users & rights

Hi,

I am able to successfully create subwikis through the REST API provided by the /wikimanager resource.

Is there any way to configure the users and rights for subwikis through the REST API? Eg: The web UI allows you to “Prevent unregistered users from viewing pages, regardless of the page rights” - can this be set via REST?

The /wikimanager resource doesn’t seem to support that, and I don’t see anything here that might help: https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/Features/XWikiRESTfulAPI . Am I missing something? Is there an extension that might help?

thanks,
Leigh

yes. Rights are xobjects. See Setting Rights (Extension.Setting Rights) - XWiki

And “Prevent unregistered users from viewing pages, regardless of the page rights” is an xproperty of the XWiki.XWikiPreferences xclass AFAIK (authenticate_view).

Using https://www.xwiki.org/xwiki/bin/view/Documentation/UserGuide/Features/XWikiRESTfulAPI#HObjectresources to set xproperties of xobjects (/wikis/{wikiName}/spaces/{spaceName}[/spaces/{nestedSpaceName}]*/pages/{pageName}/objects/{className}/{objectNumber}/properties/{propertyName}[?minorRevision={true,false}] to be precise)