Add a Group
POST/api/v31.02/groups
x-prisma-cloud-target-env: {"permission":"userManagement","saas":false,"self-hosted":true}
x-public: true
Creates a group with users.
To invoke this endpoint in the Console UI:
- Navigate to Manage > Authentication > Groups.
- Add a collection using + Add group.
- Enter a group name and add at least one user.
- Click the Save button.
cURL Request
Refer to the following example cURL command that creates a new group named my-group
:
$ curl -k \
-X POST \
-u <USER> \
-H 'Content-Type: application/json' \
-d \
'{
"groupName": "my-group",
"user": [
{"username": "john"},
{"username": "jane"}
]
}' \
'https://<CONSOLE>/api/v<VERSION>/groups'
This group includes the users associated with the usernames john
and jane
.
Note: You must use usernames that already exist in the system.
No response will be returned upon successful execution.
Request
Responses
- 200
- default
OK