Query VPC List
Last Updated:2021-03-23
Description
Query the VPC list information.
Request Structure
GET /v{version}/vpc?marker=vpc-IyWRtII7&maxKeys=1 HTTP/1.1
Host: bcc.bj.baidubce.com
Authorization: authorization string
Request Header
There are no other special headers except the public headers.
Request Parameter
Parameter name | Type | Required or not | Parameter position | Description |
---|---|---|---|---|
version | String | Yes | URL parameter | API version number |
marker | String | No | Query parameter | The starting location of query for batch acquisition of lists, and is one string generated by the system. |
maxKeys | Integer | No | Query parameter | The maximum quantity contained in each page. The maximum quantity usually does not exceed 1000. The default is 1000 |
isDefault | Boolean | No | Query parameter | Default VPC? true: Yes, optional values: True, false; return all VPCs when this parameter is not filled in. |
Return Header
There are no other special headers except the public headers.
Return Parameter
Parameter name | Type | Description |
---|---|---|
marker | String | It marks the queried starting position. |
isTruncated | boolean | True means there are additional data in the following pages and false means the current page is the last page. |
nextMarker | String | The marker value requiring to be passed in order to acquire the next page. The domain doesn't appear when isTruncated is false. |
maxKeys | int | Maximum number contained in each page. |
vpcs | List<Vpc> | VPC list |
Request Example
GET /v{version}/vpc marker=vpc-IyWRtII7&maxKeys=1 HTTP/1.1
Host: bcc.bj.baidubce.com
ContentType: application/json
Authorization: bce auth v1/f81d3b34e48048fbb2634dc7882d7e21/2017 03 11T04:17:29Z/3600/host/74c506f68c65e26c633bfa104c863fffac5190fdec1ec24b7c03eb5d67d2e1de
Return Example
HTTP/1.1 200 OK
x-bce-request-id: 1214cca7 4ad5 451d 9215 71cb844c0a50
Date: Thu, 16 Mar 2017 06:29:48 GMT
Content Type: application/json;charset=UTF 8
Server: BWS
{
"nextMarker": "vpc-xktdeMSf",
"marker": "vpc-IyWRtII7",
"maxKeys": 1,
"isTruncated": true,
"vpcs": [
{
"vpcId': "vpc-IyWRtII7",
"name": "VPC Name",
"isDefault": True,
"cidr": "0.0.0.0/0",
"description": "default",
"tags":[
{
"tagKey": "tagKey",
"tagValue": "tagValue"
}
]
}
]
}