SDK PHP v3.x

You are currently looking at the documentation of a previous version of Kuzzle. We strongly recommend that you use the latest version. You can also use the version selector in the top menu.

getUserRights #

Callback response example

Copied to clipboard!
    "controller": "my-controller",
    "action": "my-action",
    "index": "*",
    "collection": "*",
    "value": "allowed"
    "controller": "another-controller",
    "action": "*",
    "index": "my-index",
    "collection": "*",
    "value": "conditional"

Given a Kuzzle user id (kuid), retrieves the list of permissions granted to that user.

getUserRights(id, [options], callback) #

Arguments Type Description
kuid String Kuzzle User Unique Identifier
options JSON Object Optional parameters
callback function Callback handling the response

Options #

Option Type Description Default
queuable boolean Make this request queuable or not true

Callback Response #

Returns an array of objects.

Usage #

Copied to clipboard!
use \Kuzzle\Kuzzle;
$kuid = 'myUser';
$kuzzle = new Kuzzle('localhost');
try {
  $rights = $kuzzle->security()->getUserRights($kuid);
catch (ErrorException $e) {