Reference Guide

Request
body
{
"name": "User1",
"password": "myPassword",
"role_id": "1"
}
Response
body
{
"id": "4"
}
Modifying a resource instance
To modify a resource instance, use the following request components:
Headers
Accept: application/json
Content-Type: application/json
Authorization: <auth_cookie>
Operation
PATCH
URI
pattern
/api/rest/<resource_type>/<id>
where:
<resource_type> is the resource type of the instance you want to modify.
<id> is the unique identifier of the instance you want to modify.
There are three varieties of PATCH operations:
"<attribute>": "new_value" replaces the existing value of the specified attribute with the new value.
"add_<attribute>": ["<new_value1>", "<new_value2>", ...] This only applies to list-type
attributes, and adds the specified values to an existing list of values.
"remove_<attribute>": ["<existing value1>", "<existing_value2>"...] This only
applies to list-type attributes, and removes the specified values from an existing list of values.
The Reference content on page 43 documents which varieties of PATCH are supported for each resource type.
For additional functionality, such as making the request an asynchronous request, you can append one or more
request parameters to the URI.
Body
{
"argument1":<value>,
"argument2":<value>,
.
.
.
}
where the comma-separated list contains all required arguments and any optional arguments. Use double quotes
around a string, date-time, or ip-address value.
If the request succeeds, it returns a 204 No Content HTTP status code and an empty response body. If the request does not
succeed, the server returns a 4xx or 5xx HTTP status code in the response header and a message entity in the response body.
Examples
Replacing existing values in a volume group
The following request modifies the name and description values for the volume_group resource instance that has an id
of ad09bfa8-f8d8-41b5-96a9-c15c9ebdf214:
36
Creating other types of requests