doc-exports/docs/waf/api-ref/waf_02_0010.html
Li, Qiao 914011d51b waf_api_1109
Reviewed-by: Hasko, Vladimir <vladimir.hasko@t-systems.com>
Co-authored-by: Li, Qiao <qiaoli@huawei.com>
Co-committed-by: Li, Qiao <qiaoli@huawei.com>
2022-11-16 15:31:27 +00:00

101 lines
8.0 KiB
HTML

<a name="waf_02_0010"></a><a name="waf_02_0010"></a>
<h1 class="topictitle1">Querying the Number of Existing Resources</h1>
<div id="body1547540588547"><div class="section" id="waf_02_0010__section34155517"><h4 class="sectiontitle">Function Description</h4><p class="msonormal" id="waf_02_0010__p56151406">This API is used to query the number of existing resources of a user.</p>
</div>
<div class="section" id="waf_02_0010__section38964204"><h4 class="sectiontitle">URI</h4><ul id="waf_02_0010__ul51970052"><li id="waf_02_0010__li65077289">URI format<p id="waf_02_0010__p48824690"><a name="waf_02_0010__li65077289"></a><a name="li65077289"></a>GET /v1/{project_id}/waf/bundle/usage/{resource_type}</p>
</li><li id="waf_02_0010__li1726204619181">Parameter description
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="waf_02_0010__table1039446101818" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Path parameters</caption><thead align="left"><tr id="waf_02_0010__row133984613186"><th align="left" class="cellrowborder" valign="top" width="25.507449255074494%" id="mcps1.3.2.2.2.1.2.5.1.1"><p id="waf_02_0010__p839346151813"><strong id="waf_02_0010__b4404192153716">Parameter</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="17.348265173482652%" id="mcps1.3.2.2.2.1.2.5.1.2"><p id="waf_02_0010__p939114618181"><strong id="waf_02_0010__b16442112219376">Mandatory</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="17.348265173482652%" id="mcps1.3.2.2.2.1.2.5.1.3"><p id="waf_02_0010__p173994620185"><strong id="waf_02_0010__b1273215232374">Type</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="39.796020397960206%" id="mcps1.3.2.2.2.1.2.5.1.4"><p id="waf_02_0010__p939184615184"><strong id="waf_02_0010__b47481324153713">Description</strong></p>
</th>
</tr>
</thead>
<tbody><tr id="waf_02_0010__row83944617189"><td class="cellrowborder" valign="top" width="25.507449255074494%" headers="mcps1.3.2.2.2.1.2.5.1.1 "><p id="waf_02_0010__p9398461184">project_id</p>
</td>
<td class="cellrowborder" valign="top" width="17.348265173482652%" headers="mcps1.3.2.2.2.1.2.5.1.2 "><p id="waf_02_0010__p639174611820">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="17.348265173482652%" headers="mcps1.3.2.2.2.1.2.5.1.3 "><p id="waf_02_0010__p1339646181816">String</p>
</td>
<td class="cellrowborder" valign="top" width="39.796020397960206%" headers="mcps1.3.2.2.2.1.2.5.1.4 "><p id="waf_02_0010__p1539114661810">Specifies the project ID.</p>
</td>
</tr>
<tr id="waf_02_0010__row6706181910168"><td class="cellrowborder" valign="top" width="25.507449255074494%" headers="mcps1.3.2.2.2.1.2.5.1.1 "><p id="waf_02_0010__p970043120256">resource_type</p>
</td>
<td class="cellrowborder" valign="top" width="17.348265173482652%" headers="mcps1.3.2.2.2.1.2.5.1.2 "><p id="waf_02_0010__p8699203112517">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="17.348265173482652%" headers="mcps1.3.2.2.2.1.2.5.1.3 "><p id="waf_02_0010__p2699103110258">String</p>
</td>
<td class="cellrowborder" valign="top" width="39.796020397960206%" headers="mcps1.3.2.2.2.1.2.5.1.4 "><p id="waf_02_0010__p21617533">Specifies the resource type. The options are <span class="parmvalue" id="waf_02_0010__parmvalue2446131591919"><b>instance</b></span>, <span class="parmvalue" id="waf_02_0010__parmvalue1975716186197"><b>policy</b></span>, and <span class="parmvalue" id="waf_02_0010__parmvalue16323162491917"><b>certificate</b></span>.</p>
</td>
</tr>
</tbody>
</table>
</div>
</li></ul>
</div>
<div class="section" id="waf_02_0010__section15133516"><h4 class="sectiontitle">Request</h4><p id="waf_02_0010__p19581921193310">Request parameters</p>
<p class="msonormal" id="waf_02_0010__p19675154">None</p>
</div>
<div class="section" id="waf_02_0010__section1983919"><h4 class="sectiontitle">Response</h4><div class="p" id="waf_02_0010__p1130583215339">Response parameters
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="waf_02_0010__table50183647" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Parameter description</caption><thead align="left"><tr id="waf_02_0010__row48503826"><th align="left" class="cellrowborder" valign="top" width="24.490000000000002%" id="mcps1.3.4.2.1.2.4.1.1"><p id="waf_02_0010__p36495809"><strong id="waf_02_0010__b884261318381">Parameter</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="17.349999999999998%" id="mcps1.3.4.2.1.2.4.1.2"><p id="waf_02_0010__p3370541"><strong id="waf_02_0010__b7170215153817">Type</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="58.160000000000004%" id="mcps1.3.4.2.1.2.4.1.3"><p id="waf_02_0010__p4578365"><strong id="waf_02_0010__b149601015143813">Description</strong></p>
</th>
</tr>
</thead>
<tbody><tr id="waf_02_0010__row41205286"><td class="cellrowborder" valign="top" width="24.490000000000002%" headers="mcps1.3.4.2.1.2.4.1.1 "><p id="waf_02_0010__p49293864">count</p>
</td>
<td class="cellrowborder" valign="top" width="17.349999999999998%" headers="mcps1.3.4.2.1.2.4.1.2 "><p id="waf_02_0010__p33380034">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="58.160000000000004%" headers="mcps1.3.4.2.1.2.4.1.3 "><p id="waf_02_0010__p19428253">Specifies the number of existing resources.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
<div class="section" id="waf_02_0010__section6628133643318"><h4 class="sectiontitle">Example</h4><p id="waf_02_0010__p474813412307">The following shows the response if the number of uploaded certificates is queried.</p>
<div class="p" id="waf_02_0010__p850194383313">Response example<pre class="screen" id="waf_02_0010__screen126421636173314">{
"count": 2
}</pre>
</div>
</div>
<div class="section" id="waf_02_0010__section17855279"><h4 class="sectiontitle">Status Code</h4><div class="p" id="waf_02_0010__waf_02_0012_a652d4922b7df48fca0a65bc1a38ea5f2"><a href="#waf_02_0010__waf_02_0012_t82c3440f3efb42a38b9d4dc4011a33d0">Table 3</a> describes the normal status code returned by the API.
<div class="tablenoborder"><a name="waf_02_0010__waf_02_0012_t82c3440f3efb42a38b9d4dc4011a33d0"></a><a name="waf_02_0012_t82c3440f3efb42a38b9d4dc4011a33d0"></a><table cellpadding="4" cellspacing="0" summary="" id="waf_02_0010__waf_02_0012_t82c3440f3efb42a38b9d4dc4011a33d0" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Status code</caption><thead align="left"><tr id="waf_02_0010__waf_02_0012_r3d6e2f205c444705bdbb9daaac74e575"><th align="left" class="cellrowborder" valign="top" width="22%" id="mcps1.3.6.2.2.2.4.1.1"><p id="waf_02_0010__waf_02_0012_af3c4073076f24eca88d94e3fa1effdc6">Status Code</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="19.41%" id="mcps1.3.6.2.2.2.4.1.2"><p id="waf_02_0010__waf_02_0012_en-us_topic_0144911667_p4531342288">Description</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="58.589999999999996%" id="mcps1.3.6.2.2.2.4.1.3"><p id="waf_02_0010__waf_02_0012_ada185614bba24140995b8123b3e9faa8">Meaning</p>
</th>
</tr>
</thead>
<tbody><tr id="waf_02_0010__waf_02_0012_rc7b2adc390904a1ba79e303017797786"><td class="cellrowborder" valign="top" width="22%" headers="mcps1.3.6.2.2.2.4.1.1 "><p id="waf_02_0010__waf_02_0012_a93f3895d44bb4226934cc626ac50e37b">200</p>
</td>
<td class="cellrowborder" valign="top" width="19.41%" headers="mcps1.3.6.2.2.2.4.1.2 "><p id="waf_02_0010__waf_02_0012_en-us_topic_0144911667_p7538425819">OK</p>
</td>
<td class="cellrowborder" valign="top" width="58.589999999999996%" headers="mcps1.3.6.2.2.2.4.1.3 "><p id="waf_02_0010__waf_02_0012_en-us_topic_0144911667_p369874114414">The request has succeeded.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<p id="waf_02_0010__waf_02_0012_en-us_topic_0144911667_p482819399522">For details about error status codes, see <a href="waf_02_0085.html">Status Codes</a>.</p>
</div>
<p id="waf_02_0010__p8060118"></p>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="waf_02_0008.html">Resource Quotas</a></div>
</div>
</div>