Skip to main content

PUT /resourceGroups/{UUID}

Use this method to modify resource-group properties, add devices to a specific static group, or change the criteria of a dynamic resource group.

Authentication

Authentication with username and password is required.

Request URL

PUT https://{management_server_IP}/resourceGroups/{UUID}

where {UUID} is the UUID of a resource group. To obtain the group UUID, use GET /resourceGroups.

Query parameters

None

Request body

AttributesRequired / OptionalTypeDescription
criteriaRequired if type is dynamicObject(Dynamic groups only) Information about a simple criteria object or criteria set that select which managed devices are members of the dynamic group
Simple criteria is a query (logical rule) that compares property values. The following example selects managed devices whose contact is John@company.com.
{
"property": "contact",
"operator": "equals",
"value": "John@company.com",
}
A criteria set is the root of the tree structure that defines how the simple criteria are logically combined, using Boolean AND and OR relationships. The following example shows a criteria set that logically combines two simple criteria with an AND relationship. It selects managed devices whose contact is John@company.com and are in the Critical state.
{
"operator": "AND",
"criteria": [{
"property": "contact",
"operator": "equals",
"value": "John@company.com"
},
{
"property": "overallHealthState",
"operator": "equals",
"value": "Critical"
}]
}
 criteriaRequired only for criteria setsArray of objectsNested criteria or criteria set that defines the members of the dynamic group. Array elements can be a combination of simple criteria or criteria set objects.
 idRequiredStringID of the simple criteria or criteria set object
 operator StringOperator

For criteria, you can obtain a list of valid operator values for each property using GET /resourceGroups/criteriaProperties.

For criteria sets, this can be one of the following values:
  • AND. Members must satisfy all specified values.
  • OR. Members must satisfy one or more of the specified values.
 parentRequiredStringID of the parent criteria set. This is root when the criteria or criteria set is not nested.
 propertyRequired only for simple criteriaStringInventory property. To obtain a list of properties, use GET /resourceGroups/criteriaProperties.
 valueRequired only for simple criteriaStringValue of the property
descriptionOptionalStringDescription of the resource group
membersOptionalArray of strings(Static groups only) URIs for all managed devices that are members of this resource group

Members are automatically removed from the group if the device is not managed by Lenovo XClarity Administrator. For dynamic groups, the members consist of the managed devices that satisfy the criteria at the time that the GET request is done.

nameRequiredStringUnique name of the resource group
typeOptionalStringType of resource group. This can be one of the following values.
  • static
  • dynamic
Note
The group type cannot be changed.
uuidRequiredStringUUID of the resource group to be modified
Note
The group UUID cannot be changed.
The following example modifies the properties and membership of a static group.
{
"description": "Business application VMware clusters",
"members": [
"nodes/AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
"nodes/BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB"
],
"name": "e-Commerce Servers",
"type": "static"
}
The following example modifies the properties and criteria for a dynamic group.
{
"criteria": {
"criteria": [{
"property": "overallHealthState",
"operator": "equals",
"value": "Normal"
},
{
"property": "location.location",
"operator": "contains",
"value": "Lab10"
},
{
"property": "location.rack",
"operator": "contains",
"value": "rack1"
},
{
"operator": "OR",
"criteria": [
{
"property": "machineType",
"operator": "contains",
"value": "7X07"
},
{
"property": "machineType",
"operator": "contains",
"value": "7X08"
}]
}],
"operator": "AND"
},
"description": "All ThinkSystem SR530 servers in room 1 in Lab10 that are offline ",
"name": "Offline SR530 servers",
"type": "dynamic"
}

Response codes

CodeDescriptionComments
200OKThe request completed successfully.
400Bad RequestA query parameter or request attribute is missing or not valid, or the operation is not supported. A descriptive error message is returned in the response body.
403ForbiddenThe orchestrator server was prevented from fulfilling the request. A descriptive error message is returned in the response body. Ensure that you have privileges to perform the request.
409ConflictThere is a conflict with the current state of the resource. A descriptive error message is returned in the response body.
500Internal Server ErrorAn internal error occurred. A descriptive error message is returned in the response body.

Response body

AttributesTypeDescription
criteriaObject(Dynamic groups only) Information about a simple criteria object or criteria set that select which managed devices are members of the dynamic group
Simple criteria is a query (logical rule) that compares property values. The following example selects managed devices whose contact is John@company.com.
{
"property": "contact",
"operator": "equals",
"value": "John@company.com",
}
A criteria set is the root of the tree structure that defines how the simple criteria are logically combined, using Boolean AND and OR relationships. The following example shows a criteria set that logically combines two simple criteria with an AND relationship. It selects managed devices whose contact is John@company.com and are in the Critical state.
{
"operator": "AND",
"criteria": [{
"property": "contact",
"operator": "equals",
"value": "John@company.com"
},
{
"property": "overallHealthState",
"operator": "equals",
"value": "Critical"
}]
}
 criteriaArray of objectsNested criteria or criteria set that defines the members of the dynamic group. Array elements can be a combination of simple criteria or criteria set objects.
 idStringID of the simple criteria or criteria set object
 operatorStringOperator

For criteria, you can obtain a list of valid operator values for each property using GET /resourceGroups/criteriaProperties.

For criteria sets, this can be one of the following values:
  • AND. Members must satisfy all specified values.
  • OR. Members must satisfy one or more of the specified values.
 parentStringID of the parent criteria set. This is root when the criteria or criteria set is not nested.
 propertyStringInventory property. To obtain a list of properties, use GET /resourceGroups/criteriaProperties.
 valueStringValue of the property
descriptionStringDescription of the resource group
healthStatusStringStatus of the device with the highest severity. This can be one of the following values.
  • Normal
  • Non-Critical
  • Warning
  • Minor-Failure
  • Major-Failure
  • Non-Recoverable
  • Critical
  • Unknown
membersArray of stringsURIs for all managed devices that are members of this resource group

Members are automatically removed from the group if the device is not managed by Lenovo XClarity Administrator. For dynamic groups, the members consist of the managed devices that satisfy the criteria at the time that the GET request is done.

memberUuidsArray of stringsUUIDs for all managed devices that are members of this resource group
nameStringUnique name of the resource group
queryStringInternal use only.
Deprecated
This attribute is deprecated and will be removed in a future release.
rsqlStringInternal use only.
Deprecated
This attribute is deprecated and will be removed in a future release.
typeStringType of resource group. This can be one of the following values.
  • static
  • dynamic
uuidStringResource group UUID
The following example is returned if the request is successful.
{
"criteria": null,
"description": "Business application VMware clusters",
"healthStatus": "Critical",
"members": [
"nodes/AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
"nodes/BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB"
],
"memberUuids":[
"AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA",
"BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB"
],
"name": "e-Commerce Servers",
"type": "static",
"uuid": "FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF"
}