public class OrgAPI extends BaseAPI
| Constructor and Description |
|---|
OrgAPI(ResourceFactory resourceFactory) |
| Modifier and Type | Method and Description |
|---|---|
OrganizationCreateResponse |
createOrganization(OrganizationCreate data)
Creates a new organization
|
void |
endMember(int orgId,
int userId)
Ends the users membership of all spaces in the organization.
|
EndMemberInfo |
getEndMemberInfo(int orgId,
int userId)
Returns information about what would happen if this user would be removed from the org
|
OrganizationMember |
getMember(int orgId,
int userId)
Returns the member data for the given user in the given organization.
|
OrganizationMember |
getMemberByMail(int orgId,
String mail)
Returns the member data for the given user in the given organization.
|
List<OrganizationMember> |
getMembers(int orgId)
Returns the members, both invited and active, of the given organization.
|
Organization |
getOrganization(int orgId)
Gets the organization with the given id.
|
OrganizationMini |
getOrganizationByURL(String url)
Returns the organization with the given full URL.
|
List<OrganizationWithSpaces> |
getOrganizations()
Returns a list of all the organizations and spaces the user is member of.
|
List<OrganizationWithSpaces> |
getSharedOrganizations(int userId)
Returns the organizations and spaces that the logged in user shares with
the specified user.
|
Space |
getSpaceByURL(int orgId,
String url)
Return the space with the given URL on the space.
|
List<Space> |
getSpaces(int orgId)
Returns all the spaces for the organization.
|
void |
updateOrganization(int orgId,
OrganizationCreate data)
Updates an organization with new name and logo.
|
getResourceFactorypublic OrgAPI(ResourceFactory resourceFactory)
public OrganizationCreateResponse createOrganization(OrganizationCreate data)
data - The data for the new organizationpublic void updateOrganization(int orgId,
OrganizationCreate data)
orgId - The id of the organizationdata - The new datapublic Organization getOrganization(int orgId)
orgId - The id of the organizationpublic List<OrganizationWithSpaces> getOrganizations()
public OrganizationMini getOrganizationByURL(String url)
url - The URL to find the organization forpublic List<OrganizationWithSpaces> getSharedOrganizations(int userId)
userId - The id of the userpublic Space getSpaceByURL(int orgId, String url)
orgId - The id of the organizationurl - The url fragment for the spacepublic List<Space> getSpaces(int orgId)
orgId - The id of the organizationpublic List<OrganizationMember> getMembers(int orgId)
orgId - The id of the organizationpublic OrganizationMember getMember(int orgId, int userId)
orgId - The id of the organizationuserId - The id of the userpublic OrganizationMember getMemberByMail(int orgId, String mail)
orgId - The id of the organizationmail - The mail of the users accountpublic EndMemberInfo getEndMemberInfo(int orgId, int userId)
orgId - The id of the organizationuserId - The id of the userpublic void endMember(int orgId,
int userId)
orgId - The id of the organizationuserId - The id of the userCopyright © 2014. All Rights Reserved.