Class UserResource
- java.lang.Object
-
- com.atlassian.confluence.plugins.restapi.resources.UserResource
-
public class UserResource extends Object
Non-admin user operations
-
-
Constructor Summary
Constructors Constructor Description UserResource(PersonService personService, GroupService groupService)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Person
getAnonymous()
Get information about the how anonymous is represented in confluencePerson
getCurrent(String expand)
Get information about the current logged in user.PageResponse<Group>
getGroups(String userKey, String username, String expand, int start, int limit, javax.ws.rs.core.UriInfo uriInfo)
Get a paginated collection of groups that the given user is a member ofPerson
getUser(String key, String username, String expand)
Get information about a user identified by either user key or username.Person
getUserGraph(boolean current, String key, String username, String expand)
-
-
-
Constructor Detail
-
UserResource
public UserResource(PersonService personService, GroupService groupService)
-
-
Method Detail
-
getUserGraph
public Person getUserGraph(boolean current, String key, String username, String expand)
-
getUser
public Person getUser(String key, String username, String expand)
Get information about a user identified by either user key or username.
Example request URI(s):
http://example.com/confluence/rest/api/user?username=jblogs
http://example.com/confluence/rest/api/user?key=402880824ff933a4014ff9345d7c0002
- Parameters:
key
- userkey of the user to request from this resourceusername
- username of the user to request from this resourceexpand
- properties to expand on the user- Returns:
- the user identified by the key or username
-
getCurrent
public Person getCurrent(String expand)
Get information about the current logged in user.Example request URI(s):
http://example.com/confluence/rest/api/user/current
- Parameters:
expand
-- Returns:
- the current logged in user, or anonymous if viewing is allowed by anonymous
-
getAnonymous
public Person getAnonymous()
Get information about the how anonymous is represented in confluenceExample request URI(s):
http://example.com/confluence/rest/api/user/anonymous
- Returns:
- anonymous
-
getGroups
public PageResponse<Group> getGroups(String userKey, String username, String expand, int start, int limit, @Context javax.ws.rs.core.UriInfo uriInfo)
Get a paginated collection of groups that the given user is a member ofExample request URI(s):
http://example.com/confluence/rest/api/user/memberof?username=jblogs
http://example.com/confluence/rest/api/user/memberof?key=402880824ff933a4014ff9345d7c0002
- Returns:
- anonymous
-
-