Skip to main content

Update a Group

PUT 

/api/v33.01/groups/:id

x-prisma-cloud-target-env: {"permission":"userManagement"}

Creates or modifies a group. The id can be retrieved with from the GET /api/v1/groups endpoint.

To invoke this endpoint in the Console UI:

  1. Navigate to Manage > Authentication > Groups.
  2. Click the row of the group you want to update or click dotted icon under the Actions column to open the menu options and click the Manage button.
  3. Update the group's parameters.
  4. Click the Save button to save the changes.

cURL Request

The PUT cURL command updates a group.

To submit a cURL request:

  • The name value is required.
  • If one of the following resources is left unspecified, the resource value will be set to a wildcard [*]: hosts, images, labels, containers, functions, namespaces, appIDs, accountIDs, codeRepos, clusters

The following cURL command updates my-group with the users associated with the usernames john and jane.

Note: You can retrieve the group id names from the GET /api/v1/groups.

$ curl 'https://<CONSOLE>/api/v1/groups/{id}' \
-k \
-X PUT \
-u <USER> \
-H 'Content-Type: application/json' \
-d \
'{
"groupName": "my-group",
"user": [
{"username": "john"},
{"username": "jane"}
],
"lastModified":"2021-03-11T23:32:51.336Z"
}'

You must include a lastModified timestamp even though it will be overwritten by the system

Note: No response will be returned upon successful execution.

Request

Path Parameters

    id stringrequired

Body

    _id string

    Group name.

    groupId string

    Group identifier in the Azure SAML identification process.

    groupName string

    Group name.

    lastModified date-time

    Datetime when the group was created or last modified.

    ldapGroup boolean

    Indicates if the group is an LDAP group (true) or not (false).

    oauthGroup boolean

    Indicates if the group is an OAuth group (true) or not (false).

    oidcGroup boolean

    Indicates if the group is an OpenID Connect group (true) or not (false).

    owner string

    User who created or modified the group.

    permissions object[]

    Permissions is a list of permissions

  • Array [
  • collections string (string)[]

    List of collections the user can access.

    project string

    Names of projects which the user can access.

  • ]
  • role string

    Role of the group.

    samlGroup boolean

    Indicates if the group is a SAML group (true) or not (false).

    user object[]

    Users in the group.

  • Array [
  • username string

    Name of a user.

  • ]

Responses

OK

Loading...