Queries the IPsec-VPN connections associated with a transit router.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | DescribeVpnAttachments |
The operation that you want to perform. Set the value to DescribeVpnAttachments. |
RegionId | String | Yes | ap-southeast-2 |
The ID of the region to which the IPsec-VPN connection belongs. You can call the DescribeRegions operation to query the most recent region list. |
PageNumber | Integer | No | 1 |
The number of the page to return. Default value: 1. |
PageSize | Integer | No | 10 |
The number of entries to return on each page. Default value: 10. Valid values: 1 to 50. |
VpnConnectionId | String | No | vco-p0w2jpkhi2eeop6q6**** |
The ID of the IPsec-VPN connection. Note If you do not specify an ID, the system queries all IPsec-VPN connections associated
with the transit router in the region.
|
AttachType | String | No | CEN |
The type of resource that is associated with the IPsec-VPN connection. Default value: CEN. Set the value to CEN, which specifies to query IPsec-VPN connections associated with the transit router. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
RequestId | String | 9F0725BB-186A-3564-91C3-AAE48042F853 |
The ID of the request. |
PageSize | Integer | 10 |
The number of entries returned per page. |
PageNumber | Integer | 1 |
The page number of the returned page. |
TotalCount | Integer | 1 |
The number of entries returned. |
VpnAttachments | Array of vpnAttachment |
The list of IPsec-VPN connections associated with the transit router. |
|
InstanceId | String | vco-p0w2jpkhi2eeop6q6**** |
The ID of the IPsec-VPN connection. |
Name | String | nametest1 |
The name of the IPsec-VPN connection. |
Description | String | desctest |
The description of the IPsec-VPN connection. |
AttachType | String | CEN |
The type of resource that is associated with the IPsec-VPN connection. The value is set to CEN, which indicates that the IPsec-VPN connection is associated with a transit router. |
TransitRouterId | String | tr-p0wkh4yryb1dnanqw**** |
The ID of the transit router with which the IPsec-VPN connection is associated. |
TransitRouterName | String | nametest2 |
The name of the transit router. |
CrossAccountAuthorized | Boolean | false |
Indicates whether the IPsec-VPN connection is associated with a transit router that belongs to another Alibaba Cloud account. Valid values:
|
Examples
Sample requests
http(s)://[Endpoint]/?Action=DescribeVpnAttachments
&RegionId=ap-southeast-2
&PageNumber=1
&PageSize=10
&VpnConnectionId=vco-p0w2jpkhi2eeop6q6****
&AttachType=CEN
&<Common request parameters>
Sample success responses
XML
format
HTTP/1.1 200 OK
Content-Type:application/xml
<DescribeVpnAttachmentsResponse>
<RequestId>9F0725BB-186A-3564-91C3-AAE48042F853</RequestId>
<PageSize>10</PageSize>
<PageNumber>1</PageNumber>
<TotalCount>1</TotalCount>
<VpnAttachments>
<InstanceId>vco-p0w2jpkhi2eeop6q6****</InstanceId>
<Name>nametest1</Name>
<AttachType>CEN</AttachType>
<TransitRouterId>tr-p0wkh4yryb1dnanqw****</TransitRouterId>
<TransitRouterName>nametest2</TransitRouterName>
<CrossAccountAuthorized>false</CrossAccountAuthorized>
</VpnAttachments>
</DescribeVpnAttachmentsResponse>
JSON
format
HTTP/1.1 200 OK
Content-Type:application/json
{
"RequestId" : "9F0725BB-186A-3564-91C3-AAE48042F853",
"PageSize" : 10,
"PageNumber" : 1,
"TotalCount" : 1,
"VpnAttachments" : [ {
"InstanceId" : "vco-p0w2jpkhi2eeop6q6****",
"Name" : "nametest1",
"AttachType" : "CEN",
"TransitRouterId" : "tr-p0wkh4yryb1dnanqw****",
"TransitRouterName" : "nametest2",
"CrossAccountAuthorized" : false
} ]
}
Error codes
For a list of error codes, visit the API Error Center.