All Products
Search
Document Center

Alibaba Cloud Service Mesh:DescribeVSwitches

Last Updated:Mar 05, 2024

Queries a list of vSwitches that are deployed in a specified virtual private cloud (VPC) in a region.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
RegionIdstringYes

The region ID.

cn-hangzhou
VpcIdstringYes

The VPC ID.

vpc-bp17gig441u0msmd78****

Response parameters

ParameterTypeDescriptionExample
object

Schema of Response

TotalCountinteger

The total number of vSwitches that are deployed in the VPC in the region. This parameter is optional and is not returned by default.

10
RequestIdstring

The request ID.

BD65C0AD-D3C6-48D3-8D93-38D2015C****
NextTokenstring

A pagination token. It can be used in the next request to retrieve a new page of results. If NextToken is empty, no next page exists.

“”
MaxResultsinteger

The maximum number of entries returned.

10
VSwitchesobject []

The available vSwitches.

VpcIdstring

The ID of the VPC to which the vSwitch belongs.

vpc-bp17gig441u0msmd6****
VSwitchIdstring

The vSwitch ID.

vsw-bp1g24p9no0iqir46****
Statusstring

The state of the vSwitch. Valid values:

  • Pending: The vSwitch is being configured.
  • Available: The vSwitch is available.
Available
IsDefaultboolean

Indicates whether the vSwitch is the default vSwitch. Valid values:

  • true
  • false
false
VSwitchNamestring

The name of the vSwitch.

vsw-test
ZoneIdstring

The zone to which the switch belongs.

cn-hangzhou-k

Examples

Sample success responses

JSONformat

{
  "TotalCount": 10,
  "RequestId": "BD65C0AD-D3C6-48D3-8D93-38D2015C****",
  "NextToken": "“”",
  "MaxResults": 10,
  "VSwitches": [
    {
      "VpcId": "vpc-bp17gig441u0msmd6****",
      "VSwitchId": "vsw-bp1g24p9no0iqir46****",
      "Status": "Available",
      "IsDefault": false,
      "VSwitchName": "vsw-test",
      "ZoneId": "cn-hangzhou-k"
    }
  ]
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2023-04-12The response structure of the API has changedsee changesets
Change itemChange content
Output ParametersThe response structure of the API has changed.