🚀New lib version v0.0.12 [CI SKIP]
All checks were successful
continuous-integration/drone Build is passing
All checks were successful
continuous-integration/drone Build is passing
This commit is contained in:
20
dist/services/UserService.js
vendored
20
dist/services/UserService.js
vendored
@@ -5,7 +5,7 @@ const request_1 = require("../core/request");
|
||||
class UserService {
|
||||
/**
|
||||
* Get all
|
||||
* Lists all users. <br> This includes their groups and permissions directly granted to them (if existing/associated).
|
||||
* Lists all users. <br> This includes their groups and permissions granted to them.
|
||||
* @returns ResponseUser
|
||||
* @throws ApiError
|
||||
*/
|
||||
@@ -20,7 +20,7 @@ class UserService {
|
||||
* Post
|
||||
* Create a new user. <br> If you want to grant permissions to the user you have to create them seperately by posting to /api/permissions after creating the user.
|
||||
* @param requestBody CreateUser
|
||||
* @returns any
|
||||
* @returns ResponseUser
|
||||
* @throws ApiError
|
||||
*/
|
||||
static async userControllerPost(requestBody) {
|
||||
@@ -33,7 +33,7 @@ class UserService {
|
||||
}
|
||||
/**
|
||||
* Get one
|
||||
* Lists all information about the user whose id got provided. <br> Please remember that only permissions granted directly to the user will show up here, not permissions inherited from groups.
|
||||
* Lists all information about the user whose id got provided. <br> Please remember that all permissions granted to the user will show up here.
|
||||
* @param id
|
||||
* @returns ResponseUser
|
||||
* @throws ApiError
|
||||
@@ -80,5 +80,19 @@ class UserService {
|
||||
});
|
||||
return result.body;
|
||||
}
|
||||
/**
|
||||
* Get permissions
|
||||
* Lists all permissions granted to the user sorted into directly granted and inherited as permission response objects.
|
||||
* @param id
|
||||
* @returns ResponseUser
|
||||
* @throws ApiError
|
||||
*/
|
||||
static async userControllerGetPermissions(id) {
|
||||
const result = await request_1.request({
|
||||
method: 'GET',
|
||||
path: `/api/users/${id}/permissions`,
|
||||
});
|
||||
return result.body;
|
||||
}
|
||||
}
|
||||
exports.UserService = UserService;
|
||||
|
||||
Reference in New Issue
Block a user