@Consumes(value="application/json") @Produces(value="application/json") @Path(value="users") public class UserAdminResource extends Object
Constructor and Description |
---|
UserAdminResource(UsersMembershipController usersMembershipController,
UsersSearchController usersSearchController) |
Modifier and Type | Method and Description |
---|---|
javax.ws.rs.core.Response |
addUserToGroups(DirectoryEntityId userId,
GroupIdentifiersEntityList groups)
Adds single user to multiple groups placed in the same directory
|
javax.ws.rs.core.Response |
removeUserFromGroups(DirectoryEntityId userId,
GroupIdentifiersEntityList groups)
Removes multiple users from single group placed in the same directory
|
javax.ws.rs.core.Response |
searchUsers(RestPageRequest pageRequest,
UserSearchParams params)
Returns users that can be assigned by to any group administered by the current user.
|
public UserAdminResource(UsersMembershipController usersMembershipController, UsersSearchController usersSearchController)
@POST @Path(value="/{userId}/groups") public javax.ws.rs.core.Response addUserToGroups(@PathParam(value="userId") DirectoryEntityId userId, GroupIdentifiersEntityList groups) throws UserNotFoundException, DirectoryNotFoundException, OperationFailedException, FeatureInaccessibleException
userId
- User's unique identifiergroups
- Entity with group's unique identifiersUserNotFoundException
DirectoryNotFoundException
OperationFailedException
FeatureInaccessibleException
@DELETE @Path(value="/{userId}/groups") public javax.ws.rs.core.Response removeUserFromGroups(@PathParam(value="userId") DirectoryEntityId userId, GroupIdentifiersEntityList groups) throws UserNotFoundException, DirectoryNotFoundException, OperationFailedException, FeatureInaccessibleException
userId
- User's unique identifiergroups
- Entity with group's unique identifiersUserNotFoundException
DirectoryNotFoundException
OperationFailedException
FeatureInaccessibleException
@Path(value="/search") @POST public javax.ws.rs.core.Response searchUsers(@Context RestPageRequest pageRequest, UserSearchParams params) throws DirectoryNotFoundException, OperationFailedException, IllegalAccessException, UserNotFoundException, FeatureInaccessibleException
pageRequest
- starting index and maximum number of results returned from the searchparams
- search criteriaDirectoryNotFoundException
OperationFailedException
IllegalAccessException
UserNotFoundException
FeatureInaccessibleException
Copyright © 2021 Atlassian. All rights reserved.