Deletes a high-availability virtual IP address (HaVip).
Operation description
When you call this operation, take note of the following rules:
-
The HaVip must be in the available state before it can be deleted.
-
Make sure that no routes are destined for the HaVip.
-
Make sure that no elastic IP addresses (EIPs) are associated with the HaVip.
-
DeleteHaVip is an asynchronous operation. After a request is sent, the system returns a request ID while deleting the HaVip in the background. Call the DescribeHaVips operation to query the status of an HaVip:
- The Deleting state indicates the HaVip is being deleted.
- If no HaVip is found, the HaVip is deleted.
-
You cannot repeatedly call the DeleteHaVip operation to delete the same HaVip.
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- For mandatory resource types, indicate with a prefix of * .
- If the permissions cannot be granted at the resource level,
All Resourcesis used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
| Operation | Access level | Resource type | Condition key | Associated operation |
|---|---|---|---|---|
| vpc:DeleteHaVip | delete | *HaVip acs:vpc:{#regionId}:{#accountId}:havip/{#HaVipId} |
| none |
Request parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
| ClientToken | string | No | The client token that is used to ensure the idempotence of the request. You can use the client to generate the value, but you must make sure that it is unique among different requests. The client token can contain only ASCII characters. Note
If you do not set this parameter, the system uses RequestId as ClientToken. The value of RequestId in each API request may be different.
| 0c593ea1-3bea-11e9-b96b-88e9fe637760 |
| RegionId | string | Yes | The region where the HaVip resides. Call the DescribeRegions operation to query the region list. | cn-shanghai |
| HaVipId | string | Yes | The ID of the HaVip that you want to delete. | havip-2zeo05qre24nhrqpy**** |
Response parameters
Examples
Sample success responses
JSONformat
{
"RequestId": "C44F62BE-9CE7-4277-B117-69243F3988BF"
}Error codes
| HTTP status code | Error code | Error message | Description |
|---|---|---|---|
| 400 | IncorrectStatus | HaVip can be deleted only when it is status is Available. | Failed to delete the HAVIP. You can delete the HAVIP only when its status is available. |
| 400 | DependencyViolation.HaVipReferedByRouteEntry | HaVip cannot be deleted when it is refered by a route table entry as next hop. | The HAVIP serves as the next hop of a route entry and cannot be deleted. You must delete the route entry before you can delete the HAVIP. |
| 400 | DependencyViolation.HaVipAssociatedWithEIP | HaVip cannot be deleted when it is associated with EIP. | The HAVIP is associated with an EIP and cannot be deleted. |
| 400 | IncorrectHaVipStatus | HaVip?s status is invalid. | - |
| 400 | Forbidden.HaVip | No permissions to perform operations on HAVIPs. Please apply for privilege--vpc_privilege_allow_buy_havip_instance. | The error message returned because you do not have the permissions to manage the HAVIP. Go to the Quota Center page to acquire the permissions. |
| 404 | InvalidRegionId.NotFound | The RegionId provided does not exist in our records. | The RegionId parameter is set to an invalid value. Specify a valid value and try again. |
| 404 | InvalidHaVipId.NotFound | The specified HaVip does not exist in the specified region. | The specified HAVIP does not exist in the specified region. Check whether the specified region is correct. |
For a list of error codes, visit the Service error codes.
Change history
| Change time | Summary of changes | Operation |
|---|
