Package com.okta.sdk.resource.api
Class GroupApi
java.lang.Object
com.okta.sdk.resource.api.GroupApi
@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen",
date="2024-03-29T16:47:02.065887-05:00[America/Chicago]",
comments="Generator version: 7.4.0")
public class GroupApi
extends Object
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
activateGroupRule
(String groupRuleId) Activate a Group Rule Activates a specific group rule by `groupRuleId`void
activateGroupRule
(String groupRuleId, Map<String, String> additionalHeaders) Activate a Group Rule Activates a specific group rule by `groupRuleId`assignGroupOwner
(String groupId, AssignGroupOwnerRequestBody assignGroupOwnerRequestBody) Assign a Group Owner Assigns a group ownerassignGroupOwner
(String groupId, AssignGroupOwnerRequestBody assignGroupOwnerRequestBody, Map<String, String> additionalHeaders) Assign a Group Owner Assigns a group ownervoid
assignUserToGroup
(String groupId, String userId) Assign a User Assigns a user to a group with 'OKTA_GROUP' typevoid
Assign a User Assigns a user to a group with 'OKTA_GROUP' typecreateGroup
(Group group) Create a Group Creates a new group with `OKTA_GROUP` typecreateGroup
(Group group, Map<String, String> additionalHeaders) Create a Group Creates a new group with `OKTA_GROUP` typecreateGroupRule
(GroupRule groupRule) Create a Group Rule Creates a group rule to dynamically add users to the specified group if they match the conditioncreateGroupRule
(GroupRule groupRule, Map<String, String> additionalHeaders) Create a Group Rule Creates a group rule to dynamically add users to the specified group if they match the conditionvoid
deactivateGroupRule
(String groupRuleId) Deactivate a Group Rule Deactivates a specific group rule by `groupRuleId`void
deactivateGroupRule
(String groupRuleId, Map<String, String> additionalHeaders) Deactivate a Group Rule Deactivates a specific group rule by `groupRuleId`void
deleteGroup
(String groupId) Delete a Group Deletes a group with `OKTA_GROUP` typevoid
deleteGroup
(String groupId, Map<String, String> additionalHeaders) Delete a Group Deletes a group with `OKTA_GROUP` typevoid
deleteGroupOwner
(String groupId, String ownerId) Delete a Group Owner Deletes a group owner from a specific groupvoid
Delete a Group Owner Deletes a group owner from a specific groupvoid
deleteGroupRule
(String groupRuleId, Boolean removeUsers) Delete a group Rule Deletes a specific group rule by `groupRuleId`void
Delete a group Rule Deletes a specific group rule by `groupRuleId`Retrieve a Group Retrieves a group by `groupId`Retrieve a Group Retrieves a group by `groupId`getGroupRule
(String groupRuleId, String expand) Retrieve a Group Rule Retrieves a specific group rule by `groupRuleId`Retrieve a Group Rule Retrieves a specific group rule by `groupRuleId`protected static com.fasterxml.jackson.databind.ObjectMapper
listAssignedApplicationsForGroup
(String groupId, String after, Integer limit) List all Assigned Applications Lists all applications that are assigned to a grouplistAssignedApplicationsForGroup
(String groupId, String after, Integer limit, Map<String, String> additionalHeaders) List all Assigned Applications Lists all applications that are assigned to a grouplistGroupOwners
(String groupId, String filter, String after, Integer limit) List all Group Owners Lists all owners for a specific grouplistGroupOwners
(String groupId, String filter, String after, Integer limit, Map<String, String> additionalHeaders) List all Group Owners Lists all owners for a specific grouplistGroupRules
(Integer limit, String after, String search, String expand) List all Group Rules Lists all group ruleslistGroupRules
(Integer limit, String after, String search, String expand, Map<String, String> additionalHeaders) List all Group Rules Lists all group ruleslistGroups
(String q, String filter, String after, Integer limit, String expand, String search, String sortBy, String sortOrder) List all Groups Lists all groups with pagination support.listGroups
(String q, String filter, String after, Integer limit, String expand, String search, String sortBy, String sortOrder, Map<String, String> additionalHeaders) List all Groups Lists all groups with pagination support.listGroupUsers
(String groupId, String after, Integer limit) List all Member Users Lists all users that are a member of a groupList all Member Users Lists all users that are a member of a groupreplaceGroup
(String groupId, Group group) Replace a Group Replaces the profile for a group with `OKTA_GROUP` typeReplace a Group Replaces the profile for a group with `OKTA_GROUP` typereplaceGroupRule
(String groupRuleId, GroupRule groupRule) Replace a Group Rule Replaces a group rule.Replace a Group Rule Replaces a group rule.void
setApiClient
(ApiClient apiClient) void
unassignUserFromGroup
(String groupId, String userId) Unassign a User Unassigns a user from a group with 'OKTA_GROUP' typevoid
Unassign a User Unassigns a user from a group with 'OKTA_GROUP' type
-
Constructor Details
-
GroupApi
public GroupApi() -
GroupApi
-
-
Method Details
-
getApiClient
-
setApiClient
-
activateGroupRule
Activate a Group Rule Activates a specific group rule by `groupRuleId`- Parameters:
groupRuleId
- The `id` of the group rule (required)- Throws:
ApiException
- if fails to make API call
-
activateGroupRule
public void activateGroupRule(String groupRuleId, Map<String, String> additionalHeaders) throws ApiExceptionActivate a Group Rule Activates a specific group rule by `groupRuleId`- Parameters:
groupRuleId
- The `id` of the group rule (required)additionalHeaders
- additionalHeaders for this call- Throws:
ApiException
- if fails to make API call
-
assignGroupOwner
public GroupOwner assignGroupOwner(String groupId, AssignGroupOwnerRequestBody assignGroupOwnerRequestBody) throws ApiException Assign a Group Owner Assigns a group owner- Parameters:
groupId
- The `id` of the group (required)assignGroupOwnerRequestBody
- (required)- Returns:
- GroupOwner
- Throws:
ApiException
- if fails to make API call
-
assignGroupOwner
public GroupOwner assignGroupOwner(String groupId, AssignGroupOwnerRequestBody assignGroupOwnerRequestBody, Map<String, String> additionalHeaders) throws ApiExceptionAssign a Group Owner Assigns a group owner- Parameters:
groupId
- The `id` of the group (required)assignGroupOwnerRequestBody
- (required)additionalHeaders
- additionalHeaders for this call- Returns:
- GroupOwner
- Throws:
ApiException
- if fails to make API call
-
assignUserToGroup
Assign a User Assigns a user to a group with 'OKTA_GROUP' type- Parameters:
groupId
- The `id` of the group (required)userId
- (required)- Throws:
ApiException
- if fails to make API call
-
assignUserToGroup
public void assignUserToGroup(String groupId, String userId, Map<String, String> additionalHeaders) throws ApiExceptionAssign a User Assigns a user to a group with 'OKTA_GROUP' type- Parameters:
groupId
- The `id` of the group (required)userId
- (required)additionalHeaders
- additionalHeaders for this call- Throws:
ApiException
- if fails to make API call
-
createGroup
Create a Group Creates a new group with `OKTA_GROUP` type- Parameters:
group
- (required)- Returns:
- Group
- Throws:
ApiException
- if fails to make API call
-
createGroup
Create a Group Creates a new group with `OKTA_GROUP` type- Parameters:
group
- (required)additionalHeaders
- additionalHeaders for this call- Returns:
- Group
- Throws:
ApiException
- if fails to make API call
-
createGroupRule
Create a Group Rule Creates a group rule to dynamically add users to the specified group if they match the condition- Parameters:
groupRule
- (required)- Returns:
- GroupRule
- Throws:
ApiException
- if fails to make API call
-
createGroupRule
public GroupRule createGroupRule(GroupRule groupRule, Map<String, String> additionalHeaders) throws ApiExceptionCreate a Group Rule Creates a group rule to dynamically add users to the specified group if they match the condition- Parameters:
groupRule
- (required)additionalHeaders
- additionalHeaders for this call- Returns:
- GroupRule
- Throws:
ApiException
- if fails to make API call
-
deactivateGroupRule
Deactivate a Group Rule Deactivates a specific group rule by `groupRuleId`- Parameters:
groupRuleId
- The `id` of the group rule (required)- Throws:
ApiException
- if fails to make API call
-
deactivateGroupRule
public void deactivateGroupRule(String groupRuleId, Map<String, String> additionalHeaders) throws ApiExceptionDeactivate a Group Rule Deactivates a specific group rule by `groupRuleId`- Parameters:
groupRuleId
- The `id` of the group rule (required)additionalHeaders
- additionalHeaders for this call- Throws:
ApiException
- if fails to make API call
-
deleteGroup
Delete a Group Deletes a group with `OKTA_GROUP` type- Parameters:
groupId
- The `id` of the group (required)- Throws:
ApiException
- if fails to make API call
-
deleteGroup
Delete a Group Deletes a group with `OKTA_GROUP` type- Parameters:
groupId
- The `id` of the group (required)additionalHeaders
- additionalHeaders for this call- Throws:
ApiException
- if fails to make API call
-
deleteGroupOwner
Delete a Group Owner Deletes a group owner from a specific group- Parameters:
groupId
- The `id` of the group (required)ownerId
- The `id` of the group owner (required)- Throws:
ApiException
- if fails to make API call
-
deleteGroupOwner
public void deleteGroupOwner(String groupId, String ownerId, Map<String, String> additionalHeaders) throws ApiExceptionDelete a Group Owner Deletes a group owner from a specific group- Parameters:
groupId
- The `id` of the group (required)ownerId
- The `id` of the group owner (required)additionalHeaders
- additionalHeaders for this call- Throws:
ApiException
- if fails to make API call
-
deleteGroupRule
Delete a group Rule Deletes a specific group rule by `groupRuleId`- Parameters:
groupRuleId
- The `id` of the group rule (required)removeUsers
- Indicates whether to keep or remove users from groups assigned by this rule. (optional)- Throws:
ApiException
- if fails to make API call
-
deleteGroupRule
public void deleteGroupRule(String groupRuleId, Boolean removeUsers, Map<String, String> additionalHeaders) throws ApiExceptionDelete a group Rule Deletes a specific group rule by `groupRuleId`- Parameters:
groupRuleId
- The `id` of the group rule (required)removeUsers
- Indicates whether to keep or remove users from groups assigned by this rule. (optional)additionalHeaders
- additionalHeaders for this call- Throws:
ApiException
- if fails to make API call
-
getGroup
Retrieve a Group Retrieves a group by `groupId`- Parameters:
groupId
- The `id` of the group (required)- Returns:
- Group
- Throws:
ApiException
- if fails to make API call
-
getGroup
Retrieve a Group Retrieves a group by `groupId`- Parameters:
groupId
- The `id` of the group (required)additionalHeaders
- additionalHeaders for this call- Returns:
- Group
- Throws:
ApiException
- if fails to make API call
-
getGroupRule
Retrieve a Group Rule Retrieves a specific group rule by `groupRuleId`- Parameters:
groupRuleId
- The `id` of the group rule (required)expand
- (optional)- Returns:
- GroupRule
- Throws:
ApiException
- if fails to make API call
-
getGroupRule
public GroupRule getGroupRule(String groupRuleId, String expand, Map<String, String> additionalHeaders) throws ApiExceptionRetrieve a Group Rule Retrieves a specific group rule by `groupRuleId`- Parameters:
groupRuleId
- The `id` of the group rule (required)expand
- (optional)additionalHeaders
- additionalHeaders for this call- Returns:
- GroupRule
- Throws:
ApiException
- if fails to make API call
-
listAssignedApplicationsForGroup
public List<Application> listAssignedApplicationsForGroup(String groupId, String after, Integer limit) throws ApiException List all Assigned Applications Lists all applications that are assigned to a group- Parameters:
groupId
- The `id` of the group (required)after
- Specifies the pagination cursor for the next page of apps (optional)limit
- Specifies the number of app results for a page (optional, default to 20)- Returns:
- List<Application>
- Throws:
ApiException
- if fails to make API call
-
listAssignedApplicationsForGroup
public List<Application> listAssignedApplicationsForGroup(String groupId, String after, Integer limit, Map<String, String> additionalHeaders) throws ApiExceptionList all Assigned Applications Lists all applications that are assigned to a group- Parameters:
groupId
- The `id` of the group (required)after
- Specifies the pagination cursor for the next page of apps (optional)limit
- Specifies the number of app results for a page (optional, default to 20)additionalHeaders
- additionalHeaders for this call- Returns:
- List<Application>
- Throws:
ApiException
- if fails to make API call
-
listGroupOwners
public List<GroupOwner> listGroupOwners(String groupId, String filter, String after, Integer limit) throws ApiException List all Group Owners Lists all owners for a specific group- Parameters:
groupId
- The `id` of the group (required)filter
- SCIM Filter expression for group owners. Allows to filter owners by type. (optional)after
- Specifies the pagination cursor for the next page of owners (optional)limit
- Specifies the number of owner results in a page (optional, default to 1000)- Returns:
- List<GroupOwner>
- Throws:
ApiException
- if fails to make API call
-
listGroupOwners
public List<GroupOwner> listGroupOwners(String groupId, String filter, String after, Integer limit, Map<String, String> additionalHeaders) throws ApiExceptionList all Group Owners Lists all owners for a specific group- Parameters:
groupId
- The `id` of the group (required)filter
- SCIM Filter expression for group owners. Allows to filter owners by type. (optional)after
- Specifies the pagination cursor for the next page of owners (optional)limit
- Specifies the number of owner results in a page (optional, default to 1000)additionalHeaders
- additionalHeaders for this call- Returns:
- List<GroupOwner>
- Throws:
ApiException
- if fails to make API call
-
listGroupRules
public List<GroupRule> listGroupRules(Integer limit, String after, String search, String expand) throws ApiException List all Group Rules Lists all group rules- Parameters:
limit
- Specifies the number of rule results in a page (optional, default to 50)after
- Specifies the pagination cursor for the next page of rules (optional)search
- Specifies the keyword to search fules for (optional)expand
- If specified as `groupIdToGroupNameMap`, then show group names (optional)- Returns:
- List<GroupRule>
- Throws:
ApiException
- if fails to make API call
-
listGroupRules
public List<GroupRule> listGroupRules(Integer limit, String after, String search, String expand, Map<String, String> additionalHeaders) throws ApiExceptionList all Group Rules Lists all group rules- Parameters:
limit
- Specifies the number of rule results in a page (optional, default to 50)after
- Specifies the pagination cursor for the next page of rules (optional)search
- Specifies the keyword to search fules for (optional)expand
- If specified as `groupIdToGroupNameMap`, then show group names (optional)additionalHeaders
- additionalHeaders for this call- Returns:
- List<GroupRule>
- Throws:
ApiException
- if fails to make API call
-
listGroupUsers
List all Member Users Lists all users that are a member of a group- Parameters:
groupId
- The `id` of the group (required)after
- Specifies the pagination cursor for the next page of users (optional)limit
- Specifies the number of user results in a page (optional, default to 1000)- Returns:
- List<User>
- Throws:
ApiException
- if fails to make API call
-
listGroupUsers
public List<User> listGroupUsers(String groupId, String after, Integer limit, Map<String, String> additionalHeaders) throws ApiExceptionList all Member Users Lists all users that are a member of a group- Parameters:
groupId
- The `id` of the group (required)after
- Specifies the pagination cursor for the next page of users (optional)limit
- Specifies the number of user results in a page (optional, default to 1000)additionalHeaders
- additionalHeaders for this call- Returns:
- List<User>
- Throws:
ApiException
- if fails to make API call
-
listGroups
public List<Group> listGroups(String q, String filter, String after, Integer limit, String expand, String search, String sortBy, String sortOrder) throws ApiException List all Groups Lists all groups with pagination support. A subset of groups can be returned that match a supported filter expression or query.- Parameters:
q
- Searches the name property of groups for matching value (optional)filter
- Filter expression for groups (optional)after
- Specifies the pagination cursor for the next page of groups (optional)limit
- Specifies the number of group results in a page (optional, default to 10000)expand
- If specified, it causes additional metadata to be included in the response. (optional)search
- Searches for groups with a supported filtering expression for all attributes except for _embedded, _links, and objectClass (optional)sortBy
- Specifies field to sort by and can be any single property (for search queries only). (optional)sortOrder
- Specifies sort order `asc` or `desc` (for search queries only). This parameter is ignored if `sortBy` is not present. Groups with the same value for the `sortBy` parameter are ordered by `id`. (optional, default to asc)- Returns:
- List<Group>
- Throws:
ApiException
- if fails to make API call
-
listGroups
public List<Group> listGroups(String q, String filter, String after, Integer limit, String expand, String search, String sortBy, String sortOrder, Map<String, String> additionalHeaders) throws ApiExceptionList all Groups Lists all groups with pagination support. A subset of groups can be returned that match a supported filter expression or query.- Parameters:
q
- Searches the name property of groups for matching value (optional)filter
- Filter expression for groups (optional)after
- Specifies the pagination cursor for the next page of groups (optional)limit
- Specifies the number of group results in a page (optional, default to 10000)expand
- If specified, it causes additional metadata to be included in the response. (optional)search
- Searches for groups with a supported filtering expression for all attributes except for _embedded, _links, and objectClass (optional)sortBy
- Specifies field to sort by and can be any single property (for search queries only). (optional)sortOrder
- Specifies sort order `asc` or `desc` (for search queries only). This parameter is ignored if `sortBy` is not present. Groups with the same value for the `sortBy` parameter are ordered by `id`. (optional, default to asc)additionalHeaders
- additionalHeaders for this call- Returns:
- List<Group>
- Throws:
ApiException
- if fails to make API call
-
replaceGroup
Replace a Group Replaces the profile for a group with `OKTA_GROUP` type- Parameters:
groupId
- The `id` of the group (required)group
- (required)- Returns:
- Group
- Throws:
ApiException
- if fails to make API call
-
replaceGroup
public Group replaceGroup(String groupId, Group group, Map<String, String> additionalHeaders) throws ApiExceptionReplace a Group Replaces the profile for a group with `OKTA_GROUP` type- Parameters:
groupId
- The `id` of the group (required)group
- (required)additionalHeaders
- additionalHeaders for this call- Returns:
- Group
- Throws:
ApiException
- if fails to make API call
-
replaceGroupRule
Replace a Group Rule Replaces a group rule. Only `INACTIVE` rules can be updated.- Parameters:
groupRuleId
- The `id` of the group rule (required)groupRule
- (required)- Returns:
- GroupRule
- Throws:
ApiException
- if fails to make API call
-
replaceGroupRule
public GroupRule replaceGroupRule(String groupRuleId, GroupRule groupRule, Map<String, String> additionalHeaders) throws ApiExceptionReplace a Group Rule Replaces a group rule. Only `INACTIVE` rules can be updated.- Parameters:
groupRuleId
- The `id` of the group rule (required)groupRule
- (required)additionalHeaders
- additionalHeaders for this call- Returns:
- GroupRule
- Throws:
ApiException
- if fails to make API call
-
unassignUserFromGroup
Unassign a User Unassigns a user from a group with 'OKTA_GROUP' type- Parameters:
groupId
- The `id` of the group (required)userId
- (required)- Throws:
ApiException
- if fails to make API call
-
unassignUserFromGroup
public void unassignUserFromGroup(String groupId, String userId, Map<String, String> additionalHeaders) throws ApiExceptionUnassign a User Unassigns a user from a group with 'OKTA_GROUP' type- Parameters:
groupId
- The `id` of the group (required)userId
- (required)additionalHeaders
- additionalHeaders for this call- Throws:
ApiException
- if fails to make API call
-
getObjectMapper
protected static com.fasterxml.jackson.databind.ObjectMapper getObjectMapper()
-