forked from docs/doc-exports
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>
111 lines
11 KiB
HTML
111 lines
11 KiB
HTML
<a name="EN-US_TOPIC_0000001807530316"></a><a name="EN-US_TOPIC_0000001807530316"></a>
|
|
|
|
<h1 class="topictitle1">Querying Project Tags</h1>
|
|
<div id="body8662426"><div class="section" id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_section20114008"><h4 class="sectiontitle">Function</h4><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p156141423912">This API is used to query all tags of a specified resource type in a specified project of a tenant.</p>
|
|
</div>
|
|
<div class="section" id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_section18104173342818"><h4 class="sectiontitle">Calling Method</h4><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_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_0000001807530316__en-us_topic_0000001806475629_section46808346"><h4 class="sectiontitle">URI</h4><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p832123135010">GET /v5/{project_id}/{resource_type}/tags</p>
|
|
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_table92238" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_row12907152516281"><th align="left" class="cellrowborder" valign="top" width="19.607843137254903%" id="mcps1.3.3.3.2.5.1.1"><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p1790862522818">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="19.607843137254903%" id="mcps1.3.3.3.2.5.1.2"><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p1590862511281">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="11.76470588235294%" id="mcps1.3.3.3.2.5.1.3"><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p190822518281">Mandatory</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="49.01960784313725%" id="mcps1.3.3.3.2.5.1.4"><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p11908132532819">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_row19907325142817"><td class="cellrowborder" valign="top" width="19.607843137254903%" headers="mcps1.3.3.3.2.5.1.1 "><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p69098254284">project_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="19.607843137254903%" headers="mcps1.3.3.3.2.5.1.2 "><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p090912572820">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="11.76470588235294%" headers="mcps1.3.3.3.2.5.1.3 "><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p79091425122815">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="49.01960784313725%" headers="mcps1.3.3.3.2.5.1.4 "><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_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>
|
|
<tr id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_row129071625122816"><td class="cellrowborder" valign="top" width="19.607843137254903%" headers="mcps1.3.3.3.2.5.1.1 "><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p623155842816">resource_type</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="19.607843137254903%" headers="mcps1.3.3.3.2.5.1.2 "><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p223105819284">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="11.76470588235294%" headers="mcps1.3.3.3.2.5.1.3 "><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p152315585286">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="49.01960784313725%" headers="mcps1.3.3.3.2.5.1.4 "><ul id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_ul93453614117"><li id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_li43451661818">Specifies the resource type.</li><li id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_li16527151316115">The value can be <strong id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_b06410598511">vpn-gateway</strong>, <strong id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_b1964205945115">customer-gateway</strong>, or <strong id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_b136417593510">vpn-connection</strong>.</li></ul>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_section18621933"><h4 class="sectiontitle">Request</h4><ul id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_ul5992193374713"><li id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_li6680921111317">Request parameters<p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p0944102114137"><a name="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_li6680921111317"></a><a name="en-us_topic_0000001806475629_li6680921111317"></a>None</p>
|
|
</li><li id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_li13171757192219">Example request<pre class="screen" id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_screen1778465375316">GET https://{Endpoint}/v5/{project_id}/{resource_type}/tags</pre>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_section33379675"><h4 class="sectiontitle">Response</h4><ul id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_ul2144514204819"><li id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_li61441714114816">Response parameters<p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p76201023211"><a name="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_li61441714114816"></a><a name="en-us_topic_0000001806475629_li61441714114816"></a>Returned status code 200: successful query</p>
|
|
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_table1877709" 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_0000001807530316__en-us_topic_0000001806475629_row135121628161013"><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_0000001807530316__en-us_topic_0000001806475629_p151362812105">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_0000001807530316__en-us_topic_0000001806475629_p145138284106">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_0000001807530316__en-us_topic_0000001806475629_p105135287107">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_row16512202861010"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.2.2.4.1.1 "><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p175131328161011">tags</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_0000001807530316__en-us_topic_0000001806475629_p175141128101016">Array of <a href="#EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_table1877710">ResourceTag</a> objects</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_0000001807530316__en-us_topic_0000001806475629_p1351482821011">Specifies the list of resource tags.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="tablenoborder"><a name="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_table1877710"></a><a name="en-us_topic_0000001806475629_table1877710"></a><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_table1877710" frame="border" border="1" rules="all"><caption><b>Table 3 </b>ResourceTag</caption><thead align="left"><tr id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_row151517285103"><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_0000001807530316__en-us_topic_0000001806475629_p1551612812109">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_0000001807530316__en-us_topic_0000001806475629_p18516828161012">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_0000001807530316__en-us_topic_0000001806475629_p155161228131016">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_row14515182820109"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p1751752810102">key</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_0000001807530316__en-us_topic_0000001806475629_p3517102810103">String</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_0000001807530316__en-us_topic_0000001806475629_p1128123294012">Indicates a tag key.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_row65151128111014"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_p1051812810103">values</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_0000001807530316__en-us_topic_0000001806475629_p10518182817102">Array of String</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_0000001807530316__en-us_topic_0000001806475629_p14157172813400">Indicates a tag value.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li><li id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_li7698512202311">Example response<pre class="screen" id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_screen678017232489">{
|
|
"tags":[
|
|
{
|
|
"key":"key1",
|
|
"values":["value1"]
|
|
}
|
|
]
|
|
}</pre>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_section31981619"><h4 class="sectiontitle">Status Codes</h4><p id="EN-US_TOPIC_0000001807530316__en-us_topic_0000001806475629_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_0060.html">Tags</a></div>
|
|
</div>
|
|
</div>
|
|
|