API version:
Show / Hide Table of Contents

Interface IGroupsClient

A client that works with Okta Group resources.

Inherited Members
System.Collections.Generic.IAsyncEnumerable<Okta.Sdk.IGroup>.GetAsyncEnumerator(System.Threading.CancellationToken)
Namespace: Okta.Sdk
Assembly: Okta.Sdk.dll
Syntax
public interface IGroupsClient : IAsyncEnumerable<IGroup>

Methods

ActivateGroupRuleAsync(String, CancellationToken)

Activates a specific group rule by id from your organization

Declaration
Task ActivateGroupRuleAsync(string ruleId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String ruleId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

AddApplicationInstanceTargetToAppAdminRoleGivenToGroupAsync(String, String, String, String, CancellationToken)

Add App Instance Target to App Administrator Role given to a Group

Declaration
Task AddApplicationInstanceTargetToAppAdminRoleGivenToGroupAsync(string groupId, string roleId, string appName, string applicationId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String groupId
System.String roleId
System.String appName
System.String applicationId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

AddApplicationTargetToAdminRoleGivenToGroupAsync(String, String, String, CancellationToken)

Success

Declaration
Task AddApplicationTargetToAdminRoleGivenToGroupAsync(string groupId, string roleId, string appName, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String groupId
System.String roleId
System.String appName
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

AddGroupTargetToGroupAdministratorRoleForGroupAsync(String, String, String, CancellationToken)

Declaration
Task AddGroupTargetToGroupAdministratorRoleForGroupAsync(string groupId, string roleId, string targetGroupId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String groupId
System.String roleId
System.String targetGroupId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

AddUserToGroupAsync(String, String, CancellationToken)

Adds a user to a group with 'OKTA_GROUP' type.

Declaration
Task AddUserToGroupAsync(string groupId, string userId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String groupId
System.String userId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

AssignRoleToGroupAsync(IAssignRoleRequest, String, String, CancellationToken)

Assigns a Role to a Group

Declaration
Task<IRole> AssignRoleToGroupAsync(IAssignRoleRequest assignRoleRequest, string groupId, string disableNotifications = null, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
IAssignRoleRequest assignRoleRequest

The IAssignRoleRequest resource.

System.String groupId
System.String disableNotifications
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task<IRole>

The IRole response.

CreateGroupAsync(CreateGroupOptions, CancellationToken)

Adds a new group with OKTA_GROUP type to your organization.

Declaration
Task<IGroup> CreateGroupAsync(CreateGroupOptions options, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
CreateGroupOptions options

The options for this Create Group request.

System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task<IGroup>

The IGroup response.

CreateGroupAsync(IGroup, CancellationToken)

Adds a new group with OKTA_GROUP type to your organization.

Declaration
Task<IGroup> CreateGroupAsync(IGroup group, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
IGroup group

The IGroup resource.

System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task<IGroup>

The IGroup response.

CreateGroupRuleAsync(IGroupRule, CancellationToken)

Creates a group rule to dynamically add users to the specified group if they match the condition

Declaration
Task<IGroupRule> CreateGroupRuleAsync(IGroupRule groupRule, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
IGroupRule groupRule

The IGroupRule resource.

System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task<IGroupRule>

The IGroupRule response.

DeactivateGroupRuleAsync(String, CancellationToken)

Deactivates a specific group rule by id from your organization

Declaration
Task DeactivateGroupRuleAsync(string ruleId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String ruleId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

DeleteGroupAsync(String, CancellationToken)

Removes a group with OKTA_GROUP type from your organization.

Declaration
Task DeleteGroupAsync(string groupId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String groupId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

DeleteGroupRuleAsync(String, Nullable<Boolean>, CancellationToken)

Removes a specific group rule by id from your organization

Declaration
Task DeleteGroupRuleAsync(string ruleId, bool? removeUsers = default(bool? ), CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String ruleId
System.Nullable<System.Boolean> removeUsers

Indicates whether to keep or remove users from groups assigned by this rule.

System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

GetGroupAsync(String, CancellationToken)

Fetches a group from your organization.

Declaration
Task<IGroup> GetGroupAsync(string groupId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String groupId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task<IGroup>

The IGroup response.

GetGroupRuleAsync(String, String, CancellationToken)

Fetches a specific group rule by id from your organization

Declaration
Task<IGroupRule> GetGroupRuleAsync(string ruleId, string expand = null, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String ruleId
System.String expand
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task<IGroupRule>

The IGroupRule response.

GetRoleAsync(String, String, CancellationToken)

Success

Declaration
Task<IRole> GetRoleAsync(string groupId, string roleId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String groupId
System.String roleId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task<IRole>

The IRole response.

ListApplicationTargetsForApplicationAdministratorRoleForGroup(String, String, String, Nullable<Int32>)

Lists all App targets for an APP_ADMIN Role assigned to a Group. This methods return list may include full Applications or Instances. The response for an instance will have an ID value, while Application will not have an ID.

Declaration
ICollectionClient<ICatalogApplication> ListApplicationTargetsForApplicationAdministratorRoleForGroup(string groupId, string roleId, string after = null, int? limit)
Parameters
Type Name Description
System.String groupId
System.String roleId
System.String after
System.Nullable<System.Int32> limit
Returns
Type Description
ICollectionClient<ICatalogApplication>

A collection of ICatalogApplication that can be enumerated asynchronously.

ListAssignedApplicationsForGroup(String, String, Nullable<Int32>)

Enumerates all applications that are assigned to a group.

Declaration
ICollectionClient<IApplication> ListAssignedApplicationsForGroup(string groupId, string after = null, int? limit)
Parameters
Type Name Description
System.String groupId
System.String after

Specifies the pagination cursor for the next page of apps

System.Nullable<System.Int32> limit

Specifies the number of app results for a page

Returns
Type Description
ICollectionClient<IApplication>

A collection of IApplication that can be enumerated asynchronously.

ListGroupAssignedRoles(String, String)

Success

Declaration
ICollectionClient<IRole> ListGroupAssignedRoles(string groupId, string expand = null)
Parameters
Type Name Description
System.String groupId
System.String expand
Returns
Type Description
ICollectionClient<IRole>

A collection of IRole that can be enumerated asynchronously.

ListGroupRules(Nullable<Int32>, String, String, String)

Lists all group rules for your organization.

Declaration
ICollectionClient<IGroupRule> ListGroupRules(int? limit, string after = null, string search = null, string expand = null)
Parameters
Type Name Description
System.Nullable<System.Int32> limit

Specifies the number of rule results in a page

System.String after

Specifies the pagination cursor for the next page of rules

System.String search

Specifies the keyword to search fules for

System.String expand

If specified as groupIdToGroupNameMap, then show group names

Returns
Type Description
ICollectionClient<IGroupRule>

A collection of IGroupRule that can be enumerated asynchronously.

ListGroups(String, String, String, Nullable<Int32>, String)

Enumerates groups in your organization with pagination. A subset of groups can be returned that match a supported filter expression or query.

Declaration
ICollectionClient<IGroup> ListGroups(string q = null, string search = null, string after = null, int? limit, string expand = null)
Parameters
Type Name Description
System.String q

Searches the name property of groups for matching value

System.String search

Filter expression for groups

System.String after

Specifies the pagination cursor for the next page of groups

System.Nullable<System.Int32> limit

Specifies the number of group results in a page

System.String expand

If specified, it causes additional metadata to be included in the response.

Returns
Type Description
ICollectionClient<IGroup>

A collection of IGroup that can be enumerated asynchronously.

ListGroupTargetsForGroupRole(String, String, String, Nullable<Int32>)

Success

Declaration
ICollectionClient<IGroup> ListGroupTargetsForGroupRole(string groupId, string roleId, string after = null, int? limit)
Parameters
Type Name Description
System.String groupId
System.String roleId
System.String after
System.Nullable<System.Int32> limit
Returns
Type Description
ICollectionClient<IGroup>

A collection of IGroup that can be enumerated asynchronously.

ListGroupUsers(String, String, Nullable<Int32>)

Enumerates all users that are a member of a group.

Declaration
ICollectionClient<IUser> ListGroupUsers(string groupId, string after = null, int? limit)
Parameters
Type Name Description
System.String groupId
System.String after

Specifies the pagination cursor for the next page of users

System.Nullable<System.Int32> limit

Specifies the number of user results in a page

Returns
Type Description
ICollectionClient<IUser>

A collection of IUser that can be enumerated asynchronously.

RemoveApplicationTargetFromAdministratorRoleGivenToGroupAsync(String, String, String, String, CancellationToken)

Remove App Instance Target to App Administrator Role given to a Group

Declaration
Task RemoveApplicationTargetFromAdministratorRoleGivenToGroupAsync(string groupId, string roleId, string appName, string applicationId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String groupId
System.String roleId
System.String appName
System.String applicationId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

RemoveApplicationTargetFromApplicationAdministratorRoleGivenToGroupAsync(String, String, String, CancellationToken)

Success

Declaration
Task RemoveApplicationTargetFromApplicationAdministratorRoleGivenToGroupAsync(string groupId, string roleId, string appName, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String groupId
System.String roleId
System.String appName
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

RemoveGroupTargetFromGroupAdministratorRoleGivenToGroupAsync(String, String, String, CancellationToken)

Declaration
Task RemoveGroupTargetFromGroupAdministratorRoleGivenToGroupAsync(string groupId, string roleId, string targetGroupId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String groupId
System.String roleId
System.String targetGroupId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

RemoveRoleFromGroupAsync(String, String, CancellationToken)

Unassigns a Role from a Group

Declaration
Task RemoveRoleFromGroupAsync(string groupId, string roleId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String groupId
System.String roleId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

RemoveUserFromGroupAsync(String, String, CancellationToken)

Removes a user from a group with 'OKTA_GROUP' type.

Declaration
Task RemoveUserFromGroupAsync(string groupId, string userId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String groupId
System.String userId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task

A Task that represents the asynchronous operation.

UpdateGroupAsync(IGroup, String, CancellationToken)

Updates the profile for a group with OKTA_GROUP type from your organization.

Declaration
Task<IGroup> UpdateGroupAsync(IGroup group, string groupId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
IGroup group

The IGroup resource.

System.String groupId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task<IGroup>

The IGroup response.

UpdateGroupRuleAsync(IGroupRule, String, CancellationToken)

Updates a group rule. Only INACTIVE rules can be updated.

Declaration
Task<IGroupRule> UpdateGroupRuleAsync(IGroupRule groupRule, string ruleId, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
IGroupRule groupRule

The IGroupRule resource.

System.String ruleId
System.Threading.CancellationToken cancellationToken

The cancellation token.

Returns
Type Description
System.Threading.Tasks.Task<IGroupRule>

The IGroupRule response.

Back to top Copyright © 2021 Okta, Inc.
Generated with DocFx.