Update User Groups
put
/rest/v19/companies/{companyName}/users/{userName}/groups
This operation to update assigned groups for the specified user.
Request
Supported Media Types
- application/json
Path Parameters
-
companyName(required): string
Company login name. For Host Company users, use _host. For Partner Organization users, use partner organization company login name.
-
userName(required): string
Login Id of the user
Root Schema : groups-updateRequest
Type:
Show Source
object
-
items:
array Groups
Title:
Groups
List of groups to which user should belong, user will be removed from the existing groups which are not passed in request.
Nested Schema : Groups
Type:
array
Title:
Groups
List of groups to which user should belong, user will be removed from the existing groups which are not passed in request.
Show Source
-
Array of:
object Group
Title:
Group
User group information
Nested Schema : Group
Type:
object
Title:
Group
User group information
Show Source
-
label:
string
Title:
Group Name
Group name -
type:
string
Title:
Group Type
Type of the group -
variableName:
string
Title:
Group Variable Name
Variable name of the group
Response
Supported Media Types
- application/json
Default Response
User groups details.
Root Schema : Groups
Type:
object
Title:
Groups
Groups to which the user belongs
Show Source
-
items:
array items
-
links:
array Links to the related objects
Title:
Links to the related objects
Links to the related objects
Nested Schema : items
Type:
Show Source
array
-
Array of:
object Group
Title:
Group
User group information
Nested Schema : Links to the related objects
Type:
array
Title:
Links to the related objects
Links to the related objects
Show Source
-
Array of:
object reference links
Title:
reference links
Reference links for the Parent, Self, Children and Related as applicable
Nested Schema : Group
Type:
object
Title:
Group
User group information
Show Source
-
label:
string
Title:
Group Name
Group name -
type:
string
Title:
Group Type
Type of the group -
variableName:
string
Title:
Group Variable Name
Variable name of the group
Nested Schema : reference links
Type:
object
Title:
reference links
Reference links for the Parent, Self, Children and Related as applicable
Show Source
-
href:
string
Title:
URL to the related object
URL to the related object -
rel:
string
Title:
Link Relationship to the current object
Link Relationship to the current object
Examples
This operation to update assigned groups for the specified user by submitting a PUT request to the REST resource using cURL. For more information about cURL, see Use cURL.
curl - X PUT -H "Authorization: Bearer <token>" - H https://sitename.oracle.com/rest/v19/companies/_host/users/aavenkatbulk/groups
Request Body Sample
{ "items": [{ "label": "Sales User", "variableName": "salesUser", "type": "Sales" }, { "label": "Sales Administrator", "variableName": "salesAdministrator", "type": "Administrator" } ] }
Response Body Sample
{ "items": [{ "label": "Sales User", "variableName": "salesUser", "type": "Sales" }, { "label": "Sales Administrator", "variableName": "salesAdministrator", "type": "Administrator" } ], "links": [{ "rel": "self", "href": "https://sitename.oracle.com/rest/v19/companies/_host/users/aavenkatbulk/groups" }, { "rel": "parent", "href": "https://sitename.oracle.com/rest/v19/companies/_host/users/aavenkatbulk" } ] }