Group Manager (.NET)

The Group Manager service exposes the API to create, read, update, and delete the groups. Sample use cases for Group Manager API include:

  • Creating a new group
  • Adding users to a group
  • Removing users from a group

You can also use the Group Manager service through the REST API. For more information, see Group Manager service.

This page contains the following information:

The Relativity.Identity.SDK contains this API. For compatibility and package installation instructions, see Download the SDKs and NuGet packages.

Fundamentals for managing Groups

Methods

The Group Manager API exposes the following methods on the IGroupManager interface in the Relativity.Identity.{versionNumber}.Services namespace:

  • CreateAsync() method - adds a new user group. Its parameter is the GroupRequest object which describes the group to create. It returns the GroupResponse object which contains information about the created group.
  • ReadAsync() method - Retrieves advanced metadata for a user group, including its name, associated client, and other properties. Its parameter is the Artifact ID of the group. It returns the GroupResponse object which contains information about the group.
  • UpdateAsync() method - modifies properties of the user group. Its parameters are the Artifact ID of the group and the GroupRequest object. It returns the GroupResponse object which contains information about the group.
  • DeleteAsync() method - deletes the group. Its parameter is the Artifact ID of the group.
  • QueryMembersAsync() method - retrieves information about the users that belong to the group. Its parameters are QueryRequest object, start index and count of users to return and the Artifact ID of the group. It returns the QueryResultSlim object.
  • AddMembersAsync() method - adds users to the group. Its parameters include the Artifact ID of the group, and a list of user identifiers.
  • RemoveMembersAsync() method - removes users from the group. Its parameters include the Artifact ID of the group, and a list of user identifiers.
  • MassAddUsersToGroupsAsync() method - adds given users to each of the given groups. Its parameters include a list of user identifiers and a list of group identifiers. It returns a list of MassOperationResult objects.
  • MassRemoveUsersFromGroupsAsync() method - removes given users from each of the given groups. Its parameters include a list of user identifiers and a list of group identifiers. It returns a list of MassOperationResult objects.
  • QueryEligibleClients() method - retrieves a list of clients that can be used when creating and updating the group. Its parameters include the QueryRequest object, start index and count of clients to return. It returns the QueryResultSlim object.
  • QueryEligibleUsersToAdd() method - retrieves a list of users that can be added to a given group. Its parameters include the QueryRequest object, start index and count of users to return, and the Artifact ID of the group. It returns the QueryResultSlim object.

Objects

The Group Manager API includes the following classes available in the Relativity.Identity.{versionNumber}.GroupModels namespace.

GroupRequest class - represents the data used to create or update the group, as outlined in the table below:

Field Type Description
Client Securable<ObjectIdentifier> Client identifier associated with a group.
Name string A name of a group.
Keywords string Keywords associated with a group.
Notes string Notes for a group.

GroupResponse class - represents the existing group, as outlined in the table below:

Field Type Description
Client Securable<DisplayableObjectIdentifier> Client identifier associated with a group.
GroupType GroupType enum Group type.
Keywords string Keywords associated with a group.
Notes string Notes for a group.
CreatedOn DateTime A date and time of group creation.
CreatedBy DisplayableObjectIdentifier Identifier of a user that created a group.
LastModifiedBy DisplayableObjectIdentifier Identifier of a user that last modified a group.
LastModifiedOn DateTime A date and time of last modification.
Meta Meta Meta information (a list of read-only and unsupported fields).
Actions List<Action> A list of available actions that can be performed on a group.
ArtifactID int Artifact ID of a group.
Guids List<Guid> A list of Guids associated with a group.
Name string A name of a group.

GroupType enum - represent a type of a group, as outlined in the table below:

Name Value Description
SystemAdmin 1 A group containing system administrators.
SystemGroup 2 A group containing users.
Everyone 3 A special group containing all the users in the system.

Code samples

Querying eligible clients

Creating a group

Reading a group

Updating a group

Deleting a group

Querying group members

Querying eligible users to add to a group

Adding users to a group

Removing users from a group

Querying groups that user belongs to

Mass adding users to groups

Mass removing users from groups