Update the User Groups for a User

put

/rest/v19/users/{partyNumber}/groups

Use this endpoint to update user groups for a given user.

Request

Supported Media Types
Path Parameters
Body ()
Root Schema : groups-updateRequest
Type: object
Show Source
  • 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
Nested Schema : Group Details
Type: object
Title: Group Details
Show Source
Nested Schema : Company Details
Type: object
Title: Company Details
Company details to which the group belongs.
Show Source
Nested Schema : Segments
Type: object
Title: Segments
Access Segments for a group
Show Source
Nested Schema : Status
Type: object
Title: Status
Status of the group.
Show Source
Nested Schema : Type
Type: object
Title: Type
Type of the group.
Show Source
Nested Schema : Users
Type: object
Title: Users
All users of a group
Show Source
Nested Schema : items
Type: array
Show Source
Nested Schema : Segment Details
Type: object
Title: Segment Details
Show Source
  • Title: Checked
    Is segment enabled.
  • Title: Icon
    Path of the icon image file. This field is only applicable if uiMetadata is set as true.
  • Sub Segments
    Title: Sub Segments
    Sub access segments for the segment.
  • Title: Status
    Specifies if the segment is enabled, partially selected or unselected. Possible values are 0[UNCHECKED], 1[PARTIALCHECKED],2[CHECKED]. This field is only applicable if uiMetadata is set as true.
  • Title: VariableName
    Segment variable name.
Nested Schema : Sub Segments
Type: object
Title: Sub Segments
Sub access segments for the segment.
Show Source
Nested Schema : items
Type: array
Show Source
Nested Schema : Sub Segment Details
Type: object
Title: Sub Segment Details
Show Source
  • Title: Checked
    Is segment enabled.
  • Title: Icon
    Path of the icon image file. This field is only applicable if uiMetadata is set as true.
  • Title: Status
    Specifies if the segment is enabled, partially selected or unselected. Possible values are 0[UNCHECKED], 1[PARTIALCHECKED],2[CHECKED]. This field is only applicable if uiMetadata is set as true.
  • Title: title
    Segment label.
  • Title: VariableName
    Segment variable name.
Nested Schema : items
Type: array
Show Source
Nested Schema : User Details
Type: object
Title: User Details
User details of group.
Show Source
Back to Top

Response

Supported Media Types

Default Response

User groups details.
Body ()
Root Schema : Groups
Type: object
Title: Groups
Groups to which the user belongs
Show Source
Nested Schema : items
Type: array
Show Source
Nested Schema : Group Details
Type: object
Title: Group Details
Show Source
Nested Schema : Company Details
Type: object
Title: Company Details
Company details to which the group belongs.
Show Source
Nested Schema : Segments
Type: object
Title: Segments
Access Segments for a group
Show Source
Nested Schema : Status
Type: object
Title: Status
Status of the group.
Show Source
Nested Schema : Type
Type: object
Title: Type
Type of the group.
Show Source
Nested Schema : Users
Type: object
Title: Users
All users of a group
Show Source
Nested Schema : items
Type: array
Show Source
Nested Schema : Segment Details
Type: object
Title: Segment Details
Show Source
  • Title: Checked
    Is segment enabled.
  • Title: Icon
    Path of the icon image file. This field is only applicable if uiMetadata is set as true.
  • Sub Segments
    Title: Sub Segments
    Sub access segments for the segment.
  • Title: Status
    Specifies if the segment is enabled, partially selected or unselected. Possible values are 0[UNCHECKED], 1[PARTIALCHECKED],2[CHECKED]. This field is only applicable if uiMetadata is set as true.
  • Title: VariableName
    Segment variable name.
Nested Schema : Sub Segments
Type: object
Title: Sub Segments
Sub access segments for the segment.
Show Source
Nested Schema : items
Type: array
Show Source
Nested Schema : Sub Segment Details
Type: object
Title: Sub Segment Details
Show Source
  • Title: Checked
    Is segment enabled.
  • Title: Icon
    Path of the icon image file. This field is only applicable if uiMetadata is set as true.
  • Title: Status
    Specifies if the segment is enabled, partially selected or unselected. Possible values are 0[UNCHECKED], 1[PARTIALCHECKED],2[CHECKED]. This field is only applicable if uiMetadata is set as true.
  • Title: title
    Segment label.
  • Title: VariableName
    Segment variable name.
Nested Schema : items
Type: array
Show Source
Nested Schema : User Details
Type: object
Title: User Details
User details of group.
Show Source
Back to Top

Examples

The following example pdates user groups for a given 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 "Content-type: application/json" -H "Accept: application/json"
https://sitename.oracle.com/rest/v19/users/935719302534024740/groups

Request Body Sample

{
  "items": [{
      "label": "Groups",
      "variableName": "adminAccessGroupsOnly",
      "type": "Admin"
    }, {
      "label": "100k Parts",
      "variableName": "a100kparts",
      "type": "Sales"
    }
  ]
}

Response Body Sample

{
  "items": [{
      "label": "100k Parts",
      "variableName": "a100kparts",
      "type": "Sales"
    }, {
      "label": "Admin Access- Groups",
      "variableName": "adminAccessGroupsOnly",
      "type": "Administrator"
    }
  ],
  "links": [{
      "rel": "self",
      "href": "http://sitename.oracle.com/rest/v19/users/CRM_D1000/groups"
    }, {
      "rel": "parent",
      "href": "http://sitename.oracle.com/rest/v19/users/CRM_D1000"
    }
  ]
}
Back to Top