This URL updates the protected VM group.
Resource URL
PUT /cloud/cluster/<id>/vmgroup
Request Parameters
URL Parameters
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Cluster id | Number | Yes |
Payload Request Parameters
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Protected VM group name which needs to be updated | String | Yes |
| New name for protected VM group | String | Yes |
| Protected VM group description | String | No |
| VPC where the protected VM group has been created | Array | Yes |
| Resource group list in case of Azure | Array | Yes |
| Traffic inspection settings | Object | Yes |
| List of the protected subnets | Array | Yes |
Details of fields in advancedAgentSettings:
Field Name | Description | Data Type | Mandatory |
|---|---|---|---|
| Traffic processing direction. Values can be:
| String | Yes |
| Inspection mode. Values can be :
| String | Yes |
Response Parameters
Following fields are returned if the request parameters are correct, otherwise error details are returned:
Field Name | Description | Data Type |
|---|---|---|
| Set to 1 if the update was successful | Number |
Example
Request
PUT https://<NSM_IP>/sdkapi/cloud/cluster/101/vmgroup
Payload
{
"oldName": “Protected_VMGroup”,
"name": "Protected_VMGroup",
"description": "api",
"vpc": ["vpc-06b3ce61(Protected_test)"],
"advancedAgentSettings":
{
"trafficProcessing": "Ingress & Egress",
"inspectionMode": "ips"
},
"protectedObjects":
[
"subnet-bde05df4(Protected_subnet)"
]
}
Response
{
" status ": 1
}
Error Information
Following error codes are returned by this URL:
No | HTTP Error Code | SDK API errorId | SDK API errorMessage |
|---|---|---|---|
1 | 500 | 1001 | Internal error message: internal server error |
2 | 400 | 11001 | VM group name is required |
3 | 400 | 11001 | Inspection mode is required |
4 | 400 | 11001 | Invalid Inspection mode, it should be one of: <valid list> |
5 | 400 | 11001 | Traffic processing is required |
6 | 400 | 11001 | Invalid traffic processing, it should be one of: <list> |
7 | 400 | 11001 | Old VM group name is required |