This API has been deprecated. We recommend migrating to Vpc(2016-04-28) - DeleteVSwitch for enhanced functionality and continued support. While the deprecated API remains temporarily accessible, no further updates or bug fixes will be provided.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
vpc:DeleteVSwitch |
delete |
*VSwitch
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| VSwitchId |
string |
Yes |
||
| RegionId |
string |
No |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
Examples
Success response
JSON format
{
"RequestId": ""
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | IncorrectVSwitchStatus | vpc subnet status not working. | |
| 400 | DependencyViolation | Specified object has dependent resources. | Resources deployed in the vSwitch are not deleted and the vSwitch cannot be deleted. Delete the resources deployed in the VPC before you can delete the VPC. |
| 400 | IncorrectRouteEntryStatus | Some route entry status blocked this operation. | The operation is not supported while the route table contains routes that are in the Pending or Modifying state. |
| 400 | DependencyViolation.HaVip | VSwitch cannot be deleted when there are some HaVip dependent with it. | The vSwitch is associated with a HAVIP and cannot be deleted. |
| 400 | MissingParameter | Miss mandatory parameter. | Required parameters must be specified. |
| 400 | TaskConflict | The operation is too frequent, TaskConflict. | |
| 400 | DependencyViolation.RouteTable | VSwitch cannot be deleted when associated with route table | |
| 400 | DependencyViolation.Snat | VSwitch cannot be deleted when has snat routeEntry. | |
| 400 | DeleteVSwitch.IncorrectStatus.cbnStatus | Current CBN status does not support this operation. | |
| 400 | AttrMismatching.NaclAndBindInstance | The network acl and resource not in same vpc. | |
| 400 | InvalidResource.NotBinding | The resource has not been binded. | |
| 400 | DependencyViolation.SnatEntry | VSwitch cannot be deleted when snat entry exist. | |
| 400 | DependencyViolation.NetworkAcl | VSwitch cannot be deleted when network acl exist. | |
| 400 | DependencyViolation.EnhancedNatgw | VSwitch cannot be deleted when enhanced NAT gateway exists. | |
| 400 | InvalidVSwitchId.NotFound | VSwitch not exist. | The specified vSwitch does not exist. |
| 404 | Forbidden.RegionNotFound | Specified instance is not found during access authentication. | |
| 404 | IncorrectVSwitchId | Specified vSwtich instance is not found during access authentication. | |
| 404 | InvalidVSwitchId.NotFound | VSwitch not exist. | |
| 404 | IncorrectStatus | Vswtich status not stable. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.