UpdateVip

API Request

URLs
PUT zstack/v1/vips/{uuid}/actions
Headers
Authorization: OAuth the-session-uuid
Body
{
  "updateVip": {
    "name": "new name"
  },
  "systemTags": [],
  "userTags": []
}
Note: In the preceding sample, both systemTags and userTags are optional. These two fields can be included in the body structure.
Curl Sample
curl -H "Content-Type: application/json;charset=UTF-8" \
-H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \
-X PUT -d '{"updateVip":{"name":"new name"}}' \
http://localhost:8080/zstack/v1/vips/cb7f47adc9e0386d952990c88835048c/actions
Request Parameters
Name Type Location Description Optional Value Starting Version
uuid String url The resource UUID. 0.6
name String body (contained in the updateVip structure) Optional. The resource name. 0.6
description String body (contained in the updateVip structure) Optional. The detailed description of the resource. 0.6
systemTags List body Optional. The system tags. 0.6
userTags List body Optional. The user tags. 0.6

API Response

Sample Response
{
  "inventory": {
    "uuid": "afc62fc544524344804c558156b57938",
    "name": "new name",
    "ipRangeUuid": "cbe101ec40844785ac64f0693e56122a",
    "l3NetworkUuid": "06272fa02c0b4776a0fb1bab6171ba34",
    "ip": "192.168.0.1",
    "state": "Enabled",
    "gateway": "127.0.0.1",
    "netmask": "255.255.0.0",
    "peerL3NetworkUuid": [
      "e35c8f6a65d14e8492e6fb72382dc1b4"
    ]
  }
}
Name Type Description Starting Version
error ErrorCode The error code. If not null, the operation fails, or vice versa. For more information, see error. 0.6
inventory VipInventory See inventory. 0.6
#error
Name Type Description Starting Version
code String The error code, which is a numbered or alphanumeric code that specifies an error. For example, SYS.1000, HOST.1001. 0.6
description String The brief description of the error. 0.6
details String The details about the error. 0.6
elaboration String The reserved field. Default value: null. 0.6
opaque LinkedHashMap The reserved field. Default value: null. 0.6
cause ErrorCode The root error, which is the associated root cause of the current error. If no root error exists, this parameter is null. 0.6
#inventory
Name Type Description Starting Version
uuid String The resource UUID. 0.6
name String The resource name. 0.6
description String The detailed description of the resource. 0.6
l3NetworkUuid String The L3 network UUID. 0.6
ip String The IP address of the IPv4 type. 0.6
state String The state of the VIP, including Enabled and Enabled. 0.6
gateway String The gateway. 0.6
netmask String The netmask. 0.6
prefixLen String The prefix length. 3.1.0
serviceProvider String The service provider that provides the VIP service. 0.6
peerL3NetworkUuid String The L3 private network UUID or the VPC L3 network UUID. 0.6
useFor String The usage, such as port forwarding. 0.6
createDate Timestamp The creation date. 0.6
lastOpDate Timestamp The last operation date. 0.6

SDK Sample

Java SDK
UpdateVipAction action = new UpdateVipAction();
action.uuid = "dbea243ee5c04eb5b68f8905baec42c6";
action.name = "new name";
action.sessionId = "b9f7110e36c147e7abcfbd0215c56368";
UpdateVipAction.Result res = action.call();
Python SDK
UpdateVipAction action = UpdateVipAction()
action.uuid = "620313f8f6724571addc8ef00959d951"
action.name = "new name"
action.sessionId = "4632313cde0a4cbaa67c7ff2109ebe60"
UpdateVipAction.Result res = action.call()