SDK
SDK Dart Null Safety v3.x
2

getUserRights #

Gets the detailed rights granted to a user.


Future<List<dynamic>> getUserRights(String id)

PropertyTypeDescription
id
String
User id

Return #

A List of objects. Each object is a security right granted or denied to the user:

  • controller: impacted controller
  • action: impacted controller action
  • index: index name
  • collection: collection name
  • value: tell if access if allowed or denied. If closures have been configured on the detailed scope, the value is conditional.

Usage #

final result = await kuzzle.security.getUserRights('john.doe');
/*
[ { controller: '*',
  action: '*',
  index: '*',
  collection: '*',
  value: 'allowed' } ]
*/