On 06/22/2010 11:46 PM, Marius Dumitru Florea wrote:
> Hi Manish,
>
> On 06/23/2010 12:13 AM, xManish wrote:
>>
>> Hello,
>> I was able to create a wiki page through API. Now I wanted to restrict some
>> of the access rights for certain users to that particular wikipage through
>> REST Api. For example, How can we restrict a certain user from viewing a
>> particular wiki page through REST Api?
>>
>> In XWiki, this could be achieved by logging in as an administrator ->   Click
>> on a wiki Page ->   Click on the 'Access Rights' from 'Edit' dropdown menu ->
>> and then checkmarking the rights to specific user or group.
>>
>
>> How can we achieve this from REST Api?
>
> I don't know much about the REST API, but if you edit with the object
> editor the page you just set access rights on you'll see that it has an
> object of class XWiki.XWikiRights attached. In other words, access
> rights are controlled with XWiki objects. So you just have to
> add/update/remove objects of class XWiki.XWikiRights to your page with
> the REST API.
>
> Hope this helps,
> Marius
>
That's it.

The REST api only provide resources for manipulating pages an objects.
There are no resources for higher-level abstractions (excepts tags and 
comments)

So as long as what you want to do is achievable by page and object 
manipulation (like the most of the XWiki functionalities) you are able 
to use the REST api to do it.

Marius suggested the way to change the rights for a page and in a 
previous thread it was told how to create a new user.

It's clear that having explicit resources for common use cases would 
simplify things.

-Fabio

_______________________________________________
users mailing list
[email protected]
http://lists.xwiki.org/mailman/listinfo/users

Reply via email to