doc-exports/docs/vpn/api-ref/vpn_api_0019.html
Hongwei, King Wang 32c06a10a2 vpn_api
Reviewed-by: Sarda, Priya <prsarda@noreply.gitea.eco.tsi-dev.otc-service.com>
Co-authored-by: Hongwei, King Wang <king.wanghongwei@huawei.com>
Co-committed-by: Hongwei, King Wang <king.wanghongwei@huawei.com>
2024-08-15 14:18:28 +00:00

179 lines
18 KiB
HTML

<a name="EN-US_TOPIC_0000001854089185"></a><a name="EN-US_TOPIC_0000001854089185"></a>
<h1 class="topictitle1">Querying the AZs of VPN Gateways</h1>
<div id="body8662426"><div class="section" id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_section20114008"><h4 class="sectiontitle">Function</h4><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p55391411697">This API is used to query the AZs of VPN gateways.</p>
</div>
<div class="section" id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_section18104173342818"><h4 class="sectiontitle">Calling Method</h4><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p19989133162813">For details, see <a href="vpn_api_0008.html#EN-US_TOPIC_0000001807530276">Calling APIs</a>.</p>
</div>
<div class="section" id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_section46808346"><h4 class="sectiontitle">URI</h4><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p9646523164810">GET /v5/{project_id}/vpn-gateways/availability-zones</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_table3672032" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row10026740"><th align="left" class="cellrowborder" valign="top" width="20.61793820617938%" id="mcps1.3.3.3.2.5.1.1"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p6859639">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="19.02809719028097%" id="mcps1.3.3.3.2.5.1.2"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p179611479215">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="11.798820117988202%" id="mcps1.3.3.3.2.5.1.3"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p18759866">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="48.555144485551445%" id="mcps1.3.3.3.2.5.1.4"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p43154149">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row5825185"><td class="cellrowborder" valign="top" width="20.61793820617938%" headers="mcps1.3.3.3.2.5.1.1 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p2077973">project_id</p>
</td>
<td class="cellrowborder" valign="top" width="19.02809719028097%" headers="mcps1.3.3.3.2.5.1.2 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p177965479212">String</p>
</td>
<td class="cellrowborder" valign="top" width="11.798820117988202%" headers="mcps1.3.3.3.2.5.1.3 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p34098154">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="48.555144485551445%" headers="mcps1.3.3.3.2.5.1.4 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p199639252285">Specifies a project ID. You can obtain the project ID by referring to <a href="vpn_api_0051.html#EN-US_TOPIC_0000001807530332">Obtaining the Project ID</a>.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_section18621933"><h4 class="sectiontitle">Request</h4><ul id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_ul5992193374713"><li id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_li177271541618">Request parameters<p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1756345466"><a name="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_li177271541618"></a><a name="en-us_topic_0000001543354004_li177271541618"></a>None</p>
</li><li id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_li15802101475419">Example request<pre class="screen" id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_screen1778465375316">GET https://{Endpoint}/v5/{project_id}/vpn-gateways/availability-zones</pre>
</li></ul>
</div>
<div class="section" id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_section33379675"><h4 class="sectiontitle">Response</h4><ul id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_ul2144514204819"><li id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_li61441714114816">Response parameters<p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p955814111914"><a name="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_li61441714114816"></a><a name="en-us_topic_0000001543354004_li61441714114816"></a>Returned status code 200: successful operation</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_table72052" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Parameters in the response body</caption><thead align="left"><tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row11558124116915"><th align="left" class="cellrowborder" valign="top" width="22.220000000000002%" id="mcps1.3.5.2.1.2.2.4.1.1"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1155914418910">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="22.220000000000002%" id="mcps1.3.5.2.1.2.2.4.1.2"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p205607411697">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="55.559999999999995%" id="mcps1.3.5.2.1.2.2.4.1.3"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p3561741790">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row1855919411193"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p184632119203">availability_zones</p>
</td>
<td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.2.2.4.1.2 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p17463191118209"><a href="#EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_table72053">AvailabilityZones</a> object</p>
</td>
<td class="cellrowborder" valign="top" width="55.559999999999995%" headers="mcps1.3.5.2.1.2.2.4.1.3 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1156324113917">Specifies the list of AZs.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row11517195205117"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1044574416511">request_id</p>
</td>
<td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.2.2.4.1.2 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1151785155116">String</p>
</td>
<td class="cellrowborder" valign="top" width="55.559999999999995%" headers="mcps1.3.5.2.1.2.2.4.1.3 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p75177595117">Specifies a request ID.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_table72053"></a><a name="en-us_topic_0000001543354004_table72053"></a><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_table72053" frame="border" border="1" rules="all"><caption><b>Table 3 </b>AvailabilityZones</caption><thead align="left"><tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row956412411098"><th align="left" class="cellrowborder" valign="top" width="22.220000000000002%" id="mcps1.3.5.2.1.3.2.4.1.1"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p956544113917">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="22.220000000000002%" id="mcps1.3.5.2.1.3.2.4.1.2"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p11565741891">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="55.559999999999995%" id="mcps1.3.5.2.1.3.2.4.1.3"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p75663418912">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row579017487427"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p147904481429">basic</p>
</td>
<td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p17620112315438"><a href="#EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_table72054">VpnGatewayAvailabilityZones</a> object</p>
</td>
<td class="cellrowborder" valign="top" width="55.559999999999995%" headers="mcps1.3.5.2.1.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1229216266434">Indicates that the specification of VPN gateways is Basic.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row6564134114917"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p115674411992">professional1</p>
</td>
<td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p5465121192013"><a href="#EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_table72054">VpnGatewayAvailabilityZones</a> object</p>
</td>
<td class="cellrowborder" valign="top" width="55.559999999999995%" headers="mcps1.3.5.2.1.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p656812418910">Indicates that the specification of VPN gateways is Professional1.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row667203522715"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p209821949172720">Professional1-NonFixedIP</p>
</td>
<td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1898274992714"><a href="#EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_table72054">VpnGatewayAvailabilityZones</a> object</p>
</td>
<td class="cellrowborder" valign="top" width="55.559999999999995%" headers="mcps1.3.5.2.1.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p14982154942710">Indicates that the specification of VPN gateways is Professional1-NonFixedIP.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row125645416917"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1656815411293">professional2</p>
</td>
<td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1613722911249"><a href="#EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_table72054">VpnGatewayAvailabilityZones</a> object</p>
</td>
<td class="cellrowborder" valign="top" width="55.559999999999995%" headers="mcps1.3.5.2.1.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p12570441590">Indicates that the specification of VPN gateways is Professional2.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row36174452711"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p14160752162710">Professional2-NonFixedIP</p>
</td>
<td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1516013521273"><a href="#EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_table72054">VpnGatewayAvailabilityZones</a> object</p>
</td>
<td class="cellrowborder" valign="top" width="55.559999999999995%" headers="mcps1.3.5.2.1.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1160105215278">Indicates that the specification of VPN gateways is Professional2-NonFixedIP.</p>
</td>
</tr>
</tbody>
</table>
</div>
<p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_li1131111619251p0">The supported specification options are subject to the value range of the <strong id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_b22971934141019">Specification</strong> parameter on the page for creating a VPN gateway on the VPN console.</p>
<div class="tablenoborder"><a name="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_table72054"></a><a name="en-us_topic_0000001543354004_table72054"></a><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_table72054" frame="border" border="1" rules="all"><caption><b>Table 4 </b>VpnGatewayAvailabilityZones</caption><thead align="left"><tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row1457114113912"><th align="left" class="cellrowborder" valign="top" width="22.220000000000002%" id="mcps1.3.5.2.1.5.2.4.1.1"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1857214116916">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="22.220000000000002%" id="mcps1.3.5.2.1.5.2.4.1.2"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1357216411198">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="55.559999999999995%" id="mcps1.3.5.2.1.5.2.4.1.3"><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p175739411899">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row1557164116917"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.5.2.4.1.1 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p1457320417916">vpc</p>
</td>
<td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.5.2.4.1.2 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p7574204110912">Array of String</p>
</td>
<td class="cellrowborder" valign="top" width="55.559999999999995%" headers="mcps1.3.5.2.1.5.2.4.1.3 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p19575841994">Specifies the list of AZs for VPN gateways associated with VPCs.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_row6571194114919"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.5.2.4.1.1 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p357517412913">er</p>
</td>
<td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.5.2.4.1.2 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p15761741095">Array of String</p>
</td>
<td class="cellrowborder" valign="top" width="55.559999999999995%" headers="mcps1.3.5.2.1.5.2.4.1.3 "><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p257716418919">Specifies the list of AZs for VPN gateways associated with enterprise routers.</p>
</td>
</tr>
</tbody>
</table>
</div>
</li><li id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_li10266184018544">Example response<pre class="screen" id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_screen678017232489">{
"availability_zones": {
"basic": {
<span id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_ph16967115735318"> "vpc": ["eu-de-01", "eu-de-02"],</span>
"er": []
},
"professional1": {
<span id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_ph06316166518">,</span>
<span id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_ph865141675110"> "vpc": ["eu-de-01", "eu-de-02"],</span><span id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_ph06551635118"></span>
<span id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_ph366181625111"> "er": ["eu-de-01", "eu-de-02"]</span>
},
"professional2": {
<span id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_ph12503192185115"> "vpc": ["eu-de-01", "eu-de-02"],</span>
<span id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_ph950592118513"> "er": ["eu-de-01", "eu-de-02"]</span>
},
"Professional1-NonFixedIP": {
"vpc": [],
"er": []
},
"Professional2-NonFixedIP": {
"vpc": [],
"er": []
},
"gm": {
"vpc": [],
"er": []
}
},
"request_id": "b60309ab-812c-4269-9de4-fb9a65e6db16"
}</pre>
</li></ul>
</div>
<div class="section" id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_section31981619"><h4 class="sectiontitle">Status Codes</h4><p id="EN-US_TOPIC_0000001854089185__en-us_topic_0000001543354004_p18112112662914">For details, see <a href="vpn_api_0052.html#EN-US_TOPIC_0000001807370508">Status Codes</a>.</p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="vpn_api_0013.html">VPN Gateway</a></div>
</div>
</div>