In this article
Link Group to User
Links a group to a user.
Only an Admin can link a group to a user.
URL
https://{{HOST}}/security/user/group?v={version}userId={userId}&groupId={groupId}
Method
POST
Required IMS Scopes
- securityapi_all
Versions Supported
- 2.0 (Default)
URL Query Parameters
| Name | Description | Example | Type |
|---|---|---|---|
| v optional |
Version of the api to use | /user/group?v=2.0 | number |
| userId required |
The ID of the user. | /user/group?userId=testUser | string |
| groupId required |
The ID of the group. | /user/group?groupId=testGroup | string |
Request Header Parameters
| Type | Value | Description |
|---|---|---|
| Authorization required |
Bearer {access_token} | IMS access token |
| Content-Type required |
application/json | Content Type |
Example
Request
curl -X POST
'https://{{HOST}}/securityapi/user/group?v=2.0&userId=testUser&groupId=testGroup'
-H 'Authorization: Bearer {access_token}' |
-H 'Content-Type: application/json'
Response
{
"success": true
}
Errors
| Error | Description |
|---|---|
| Error Name | Description of Error |
Response Body Parameters
| Name | Description | Schema |
|---|---|---|
| Object Name | Description | object definition |
| success | Description | object definition |