Class GroupAdminResource
java.lang.Object
com.atlassian.bamboo.plugins.rest.user.GroupAdminResource
@Path("admin/groups")
@Consumes("application/json")
@Produces("application/json")
public class GroupAdminResource
extends Object
REST resource to manage groups in Bamboo.
- Since:
- 6.6
-
Constructor Summary
ConstructorDescriptionGroupAdminResource
(BambooPermissionManager bambooPermissionManager, BambooUserManager userManager, com.atlassian.sal.api.transaction.TransactionTemplate transactionTemplate, com.atlassian.struts.TextProvider textProvider, PaginationService paginationService) -
Method Summary
Modifier and TypeMethodDescriptionjavax.ws.rs.core.Response
addUsersToGroup
(String groupName, List<String> usersToAdd) javax.ws.rs.core.Response
createGroup
(RestGroup group) javax.ws.rs.core.Response
deleteGroup
(String groupName) findUsersInGroup
(String groupName, String filter, PageRequest pageRequest, ExpansionParam expansion, javax.ws.rs.core.UriInfo uriInfo) findUsersNotInGroup
(String groupName, String filter, PageRequest pageRequest, ExpansionParam expansion, javax.ws.rs.core.UriInfo uriInfo) getGroups
(String filter, PageRequest pageRequest, ExpansionParam expansion, javax.ws.rs.core.UriInfo uriInfo) javax.ws.rs.core.Response
removeUsersFromGroup
(String groupName, List<String> usersToRemove)
-
Constructor Details
-
GroupAdminResource
@Inject public GroupAdminResource(BambooPermissionManager bambooPermissionManager, BambooUserManager userManager, com.atlassian.sal.api.transaction.TransactionTemplate transactionTemplate, com.atlassian.struts.TextProvider textProvider, PaginationService paginationService)
-
-
Method Details
-
getGroups
@GET public RestPageModel<RestGroup> getGroups(@QueryParam("filter") @DefaultValue("") String filter, @BeanParam PageRequest pageRequest, @BeanParam ExpansionParam expansion, @Context javax.ws.rs.core.UriInfo uriInfo) throws com.atlassian.user.EntityException - Throws:
com.atlassian.user.EntityException
-
createGroup
- Throws:
WebValidationException
-
deleteGroup
@DELETE @Path("{name : (.+)?}") public javax.ws.rs.core.Response deleteGroup(@PathParam("name") String groupName) throws WebValidationException - Throws:
WebValidationException
-
addUsersToGroup
@POST @Path("{name : (.+)?}/add-users") public javax.ws.rs.core.Response addUsersToGroup(@PathParam("name") String groupName, List<String> usersToAdd) throws WebValidationException - Throws:
WebValidationException
-
removeUsersFromGroup
@DELETE @Path("{name : (.+)?}/remove-users") public javax.ws.rs.core.Response removeUsersFromGroup(@PathParam("name") String groupName, List<String> usersToRemove) throws WebValidationException - Throws:
WebValidationException
-
findUsersInGroup
@GET @Path("{name : (.+)?}/more-members") public RestPageModel<RestUserDetails> findUsersInGroup(@PathParam("name") String groupName, @QueryParam("filter") @DefaultValue("") String filter, @BeanParam PageRequest pageRequest, @BeanParam ExpansionParam expansion, @Context javax.ws.rs.core.UriInfo uriInfo) -
findUsersNotInGroup
@GET @Path("{name : (.+)?}/more-non-members") public RestPageModel<RestUserDetails> findUsersNotInGroup(@PathParam("name") String groupName, @QueryParam("filter") @DefaultValue("") String filter, @BeanParam PageRequest pageRequest, @BeanParam ExpansionParam expansion, @Context javax.ws.rs.core.UriInfo uriInfo) throws com.atlassian.user.EntityException - Throws:
com.atlassian.user.EntityException
-