abacusai.organization_group

Module Contents

Classes

OrganizationGroup

An Organization Group. Defines the permissions available to the users who are members of the group.

class abacusai.organization_group.OrganizationGroup(client, organizationGroupId=None, permissions=None, groupName=None, defaultGroup=None, admin=None, createdAt=None)

Bases: abacusai.return_class.AbstractApiClass

An Organization Group. Defines the permissions available to the users who are members of the group.

Parameters
  • client (ApiClient) – An authenticated API Client instance

  • organizationGroupId (str) – The unique identifier of the Organization Group.

  • permissions (list of enum string) – The list of permissions (VIEW, MODIFY, ADMIN, BILLING, API_KEY, INVITE_USER) the group has.

  • groupName (str) – The name of the Organization Group.

  • defaultGroup (bool) – If true, all new users will be added to this group automatically.

  • admin (bool) – If true, this group contains all permissions available to the organization and cannot be modified or deleted.

  • createdAt (str) – When the Organization Group was created.

__repr__(self)

Return repr(self).

to_dict(self)

Get a dict representation of the parameters in this class

Returns

The dict value representation of the class parameters

Return type

dict

refresh(self)

Calls describe and refreshes the current object’s fields

Returns

The current object

Return type

OrganizationGroup

describe(self)

Returns the specific organization group passes in by the user.

Parameters

organization_group_id (str) – The unique ID of the organization group to that needs to be described.

Returns

Information about a specific Organization Group

Return type

OrganizationGroup

add_permission(self, permission)

Adds a permission to the specified Organization Group

Parameters

permission (str) – The permission to add to the Organization Group

remove_permission(self, permission)

Removes a permission from the specified Organization Group

Parameters

permission (str) – The permission to remove from the Organization Group

delete(self)

Deletes the specified Organization Group from the organization.

Parameters

organization_group_id (str) – The ID of the Organization Group

add_user_to(self, email)

Adds a user to the specified Organization Group

Parameters

email (str) – The email of the user that is added to the group

remove_user_from(self, email)

Removes a user from an Organization Group

Parameters

email (str) – The email of the user to remove

set_default(self)

Sets the default Organization Group that all new users that join an organization are automatically added to

Parameters

organization_group_id (str) – The ID of the Organization Group