Filter on XWikiGlobalRights object from REST API

Hello,

I am trying to list all XWikiGlobalRights object by using REST API like that :

http://localhost/xwiki/rest/wikis/xwiki/spaces/TEST/pages/WebPreferences/objects/XWiki.XWikiGlobalRights

Is there any ways to filter all those objects to only get those for a specific user ?

I have tried getting into all listed objects to get this information but it takes 2.5 seconds to do this for each object which is way too much.

Thanks.

I don’t think it’s possible using the objects resource. I think you’ll have to use the

/wikis/{wikiName}/query?q={query}&type={hql,xwql,lucene,solr}

resource. Check https://extensions.xwiki.org/xwiki/bin/view/Extension/Query+Module#HQueryLanguageExamples for examples of queries.