doc-exports/docs/natgw/api-ref/nat_api_0012.html
Qin Ying, Fan 388d58fc5d NATGW API 20230922 version
Reviewed-by: Sarda, Priya <prsarda@noreply.gitea.eco.tsi-dev.otc-service.com>
Co-authored-by: Qin Ying, Fan <fanqinying@huawei.com>
Co-committed-by: Qin Ying, Fan <fanqinying@huawei.com>
2024-01-16 14:31:30 +00:00

313 lines
24 KiB
HTML

<a name="nat_api_0012"></a><a name="nat_api_0012"></a>
<h1 class="topictitle1">Querying DNAT Rules</h1>
<div id="body1516089194257"><div class="section" id="nat_api_0012__section28610428164132"><h4 class="sectiontitle">Function</h4><p id="nat_api_0012__p11319755164149">This API is used to query DNAT rules.</p>
</div>
<div class="section" id="nat_api_0012__section19503903164158"><h4 class="sectiontitle">URI</h4><p id="nat_api_0012__p1050112546264">GET /v2.0/dnat_rules</p>
<div class="note" id="nat_api_0012__note736085482614"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="nat_api_0012__p145011054112617">You can type a question mark (?) and an ampersand (&amp;) at the end of the URI to define different search criteria. All optional parameters can be filtered. For details, see the example request.</p>
</div></div>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="nat_api_0012__table93762054132613" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="nat_api_0012__row9501145413265"><th align="left" class="cellrowborder" valign="top" width="23.23%" id="mcps1.3.2.4.2.4.1.1"><p id="nat_api_0012__p550115415265">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="19.189999999999998%" id="mcps1.3.2.4.2.4.1.2"><p id="nat_api_0012__p3501754122611">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="57.58%" id="mcps1.3.2.4.2.4.1.3"><p id="nat_api_0012__p250105419269">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="nat_api_0012__row14501165412613"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p75013243343">id</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p1850122411341">String</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p195072453418">Specifies the DNAT rule ID.</p>
</td>
</tr>
<tr id="nat_api_0012__row741582519283"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p1146353082810">limit</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p44641230172812">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p1946483042811">Specifies the number of records returned on each page.</p>
</td>
</tr>
<tr id="nat_api_0012__row105011454132610"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p1501024133416">tenant_id</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p8501524153419">String</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p150524123413">Specifies the project ID.</p>
</td>
</tr>
<tr id="nat_api_0012__row650115472619"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p650924193418">nat_gateway_id</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p750182443418">String</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p1451624163419">Specifies the NAT gateway ID.</p>
</td>
</tr>
<tr id="nat_api_0012__row1501125413265"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p35192443411">port_id</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p17514241349">String</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p135110246348">Specifies the port ID of the cloud server (<span id="nat_api_0012__text47731822154111">ECS</span> or <span id="nat_api_0012__text14773162215413">BMS</span>).</p>
</td>
</tr>
<tr id="nat_api_0012__row16501354192619"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p1651182413349">private_ip</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p195192414349">String</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p15511224133415">Specifies the private IP address, for example, the IP address of an on-premises network connected by a Direct Connect connection.</p>
</td>
</tr>
<tr id="nat_api_0012__row1150185452610"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p5511424123420">internal_service_port</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p105119243343">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p7513246347">Specifies the port number used by the cloud server (<span id="nat_api_0012__text14746833184219">ECS</span> or <span id="nat_api_0012__text1174693317425">BMS</span>) to provide services for external systems.</p>
</td>
</tr>
<tr id="nat_api_0012__row1950195417261"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p165122412348">floating_ip_id</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p851132413341">String</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p05119242344">Specifies the EIP ID.</p>
</td>
</tr>
<tr id="nat_api_0012__row18501454162610"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p16511224133414">floating_ip_address</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p5511224153414">String</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p1352324123412">Specifies the EIP address.</p>
</td>
</tr>
<tr id="nat_api_0012__row15501115452610"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p155262418349">external_service_port</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p052152410349">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p05210248347">Specifies the port for providing services for external systems.</p>
</td>
</tr>
<tr id="nat_api_0012__row15011954142618"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p552192443414">protocol</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p1666203645612">String</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p1152182413347">Specifies the protocol. TCP, UDP, and ANY are supported.</p>
<p id="nat_api_0012__p185242483420">The protocol number of TCP, UDP, and ANY are 6, 17, and 0, respectively.</p>
</td>
</tr>
<tr id="nat_api_0012__row13501165414269"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p4529244343">description</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p9525242343">String</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p165282423412">Provides supplementary information about the DNAT rule.</p>
</td>
</tr>
<tr id="nat_api_0012__row18532115313334"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p1252172410347">status</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p1852142423414">String</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><ul id="nat_api_0012__ul952182413342"><li id="nat_api_0012__li1152122463418">Specifies the status of the DNAT rule.</li><li id="nat_api_0012__li152624203419">For details about all its values, see <u id="nat_api_0012__u1752182473413"><u id="nat_api_0012__u105212413416"><a href="nat_api_0042.html">Resource Status Description</a></u></u>.</li></ul>
</td>
</tr>
<tr id="nat_api_0012__row359059183310"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p752122412345">admin_state_up</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p1764614265487">Boolean</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><ul id="nat_api_0012__ul71858556358"><li id="nat_api_0012__li132051838164415">Specifies whether the DNAT rule is enabled or disabled.</li><li id="nat_api_0012__li12205203804411">The value can be:<ul id="nat_api_0012__ul16205638124410"><li id="nat_api_0012__li16206163884415"><strong id="nat_api_0012__b337714410313">true</strong>: The DNAT rule is enabled.</li><li id="nat_api_0012__li102063382449"><strong id="nat_api_0012__b144324514320">false</strong>: The DNAT rule is disabled.</li></ul>
</li></ul>
</td>
</tr>
<tr id="nat_api_0012__row1768062193420"><td class="cellrowborder" valign="top" width="23.23%" headers="mcps1.3.2.4.2.4.1.1 "><p id="nat_api_0012__p195292413414">created_at</p>
</td>
<td class="cellrowborder" valign="top" width="19.189999999999998%" headers="mcps1.3.2.4.2.4.1.2 "><p id="nat_api_0012__p17521624103417">String</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.2.4.2.4.1.3 "><p id="nat_api_0012__p055611361601">Specifies when the DNAT rule was created (UTC time). Its value rounds to 6 decimal places for seconds. The format is yyyy-mm-dd hh:mm:ss.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="nat_api_0012__section2749321016454"><h4 class="sectiontitle">Request</h4><p id="nat_api_0012__p13242858164511">None</p>
</div>
<div class="section" id="nat_api_0012__section55770648164519"><h4 class="sectiontitle">Response</h4><p id="nat_api_0012__p1923717169275"><a href="#nat_api_0012__table47307406164538">Table 2</a> lists response parameter.</p>
<div class="tablenoborder"><a name="nat_api_0012__table47307406164538"></a><a name="table47307406164538"></a><table cellpadding="4" cellspacing="0" summary="" id="nat_api_0012__table47307406164538" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Response parameter</caption><thead align="left"><tr id="nat_api_0012__row43170063164538"><th align="left" class="cellrowborder" valign="top" width="20.73%" id="mcps1.3.4.3.2.4.1.1"><p id="nat_api_0012__p7114239164538">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="28.050000000000004%" id="mcps1.3.4.3.2.4.1.2"><p id="nat_api_0012__p39382504164538">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="51.22%" id="mcps1.3.4.3.2.4.1.3"><p id="nat_api_0012__p19483074164538">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="nat_api_0012__row34625156164538"><td class="cellrowborder" valign="top" width="20.73%" headers="mcps1.3.4.3.2.4.1.1 "><p id="nat_api_0012__p53174238164538">dnat_rules</p>
</td>
<td class="cellrowborder" valign="top" width="28.050000000000004%" headers="mcps1.3.4.3.2.4.1.2 "><p id="nat_api_0012__p12146041164538">Array(Object)</p>
</td>
<td class="cellrowborder" valign="top" width="51.22%" headers="mcps1.3.4.3.2.4.1.3 "><p id="nat_api_0012__p31957648164538">Specifies the DNAT rule objects. For details, see <a href="#nat_api_0012__table19520113319519">Table 3</a>.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="nat_api_0012__table19520113319519"></a><a name="table19520113319519"></a><table cellpadding="4" cellspacing="0" summary="" id="nat_api_0012__table19520113319519" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Description of the <strong id="nat_api_0012__b68466238532">dnat_rule</strong> field</caption><thead align="left"><tr id="nat_api_0012__row185205331254"><th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.4.4.2.4.1.1"><p id="nat_api_0012__p05291666">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.4.4.2.4.1.2"><p id="nat_api_0012__p75093619">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.4.4.2.4.1.3"><p id="nat_api_0012__p451917619">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="nat_api_0012__row15520133952"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p951910610">id</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p1656918614">String</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><p id="nat_api_0012__p051291561">Specifies the DNAT rule ID.</p>
</td>
</tr>
<tr id="nat_api_0012__row105201033858"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p254910616">tenant_id</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p1251899611">String</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><p id="nat_api_0012__p15895619">Specifies the project ID.</p>
</td>
</tr>
<tr id="nat_api_0012__row145201533552"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p7512916615">nat_gateway_id</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p155999619">String</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><p id="nat_api_0012__p1251091363">Specifies the NAT gateway ID.</p>
</td>
</tr>
<tr id="nat_api_0012__row65209331152"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p45892062">port_id</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p3517914615">String</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><p id="nat_api_0012__p1651197615">Specifies the port ID of the cloud server (<span id="nat_api_0012__text04654713425">ECS</span> or <span id="nat_api_0012__text446134784217">BMS</span>).</p>
</td>
</tr>
<tr id="nat_api_0012__row25205331457"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p1251911618">private_ip</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p1351091667">String</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><p id="nat_api_0012__p95891616">Specifies the private IP address, for example, the IP address of an on-premises network connected by a Direct Connect connection.</p>
</td>
</tr>
<tr id="nat_api_0012__row1052018331559"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p75194611">internal_service_port</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p951591063">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><p id="nat_api_0012__p14520920611">Specifies the port number used by the cloud server (<span id="nat_api_0012__text86317525424">ECS</span> or <span id="nat_api_0012__text18631165214429">BMS</span>) to provide services for external systems.</p>
</td>
</tr>
<tr id="nat_api_0012__row1752020331551"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p051991961">floating_ip_id</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p05109969">String</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><p id="nat_api_0012__p135997619">Specifies the EIP ID.</p>
</td>
</tr>
<tr id="nat_api_0012__row652015339517"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p9510911613">floating_ip_address</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p155189360">String</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><p id="nat_api_0012__p25297618">Specifies the EIP address.</p>
</td>
</tr>
<tr id="nat_api_0012__row1752013312513"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p175199763">external_service_port</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p1951396617">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><p id="nat_api_0012__p1557910616">Specifies the port for providing services for external systems.</p>
</td>
</tr>
<tr id="nat_api_0012__row752017339518"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p185591614">protocol</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p1251395611">String</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><p id="nat_api_0012__p4517918619">Specifies the protocol. TCP, UDP, and ANY are supported.</p>
<p id="nat_api_0012__p1551098611">The protocol number of TCP, UDP, and ANY are 6, 17, and 0, respectively.</p>
</td>
</tr>
<tr id="nat_api_0012__row7520143311514"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p125991664">description</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p4569262">String</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><p id="nat_api_0012__p4510915617">Provides supplementary information about the DNAT rule.</p>
</td>
</tr>
<tr id="nat_api_0012__row55358331458"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p353919612">status</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p85893612">String</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><ul id="nat_api_0012__ul6519962"><li id="nat_api_0012__li854917611">Specifies the status of the DNAT rule.</li><li id="nat_api_0012__li1451916612">For details about all its values, see <a href="nat_api_0042.html#nat_api_0042__table1390614366107">Table 1</a>.</li></ul>
</td>
</tr>
<tr id="nat_api_0012__row1353593311511"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p10529463">admin_state_up</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p12628475214">Boolean</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><ul id="nat_api_0012__ul2112113885720"><li id="nat_api_0012__li4113113855715">Specifies whether the DNAT rule is enabled or disabled.</li><li id="nat_api_0012__li4113138175718">The value can be:<ul id="nat_api_0012__ul17113838115713"><li id="nat_api_0012__li181131738165719"><strong id="nat_api_0012__b184941145142319">true</strong>: The DNAT rule is enabled.</li><li id="nat_api_0012__li1811383813571"><strong id="nat_api_0012__b1867424619232">false</strong>: The DNAT rule is disabled.</li></ul>
</li></ul>
</td>
</tr>
<tr id="nat_api_0012__row1953517336520"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.1 "><p id="nat_api_0012__p1050916613">created_at</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.2 "><p id="nat_api_0012__p4529368">String</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.4.2.4.1.3 "><p id="nat_api_0012__p74507428015">Specifies when the DNAT rule was created (UTC time). Its value rounds to 6 decimal places for seconds. The format is yyyy-mm-dd hh:mm:ss.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="nat_api_0012__section39793997164640"><h4 class="sectiontitle">Examples</h4><ul id="nat_api_0012__ul741114902713"><li id="nat_api_0012__li15411249152719">Example request<pre class="screen" id="nat_api_0012__screen45516234164713">GET https://{Endpoint}/v2.0/dnat_rules</pre>
</li></ul>
</div>
<ul id="nat_api_0012__ul92689322818"><li id="nat_api_0012__li162681332287">Example response<pre class="screen" id="nat_api_0012__screen30602842164738">{
"dnat_rules": [
{
"floating_ip_id": "bf99c679-9f41-4dac-8513-9c9228e713e1",
"status": "ACTIVE",
"description": "description",
"nat_gateway_id": "cda3a125-2406-456c-a11f-598e10578541",
"admin_state_up": true,
"port_id": "9a469561-daac-4c94-88f5-39366e5ea193",
"internal_service_port": 993,
"protocol": "tcp",
"tenant_id": "abc",
"created_at": "2017-11-15 15:44:42.595173",
"id": "79195d50-0271-41f1-bded-4c089b2502ff",
"floating_ip_address": "5.21.11.226",
"external_service_port": 242,
"private_ip": ""
},
{
"floating_ip_id": "cf99c679-9f41-4dac-8513-9c9228e713e1",
"status": "ACTIVE",
"description": "description",
"nat_gateway_id": "dda3a125-2406-456c-a11f-598e10578541",
"admin_state_up": true,
"port_id": "",
"private_ip": "192.168.1.100",
"internal_service_port": 0,
"protocol": "any",
"tenant_id": "abc",
"created_at": "2017-11-16 15:44:42.595173",
"id": "89195d50-0271-41f1-bded-4c089b2502ff",
"floating_ip_address": "5.21.11.227",
"external_service_port": 0
}
]
}</pre>
</li></ul>
<div class="section" id="nat_api_0012__section45841191164749"><h4 class="sectiontitle">Status Codes</h4><p id="nat_api_0012__p58526262195922">See <a href="nat_api_0038.html">Status Codes</a>.</p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="nat_api_0010.html">DNAT Rules</a></div>
</div>
</div>