client.groups.post

A method of the Groups endpoint.

post(name: str, *, description: str = None, slug: str = None, organization_id: int = None, default_otp_required_for_login: bool = None, role_ids: List[int] = None, default_time_zone: str = None, default_jobs_label: str = None, default_notebooks_label: str = None, default_services_label: str = None) Response

Create a Group

API URL: POST /groups

import civis
client = civis.APIClient()
response = client.groups.post(...)
Parameters:
namestr

This group’s name.

descriptionstr, optional

The description of the group.

slugstr, optional

The slug for this group.

organization_idint, optional

The ID of the organization this group belongs to.

default_otp_required_for_loginbool, optional

The two factor authentication requirement for this group.

role_idsList[int], optional

An array of ids of all the roles this group has.

default_time_zonestr, optional

The default time zone of this group.

default_jobs_labelstr, optional

The default partition label for jobs of this group.

default_notebooks_labelstr, optional

The default partition label for notebooks of this group.

default_services_labelstr, optional

The default partition label for services of this group.

Returns:
civis.Response
  • idint

    The ID of this group.

  • namestr

    This group’s name.

  • created_atstr (time)

    The date and time when this group was created.

  • updated_atstr (time)

    The date and time when this group was last updated.

  • descriptionstr

    The description of the group.

  • slugstr

    The slug for this group.

  • organization_idint

    The ID of the organization this group belongs to.

  • organization_namestr

    The name of the organization this group belongs to.

  • member_countint

    The number of active members in this group.

  • total_member_countint

    The total number of members in this group.

  • default_otp_required_for_loginbool

    The two factor authentication requirement for this group.

  • role_idsList[int]

    An array of ids of all the roles this group has.

  • default_time_zonestr

    The default time zone of this group.

  • default_jobs_labelstr

    The default partition label for jobs of this group.

  • default_notebooks_labelstr

    The default partition label for notebooks of this group.

  • default_services_labelstr

    The default partition label for services of this group.

  • last_updated_by_idint

    The ID of the user who last updated this group.

  • created_by_idint

    The ID of the user who created this group.

  • membersList[civis.Response]

    The members of this group.

    • idint

      The ID of this user.

    • namestr

      This user’s name.

    • usernamestr

      This user’s username.

    • initialsstr

      This user’s initials.

    • onlinebool

      Whether this user is online.

    • emailstr

      This user’s email address.

    • primary_group_idint

      The ID of the primary group of this user.

    • activebool

      Whether this user account is active or deactivated.