Package com.okta.sdk.resource.api
Class RoleBTargetAdminApi
java.lang.Object
com.okta.sdk.resource.api.RoleBTargetAdminApi
@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen",
date="2026-03-13T17:36:05.533634+05:30[Asia/Kolkata]",
comments="Generator version: 7.15.0")
public class RoleBTargetAdminApi
extends Object
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidassignAllAppsAsTargetToRoleForUser(String userId, String roleAssignmentId) Assign all apps as target to admin role Assigns all apps as target to an `APP_ADMIN` rolevoidassignAllAppsAsTargetToRoleForUser(String userId, String roleAssignmentId, Map<String, String> additionalHeaders) Assign all apps as target to admin role Assigns all apps as target to an `APP_ADMIN` rolevoidassignAppInstanceTargetToAppAdminRoleForUser(String userId, String roleAssignmentId, String appName, String appId) Assign an admin role app instance target Assigns an app instance target to an `APP_ADMIN` role assignment to an admin user.voidassignAppInstanceTargetToAppAdminRoleForUser(String userId, String roleAssignmentId, String appName, String appId, Map<String, String> additionalHeaders) Assign an admin role app instance target Assigns an app instance target to an `APP_ADMIN` role assignment to an admin user.voidassignAppTargetToAdminRoleForUser(String userId, String roleAssignmentId, String appName) Assign an admin role app target Assigns an OIN app target for an `APP_ADMIN` role assignment to an admin user.voidassignAppTargetToAdminRoleForUser(String userId, String roleAssignmentId, String appName, Map<String, String> additionalHeaders) Assign an admin role app target Assigns an OIN app target for an `APP_ADMIN` role assignment to an admin user.voidassignGroupTargetToUserRole(String userId, String roleAssignmentId, String groupId) Assign an admin role group target Assigns a group target for a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user.voidassignGroupTargetToUserRole(String userId, String roleAssignmentId, String groupId, Map<String, String> additionalHeaders) Assign an admin role group target Assigns a group target for a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user.protected static com.fasterxml.jackson.databind.ObjectMappergetRoleTargetsByUserIdAndRoleId(String userId, String roleIdOrEncodedRoleId, String assignmentType, String after, Integer limit) Retrieve a role target by assignment type Retrieves all role targets for an `APP_ADMIN`, `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user by user or group assignment type.getRoleTargetsByUserIdAndRoleId(String userId, String roleIdOrEncodedRoleId, String assignmentType, String after, Integer limit, Map<String, String> additionalHeaders) Retrieve a role target by assignment type Retrieves all role targets for an `APP_ADMIN`, `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user by user or group assignment type.getRoleTargetsByUserIdAndRoleIdPaged(String userId, String roleIdOrEncodedRoleId, String assignmentType, String after, Integer limit) Retrieve a role target by assignment type (Paginated) Retrieves all role targets for an `APP_ADMIN`, `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user by user or group assignment type.getRoleTargetsByUserIdAndRoleIdPaged(String userId, String roleIdOrEncodedRoleId, String assignmentType, String after, Integer limit, Map<String, String> additionalHeaders) Retrieve a role target by assignment type (Paginated with additional headers) Retrieves all role targets for an `APP_ADMIN`, `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user by user or group assignment type.listApplicationTargetsForApplicationAdministratorRoleForUser(String userId, String roleAssignmentId, String after, Integer limit) List all admin role app targets Lists all app targets for an `APP_ADMIN` role assigned to a user.listApplicationTargetsForApplicationAdministratorRoleForUser(String userId, String roleAssignmentId, String after, Integer limit, Map<String, String> additionalHeaders) List all admin role app targets Lists all app targets for an `APP_ADMIN` role assigned to a user.listApplicationTargetsForApplicationAdministratorRoleForUserPaged(String userId, String roleAssignmentId, String after, Integer limit) List all admin role app targets (Paginated) Lists all app targets for an `APP_ADMIN` role assigned to a user.listApplicationTargetsForApplicationAdministratorRoleForUserPaged(String userId, String roleAssignmentId, String after, Integer limit, Map<String, String> additionalHeaders) List all admin role app targets (Paginated with additional headers) Lists all app targets for an `APP_ADMIN` role assigned to a user.listGroupTargetsForRole(String userId, String roleAssignmentId, String after, Integer limit) List all admin role group targets Lists all group targets for a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user.listGroupTargetsForRole(String userId, String roleAssignmentId, String after, Integer limit, Map<String, String> additionalHeaders) List all admin role group targets Lists all group targets for a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user.listGroupTargetsForRolePaged(String userId, String roleAssignmentId, String after, Integer limit) List all admin role group targets (Paginated) Lists all group targets for a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user.listGroupTargetsForRolePaged(String userId, String roleAssignmentId, String after, Integer limit, Map<String, String> additionalHeaders) List all admin role group targets (Paginated with additional headers) Lists all group targets for a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user.voidsetApiClient(ApiClient apiClient) voidunassignAppInstanceTargetFromAdminRoleForUser(String userId, String roleAssignmentId, String appName, String appId) Unassign an admin role app instance target Unassigns an app instance target from an `APP_ADMIN` role assignment to an admin user.voidunassignAppInstanceTargetFromAdminRoleForUser(String userId, String roleAssignmentId, String appName, String appId, Map<String, String> additionalHeaders) Unassign an admin role app instance target Unassigns an app instance target from an `APP_ADMIN` role assignment to an admin user.voidunassignAppTargetFromAppAdminRoleForUser(String userId, String roleAssignmentId, String appName) Unassign an admin role app target Unassigns an OIN app target from an `APP_ADMIN` role assignment to an admin user.voidunassignAppTargetFromAppAdminRoleForUser(String userId, String roleAssignmentId, String appName, Map<String, String> additionalHeaders) Unassign an admin role app target Unassigns an OIN app target from an `APP_ADMIN` role assignment to an admin user.voidunassignGroupTargetFromUserAdminRole(String userId, String roleAssignmentId, String groupId) Unassign an admin role group target Unassigns a group target from a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user.voidunassignGroupTargetFromUserAdminRole(String userId, String roleAssignmentId, String groupId, Map<String, String> additionalHeaders) Unassign an admin role group target Unassigns a group target from a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user.
-
Constructor Details
-
RoleBTargetAdminApi
public RoleBTargetAdminApi() -
RoleBTargetAdminApi
-
-
Method Details
-
getApiClient
-
setApiClient
-
assignAllAppsAsTargetToRoleForUser
public void assignAllAppsAsTargetToRoleForUser(String userId, String roleAssignmentId) throws ApiException Assign all apps as target to admin role Assigns all apps as target to an `APP_ADMIN` role- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)- Throws:
ApiException- if fails to make API call
-
assignAllAppsAsTargetToRoleForUser
public void assignAllAppsAsTargetToRoleForUser(String userId, String roleAssignmentId, Map<String, String> additionalHeaders) throws ApiExceptionAssign all apps as target to admin role Assigns all apps as target to an `APP_ADMIN` role- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)additionalHeaders- additionalHeaders for this call- Throws:
ApiException- if fails to make API call
-
assignAppInstanceTargetToAppAdminRoleForUser
public void assignAppInstanceTargetToAppAdminRoleForUser(String userId, String roleAssignmentId, String appName, String appId) throws ApiException Assign an admin role app instance target Assigns an app instance target to an `APP_ADMIN` role assignment to an admin user. When you assign the first OIN app or app instance target, you reduce the scope of the role assignment. The role no longer applies to all app targets, but applies only to the specified target. > **Note:** You can target a mixture of both OIN app and app instance targets, but can't assign permissions to manage all instances of an OIN app and then assign a subset of permission to the same OIN app. > For example, you can't specify that an admin has access to manage all instances of the Salesforce app and then also manage specific configurations of the Salesforce app.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)appName- Name of the app definition (the OIN catalog app key name) (required)appId- Application ID (required)- Throws:
ApiException- if fails to make API call
-
assignAppInstanceTargetToAppAdminRoleForUser
public void assignAppInstanceTargetToAppAdminRoleForUser(String userId, String roleAssignmentId, String appName, String appId, Map<String, String> additionalHeaders) throws ApiExceptionAssign an admin role app instance target Assigns an app instance target to an `APP_ADMIN` role assignment to an admin user. When you assign the first OIN app or app instance target, you reduce the scope of the role assignment. The role no longer applies to all app targets, but applies only to the specified target. > **Note:** You can target a mixture of both OIN app and app instance targets, but can't assign permissions to manage all instances of an OIN app and then assign a subset of permission to the same OIN app. > For example, you can't specify that an admin has access to manage all instances of the Salesforce app and then also manage specific configurations of the Salesforce app.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)appName- Name of the app definition (the OIN catalog app key name) (required)appId- Application ID (required)additionalHeaders- additionalHeaders for this call- Throws:
ApiException- if fails to make API call
-
assignAppTargetToAdminRoleForUser
public void assignAppTargetToAdminRoleForUser(String userId, String roleAssignmentId, String appName) throws ApiException Assign an admin role app target Assigns an OIN app target for an `APP_ADMIN` role assignment to an admin user. When you assign the first app target, you reduce the scope of the role assignment. The role no longer applies to all app targets, but applies only to the specified target. Assigning an OIN app target overrides any existing app instance targets of the OIN app. For example, if a user was assigned to administer a specific Facebook instance, a successful request to add an OIN app target with `facebook` for `appName` makes that user the admin for all Facebook instances.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)appName- Name of the app definition (the OIN catalog app key name) (required)- Throws:
ApiException- if fails to make API call
-
assignAppTargetToAdminRoleForUser
public void assignAppTargetToAdminRoleForUser(String userId, String roleAssignmentId, String appName, Map<String, String> additionalHeaders) throws ApiExceptionAssign an admin role app target Assigns an OIN app target for an `APP_ADMIN` role assignment to an admin user. When you assign the first app target, you reduce the scope of the role assignment. The role no longer applies to all app targets, but applies only to the specified target. Assigning an OIN app target overrides any existing app instance targets of the OIN app. For example, if a user was assigned to administer a specific Facebook instance, a successful request to add an OIN app target with `facebook` for `appName` makes that user the admin for all Facebook instances.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)appName- Name of the app definition (the OIN catalog app key name) (required)additionalHeaders- additionalHeaders for this call- Throws:
ApiException- if fails to make API call
-
assignGroupTargetToUserRole
public void assignGroupTargetToUserRole(String userId, String roleAssignmentId, String groupId) throws ApiException Assign an admin role group target Assigns a group target for a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user. When you assign the first group target, you reduce the scope of the role assignment. The role no longer applies to all targets but applies only to the specified target.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)groupId- The `id` of the group (required)- Throws:
ApiException- if fails to make API call
-
assignGroupTargetToUserRole
public void assignGroupTargetToUserRole(String userId, String roleAssignmentId, String groupId, Map<String, String> additionalHeaders) throws ApiExceptionAssign an admin role group target Assigns a group target for a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user. When you assign the first group target, you reduce the scope of the role assignment. The role no longer applies to all targets but applies only to the specified target.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)groupId- The `id` of the group (required)additionalHeaders- additionalHeaders for this call- Throws:
ApiException- if fails to make API call
-
getRoleTargetsByUserIdAndRoleId
public List<RoleTarget> getRoleTargetsByUserIdAndRoleId(String userId, String roleIdOrEncodedRoleId, String assignmentType, String after, Integer limit) throws ApiException Retrieve a role target by assignment type Retrieves all role targets for an `APP_ADMIN`, `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user by user or group assignment type. If the role isn't scoped to specific group targets or any app targets, an empty array `[]` is returned.- Parameters:
userId- ID of an existing Okta user (required)roleIdOrEncodedRoleId- The `id` of the role or Base32 encoded `id` of the role name (required)assignmentType- Specifies the assignment type of the user (optional)after- The cursor to use for pagination. It is an opaque string that specifies your current location in the list and is obtained from the `Link` response header. See [Pagination](https://developer.okta.com/docs/api/#pagination) and [Link header](https://developer.okta.com/docs/api/#link-header). (optional)limit- A limit on the number of objects to return (optional, default to 20)- Returns:
- List<RoleTarget>
- Throws:
ApiException- if fails to make API call
-
getRoleTargetsByUserIdAndRoleId
public List<RoleTarget> getRoleTargetsByUserIdAndRoleId(String userId, String roleIdOrEncodedRoleId, String assignmentType, String after, Integer limit, Map<String, String> additionalHeaders) throws ApiExceptionRetrieve a role target by assignment type Retrieves all role targets for an `APP_ADMIN`, `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user by user or group assignment type. If the role isn't scoped to specific group targets or any app targets, an empty array `[]` is returned.- Parameters:
userId- ID of an existing Okta user (required)roleIdOrEncodedRoleId- The `id` of the role or Base32 encoded `id` of the role name (required)assignmentType- Specifies the assignment type of the user (optional)after- The cursor to use for pagination. It is an opaque string that specifies your current location in the list and is obtained from the `Link` response header. See [Pagination](https://developer.okta.com/docs/api/#pagination) and [Link header](https://developer.okta.com/docs/api/#link-header). (optional)limit- A limit on the number of objects to return (optional, default to 20)additionalHeaders- additionalHeaders for this call- Returns:
- List<RoleTarget>
- Throws:
ApiException- if fails to make API call
-
getRoleTargetsByUserIdAndRoleIdPaged
public Iterable<RoleTarget> getRoleTargetsByUserIdAndRoleIdPaged(String userId, String roleIdOrEncodedRoleId, String assignmentType, String after, Integer limit) Retrieve a role target by assignment type (Paginated) Retrieves all role targets for an `APP_ADMIN`, `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user by user or group assignment type. If the role isn't scoped to specific group targets or any app targets, an empty array `[]` is returned. This method returns a lazy, paginated iterable that automatically handles pagination. It is thread-safe and does not cause memory leaks. Use this method in a for-each loop to automatically fetch all pages without manual cursor management.- Parameters:
userId- ID of an existing Okta user (required)roleIdOrEncodedRoleId- The `id` of the role or Base32 encoded `id` of the role name (required)assignmentType- Specifies the assignment type of the user (optional)after- The cursor to use for pagination. It is an opaque string that specifies your current location in the list and is obtained from the `Link` response header. See [Pagination](https://developer.okta.com/docs/api/#pagination) and [Link header](https://developer.okta.com/docs/api/#link-header). (optional)limit- A limit on the number of objects to return (optional, default to 20)- Returns:
- Iterable<RoleTarget> lazy iterable over all pages
-
getRoleTargetsByUserIdAndRoleIdPaged
public Iterable<RoleTarget> getRoleTargetsByUserIdAndRoleIdPaged(String userId, String roleIdOrEncodedRoleId, String assignmentType, String after, Integer limit, Map<String, String> additionalHeaders) Retrieve a role target by assignment type (Paginated with additional headers) Retrieves all role targets for an `APP_ADMIN`, `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user by user or group assignment type. If the role isn't scoped to specific group targets or any app targets, an empty array `[]` is returned. This method returns a lazy, paginated iterable that automatically handles pagination. It is thread-safe and does not cause memory leaks.- Parameters:
userId- ID of an existing Okta user (required)roleIdOrEncodedRoleId- The `id` of the role or Base32 encoded `id` of the role name (required)assignmentType- Specifies the assignment type of the user (optional)after- The cursor to use for pagination. It is an opaque string that specifies your current location in the list and is obtained from the `Link` response header. See [Pagination](https://developer.okta.com/docs/api/#pagination) and [Link header](https://developer.okta.com/docs/api/#link-header). (optional)limit- A limit on the number of objects to return (optional, default to 20)additionalHeaders- additional headers for this call- Returns:
- Iterable<RoleTarget> lazy iterable over all pages
-
listApplicationTargetsForApplicationAdministratorRoleForUser
public List<CatalogApplication> listApplicationTargetsForApplicationAdministratorRoleForUser(String userId, String roleAssignmentId, String after, Integer limit) throws ApiException List all admin role app targets Lists all app targets for an `APP_ADMIN` role assigned to a user. The response is a list that includes OIN-cataloged apps or app instances. The response payload for an app instance contains the `id` property, but an OIN-cataloged app payload doesn't.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)after- The cursor to use for pagination. It is an opaque string that specifies your current location in the list and is obtained from the `Link` response header. See [Pagination](https://developer.okta.com/docs/api/#pagination) and [Link header](https://developer.okta.com/docs/api/#link-header). (optional)limit- A limit on the number of objects to return (optional, default to 20)- Returns:
- List<CatalogApplication>
- Throws:
ApiException- if fails to make API call
-
listApplicationTargetsForApplicationAdministratorRoleForUser
public List<CatalogApplication> listApplicationTargetsForApplicationAdministratorRoleForUser(String userId, String roleAssignmentId, String after, Integer limit, Map<String, String> additionalHeaders) throws ApiExceptionList all admin role app targets Lists all app targets for an `APP_ADMIN` role assigned to a user. The response is a list that includes OIN-cataloged apps or app instances. The response payload for an app instance contains the `id` property, but an OIN-cataloged app payload doesn't.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)after- The cursor to use for pagination. It is an opaque string that specifies your current location in the list and is obtained from the `Link` response header. See [Pagination](https://developer.okta.com/docs/api/#pagination) and [Link header](https://developer.okta.com/docs/api/#link-header). (optional)limit- A limit on the number of objects to return (optional, default to 20)additionalHeaders- additionalHeaders for this call- Returns:
- List<CatalogApplication>
- Throws:
ApiException- if fails to make API call
-
listApplicationTargetsForApplicationAdministratorRoleForUserPaged
public Iterable<CatalogApplication> listApplicationTargetsForApplicationAdministratorRoleForUserPaged(String userId, String roleAssignmentId, String after, Integer limit) List all admin role app targets (Paginated) Lists all app targets for an `APP_ADMIN` role assigned to a user. The response is a list that includes OIN-cataloged apps or app instances. The response payload for an app instance contains the `id` property, but an OIN-cataloged app payload doesn't. This method returns a lazy, paginated iterable that automatically handles pagination. It is thread-safe and does not cause memory leaks. Use this method in a for-each loop to automatically fetch all pages without manual cursor management.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)after- The cursor to use for pagination. It is an opaque string that specifies your current location in the list and is obtained from the `Link` response header. See [Pagination](https://developer.okta.com/docs/api/#pagination) and [Link header](https://developer.okta.com/docs/api/#link-header). (optional)limit- A limit on the number of objects to return (optional, default to 20)- Returns:
- Iterable<CatalogApplication> lazy iterable over all pages
-
listApplicationTargetsForApplicationAdministratorRoleForUserPaged
public Iterable<CatalogApplication> listApplicationTargetsForApplicationAdministratorRoleForUserPaged(String userId, String roleAssignmentId, String after, Integer limit, Map<String, String> additionalHeaders) List all admin role app targets (Paginated with additional headers) Lists all app targets for an `APP_ADMIN` role assigned to a user. The response is a list that includes OIN-cataloged apps or app instances. The response payload for an app instance contains the `id` property, but an OIN-cataloged app payload doesn't. This method returns a lazy, paginated iterable that automatically handles pagination. It is thread-safe and does not cause memory leaks.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)after- The cursor to use for pagination. It is an opaque string that specifies your current location in the list and is obtained from the `Link` response header. See [Pagination](https://developer.okta.com/docs/api/#pagination) and [Link header](https://developer.okta.com/docs/api/#link-header). (optional)limit- A limit on the number of objects to return (optional, default to 20)additionalHeaders- additional headers for this call- Returns:
- Iterable<CatalogApplication> lazy iterable over all pages
-
listGroupTargetsForRole
public List<Group> listGroupTargetsForRole(String userId, String roleAssignmentId, String after, Integer limit) throws ApiException List all admin role group targets Lists all group targets for a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user. If the role isn't scoped to specific group targets, an empty array `[]` is returned.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)after- The cursor to use for pagination. It is an opaque string that specifies your current location in the list and is obtained from the `Link` response header. See [Pagination](https://developer.okta.com/docs/api/#pagination) and [Link header](https://developer.okta.com/docs/api/#link-header). (optional)limit- A limit on the number of objects to return (optional, default to 20)- Returns:
- List<Group>
- Throws:
ApiException- if fails to make API call
-
listGroupTargetsForRole
public List<Group> listGroupTargetsForRole(String userId, String roleAssignmentId, String after, Integer limit, Map<String, String> additionalHeaders) throws ApiExceptionList all admin role group targets Lists all group targets for a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user. If the role isn't scoped to specific group targets, an empty array `[]` is returned.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)after- The cursor to use for pagination. It is an opaque string that specifies your current location in the list and is obtained from the `Link` response header. See [Pagination](https://developer.okta.com/docs/api/#pagination) and [Link header](https://developer.okta.com/docs/api/#link-header). (optional)limit- A limit on the number of objects to return (optional, default to 20)additionalHeaders- additionalHeaders for this call- Returns:
- List<Group>
- Throws:
ApiException- if fails to make API call
-
listGroupTargetsForRolePaged
public Iterable<Group> listGroupTargetsForRolePaged(String userId, String roleAssignmentId, String after, Integer limit) List all admin role group targets (Paginated) Lists all group targets for a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user. If the role isn't scoped to specific group targets, an empty array `[]` is returned. This method returns a lazy, paginated iterable that automatically handles pagination. It is thread-safe and does not cause memory leaks. Use this method in a for-each loop to automatically fetch all pages without manual cursor management.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)after- The cursor to use for pagination. It is an opaque string that specifies your current location in the list and is obtained from the `Link` response header. See [Pagination](https://developer.okta.com/docs/api/#pagination) and [Link header](https://developer.okta.com/docs/api/#link-header). (optional)limit- A limit on the number of objects to return (optional, default to 20)- Returns:
- Iterable<Group> lazy iterable over all pages
-
listGroupTargetsForRolePaged
public Iterable<Group> listGroupTargetsForRolePaged(String userId, String roleAssignmentId, String after, Integer limit, Map<String, String> additionalHeaders) List all admin role group targets (Paginated with additional headers) Lists all group targets for a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user. If the role isn't scoped to specific group targets, an empty array `[]` is returned. This method returns a lazy, paginated iterable that automatically handles pagination. It is thread-safe and does not cause memory leaks.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)after- The cursor to use for pagination. It is an opaque string that specifies your current location in the list and is obtained from the `Link` response header. See [Pagination](https://developer.okta.com/docs/api/#pagination) and [Link header](https://developer.okta.com/docs/api/#link-header). (optional)limit- A limit on the number of objects to return (optional, default to 20)additionalHeaders- additional headers for this call- Returns:
- Iterable<Group> lazy iterable over all pages
-
unassignAppInstanceTargetFromAdminRoleForUser
public void unassignAppInstanceTargetFromAdminRoleForUser(String userId, String roleAssignmentId, String appName, String appId) throws ApiException Unassign an admin role app instance target Unassigns an app instance target from an `APP_ADMIN` role assignment to an admin user. > **Note:** You can't remove the last app instance target from a role assignment since this causes an exception. > If you need a role assignment that applies to all apps, delete the `APP_ADMIN` role assignment and recreate a new one.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)appName- Name of the app definition (the OIN catalog app key name) (required)appId- Application ID (required)- Throws:
ApiException- if fails to make API call
-
unassignAppInstanceTargetFromAdminRoleForUser
public void unassignAppInstanceTargetFromAdminRoleForUser(String userId, String roleAssignmentId, String appName, String appId, Map<String, String> additionalHeaders) throws ApiExceptionUnassign an admin role app instance target Unassigns an app instance target from an `APP_ADMIN` role assignment to an admin user. > **Note:** You can't remove the last app instance target from a role assignment since this causes an exception. > If you need a role assignment that applies to all apps, delete the `APP_ADMIN` role assignment and recreate a new one.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)appName- Name of the app definition (the OIN catalog app key name) (required)appId- Application ID (required)additionalHeaders- additionalHeaders for this call- Throws:
ApiException- if fails to make API call
-
unassignAppTargetFromAppAdminRoleForUser
public void unassignAppTargetFromAppAdminRoleForUser(String userId, String roleAssignmentId, String appName) throws ApiException Unassign an admin role app target Unassigns an OIN app target from an `APP_ADMIN` role assignment to an admin user. > **Note:** You can't remove the last OIN app target from a role assignment since this causes an exception. > If you need a role assignment that applies to all apps, delete the `APP_ADMIN` role assignment to the user and recreate a new one.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)appName- Name of the app definition (the OIN catalog app key name) (required)- Throws:
ApiException- if fails to make API call
-
unassignAppTargetFromAppAdminRoleForUser
public void unassignAppTargetFromAppAdminRoleForUser(String userId, String roleAssignmentId, String appName, Map<String, String> additionalHeaders) throws ApiExceptionUnassign an admin role app target Unassigns an OIN app target from an `APP_ADMIN` role assignment to an admin user. > **Note:** You can't remove the last OIN app target from a role assignment since this causes an exception. > If you need a role assignment that applies to all apps, delete the `APP_ADMIN` role assignment to the user and recreate a new one.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)appName- Name of the app definition (the OIN catalog app key name) (required)additionalHeaders- additionalHeaders for this call- Throws:
ApiException- if fails to make API call
-
unassignGroupTargetFromUserAdminRole
public void unassignGroupTargetFromUserAdminRole(String userId, String roleAssignmentId, String groupId) throws ApiException Unassign an admin role group target Unassigns a group target from a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user. > **Note:** You can't remove the last group target from a role assignment since this causes an exception. > If you need a role assignment that applies to all groups, delete the role assignment to the user and recreate a new one.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)groupId- The `id` of the group (required)- Throws:
ApiException- if fails to make API call
-
unassignGroupTargetFromUserAdminRole
public void unassignGroupTargetFromUserAdminRole(String userId, String roleAssignmentId, String groupId, Map<String, String> additionalHeaders) throws ApiExceptionUnassign an admin role group target Unassigns a group target from a `USER_ADMIN`, `HELP_DESK_ADMIN`, or `GROUP_MEMBERSHIP_ADMIN` role assignment to an admin user. > **Note:** You can't remove the last group target from a role assignment since this causes an exception. > If you need a role assignment that applies to all groups, delete the role assignment to the user and recreate a new one.- Parameters:
userId- ID of an existing Okta user (required)roleAssignmentId- The `id` of the role assignment (required)groupId- The `id` of the group (required)additionalHeaders- additionalHeaders for this call- Throws:
ApiException- if fails to make API call
-
getObjectMapper
protected static com.fasterxml.jackson.databind.ObjectMapper getObjectMapper()
-