Skip to content
Primary navigation

Groups

List groups
client.Admin.Organization.Groups.List(ctx, query) (*NextCursorPage[Group], error)
GET/organization/groups
Create group
client.Admin.Organization.Groups.New(ctx, body) (*Group, error)
POST/organization/groups
Update group
client.Admin.Organization.Groups.Update(ctx, groupID, body) (*AdminOrganizationGroupUpdateResponse, error)
POST/organization/groups/{group_id}
Delete group
client.Admin.Organization.Groups.Delete(ctx, groupID) (*AdminOrganizationGroupDeleteResponse, error)
DELETE/organization/groups/{group_id}
ModelsExpand Collapse
type Group struct{…}

Details about an organization group.

ID string

Identifier for the group.

CreatedAt int64

Unix timestamp (in seconds) when the group was created.

formatunixtime
GroupType string

The type of the group.

IsScimManaged bool

Whether the group is managed through SCIM and controlled by your identity provider.

Name string

Display name of the group.

GroupsUsers

List group users
client.Admin.Organization.Groups.Users.List(ctx, groupID, query) (*NextCursorPage[OrganizationGroupUser], error)
GET/organization/groups/{group_id}/users
Add group user
client.Admin.Organization.Groups.Users.New(ctx, groupID, body) (*AdminOrganizationGroupUserNewResponse, error)
POST/organization/groups/{group_id}/users
Remove group user
client.Admin.Organization.Groups.Users.Delete(ctx, groupID, userID) (*AdminOrganizationGroupUserDeleteResponse, error)
DELETE/organization/groups/{group_id}/users/{user_id}
ModelsExpand Collapse
type OrganizationGroupUser struct{…}

Represents an individual user returned when inspecting group membership.

ID string

The identifier, which can be referenced in API endpoints

Email string

The email address of the user.

Name string

The name of the user.

GroupsRoles

List group organization role assignments
client.Admin.Organization.Groups.Roles.List(ctx, groupID, query) (*NextCursorPage[AdminOrganizationGroupRoleListResponse], error)
GET/organization/groups/{group_id}/roles
Assign organization role to group
client.Admin.Organization.Groups.Roles.New(ctx, groupID, body) (*AdminOrganizationGroupRoleNewResponse, error)
POST/organization/groups/{group_id}/roles
Unassign organization role from group
client.Admin.Organization.Groups.Roles.Delete(ctx, groupID, roleID) (*AdminOrganizationGroupRoleDeleteResponse, error)
DELETE/organization/groups/{group_id}/roles/{role_id}