doc-exports/docs/waf/api-ref/waf_02_0019.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

168 lines
13 KiB
HTML

<a name="waf_02_0019"></a><a name="waf_02_0019"></a>
<h1 class="topictitle1">Obtaining the Certificate List</h1>
<div id="body64488073"><div class="section" id="waf_02_0019__section34155517"><h4 class="sectiontitle">Function Description</h4><p class="msonormal" id="waf_02_0019__p56151406">This API is used to obtain the certificate list of a user.</p>
</div>
<div class="section" id="waf_02_0019__section38964204"><h4 class="sectiontitle">URI</h4><ul id="waf_02_0019__ul51970052"><li id="waf_02_0019__li65077289">URI format<p id="waf_02_0019__p48824690"><a name="waf_02_0019__li65077289"></a><a name="li65077289"></a>GET /v1/{project_id}/waf/certificate?offset={offset}&amp;limit={limit}</p>
</li><li id="waf_02_0019__li1726204619181">Parameter description
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="waf_02_0019__table1039446101818" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Path parameters</caption><thead align="left"><tr id="waf_02_0019__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_0019__p839346151813"><strong id="waf_02_0019__b179121613193">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_0019__p939114618181"><strong id="waf_02_0019__b594417741915">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_0019__p173994620185"><strong id="waf_02_0019__b179444816199">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_0019__p939184615184"><strong id="waf_02_0019__b18353951914">Description</strong></p>
</th>
</tr>
</thead>
<tbody><tr id="waf_02_0019__row83944617189"><td class="cellrowborder" valign="top" width="25.507449255074494%" headers="mcps1.3.2.2.2.1.2.5.1.1 "><p id="waf_02_0019__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_0019__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_0019__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_0019__p1539114661810">Specifies the project ID.</p>
</td>
</tr>
<tr id="waf_02_0019__row6706181910168"><td class="cellrowborder" valign="top" width="25.507449255074494%" headers="mcps1.3.2.2.2.1.2.5.1.1 "><p id="waf_02_0019__p970043120256">offset</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_0019__p8699203112517">No</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_0019__p2699103110258">Long</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_0019__p21617533">Specifies the number of returned pages. Its value ranges from <strong id="waf_02_0019__b182506512333">0</strong> to <strong id="waf_02_0019__b172508515338">65535</strong>. The default value is <strong id="waf_02_0019__b825015143314">0</strong>.</p>
</td>
</tr>
<tr id="waf_02_0019__row139211333181614"><td class="cellrowborder" valign="top" width="25.507449255074494%" headers="mcps1.3.2.2.2.1.2.5.1.1 "><p id="waf_02_0019__p126961631102512">limit</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_0019__p369553116251">No</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_0019__p269473120252">Long</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_0019__p25357967">Specifies the maximum number of records displayed on each page. Its value ranges from <strong id="waf_02_0019__b165636793319">0</strong> to <strong id="waf_02_0019__b056312723313">50</strong>. The default value is <strong id="waf_02_0019__b125632714337">10</strong>. If <strong id="waf_02_0019__b771592013262">limit</strong> is <strong id="waf_02_0019__b1899632313266">-1</strong>, one page with 65535 records is displayed.</p>
</td>
</tr>
</tbody>
</table>
</div>
</li></ul>
</div>
<div class="section" id="waf_02_0019__section15133516"><h4 class="sectiontitle">Request</h4><p id="waf_02_0019__p19581921193310">Request parameters</p>
<p class="msonormal" id="waf_02_0019__p19675154">None</p>
</div>
<div class="section" id="waf_02_0019__section1983919"><h4 class="sectiontitle">Response</h4><div class="p" id="waf_02_0019__p1130583215339">Response parameters
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="waf_02_0019__table50183647" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Parameter description</caption><thead align="left"><tr id="waf_02_0019__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_0019__p36495809"><strong id="waf_02_0019__b10431135810265">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_0019__p3370541"><strong id="waf_02_0019__b115417595267">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_0019__p4578365"><strong id="waf_02_0019__b1921420012712">Description</strong></p>
</th>
</tr>
</thead>
<tbody><tr id="waf_02_0019__row41205286"><td class="cellrowborder" valign="top" width="24.490000000000002%" headers="mcps1.3.4.2.1.2.4.1.1 "><p id="waf_02_0019__p49293864">total</p>
</td>
<td class="cellrowborder" valign="top" width="17.349999999999998%" headers="mcps1.3.4.2.1.2.4.1.2 "><p id="waf_02_0019__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_0019__p19428253">Specifies the total number of certificates.</p>
</td>
</tr>
<tr id="waf_02_0019__row40636554"><td class="cellrowborder" valign="top" width="24.490000000000002%" headers="mcps1.3.4.2.1.2.4.1.1 "><p id="waf_02_0019__p3226601">items</p>
</td>
<td class="cellrowborder" valign="top" width="17.349999999999998%" headers="mcps1.3.4.2.1.2.4.1.2 "><p id="waf_02_0019__p60028124"><a href="#waf_02_0019__table16394183011019">Table 3</a></p>
</td>
<td class="cellrowborder" valign="top" width="58.160000000000004%" headers="mcps1.3.4.2.1.2.4.1.3 "><p id="waf_02_0019__p30439884">Specifies the certificate objects.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="tablenoborder"><a name="waf_02_0019__table16394183011019"></a><a name="table16394183011019"></a><table cellpadding="4" cellspacing="0" summary="" id="waf_02_0019__table16394183011019" frame="border" border="1" rules="all"><caption><b>Table 3 </b><strong id="waf_02_0019__b7482164713715">items</strong></caption><thead align="left"><tr id="waf_02_0019__row939613301015"><th align="left" class="cellrowborder" valign="top" width="24.787521247875212%" id="mcps1.3.4.3.2.4.1.1"><p id="waf_02_0019__p039873016013"><strong id="waf_02_0019__b16552850181110">Parameter</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="33.27667233276672%" id="mcps1.3.4.3.2.4.1.2"><p id="waf_02_0019__p183997301406"><strong id="waf_02_0019__b1063187839">Type</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="41.935806419358066%" id="mcps1.3.4.3.2.4.1.3"><p id="waf_02_0019__p839973013010"><strong id="waf_02_0019__b134520161217">Description</strong></p>
</th>
</tr>
</thead>
<tbody><tr id="waf_02_0019__row194351472276"><td class="cellrowborder" valign="top" width="24.787521247875212%" headers="mcps1.3.4.3.2.4.1.1 "><p id="waf_02_0019__p431664632715">id</p>
</td>
<td class="cellrowborder" valign="top" width="33.27667233276672%" headers="mcps1.3.4.3.2.4.1.2 "><p id="waf_02_0019__p5316174618270">String</p>
</td>
<td class="cellrowborder" valign="top" width="41.935806419358066%" headers="mcps1.3.4.3.2.4.1.3 "><p id="waf_02_0019__p9317204622716">Specifies the certificate ID.</p>
</td>
</tr>
<tr id="waf_02_0019__row74352472273"><td class="cellrowborder" valign="top" width="24.787521247875212%" headers="mcps1.3.4.3.2.4.1.1 "><p id="waf_02_0019__p9318746172714">name</p>
</td>
<td class="cellrowborder" valign="top" width="33.27667233276672%" headers="mcps1.3.4.3.2.4.1.2 "><p id="waf_02_0019__p432084622716">String</p>
</td>
<td class="cellrowborder" valign="top" width="41.935806419358066%" headers="mcps1.3.4.3.2.4.1.3 "><p id="waf_02_0019__p12321846172712">Specifies the certificate name.</p>
</td>
</tr>
<tr id="waf_02_0019__row106651551447"><td class="cellrowborder" valign="top" width="24.787521247875212%" headers="mcps1.3.4.3.2.4.1.1 "><p id="waf_02_0019__p466545510448">expireTime</p>
</td>
<td class="cellrowborder" valign="top" width="33.27667233276672%" headers="mcps1.3.4.3.2.4.1.2 "><p id="waf_02_0019__p11665125516444">Long</p>
</td>
<td class="cellrowborder" valign="top" width="41.935806419358066%" headers="mcps1.3.4.3.2.4.1.3 "><p id="waf_02_0019__p17665655174419">Specifies the time when the certificate expires.</p>
</td>
</tr>
<tr id="waf_02_0019__row172896158372"><td class="cellrowborder" valign="top" width="24.787521247875212%" headers="mcps1.3.4.3.2.4.1.1 "><p id="waf_02_0019__p1028912157374">timestamp</p>
</td>
<td class="cellrowborder" valign="top" width="33.27667233276672%" headers="mcps1.3.4.3.2.4.1.2 "><p id="waf_02_0019__p328931510372">Long</p>
</td>
<td class="cellrowborder" valign="top" width="41.935806419358066%" headers="mcps1.3.4.3.2.4.1.3 "><p id="waf_02_0019__p6289715133717">Specifies the time when the certificate is uploaded.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="waf_02_0019__section6628133643318"><h4 class="sectiontitle">Example</h4><p id="waf_02_0019__p474813412307"><strong id="waf_02_0019__b16431212428">total</strong> with a value of <strong id="waf_02_0019__b10524220424">2</strong> is used as an example.</p>
<div class="p" id="waf_02_0019__p850194383313">Response example<pre class="screen" id="waf_02_0019__screen126421636173314">{
"total": 2,
"items": [
{
"id": "388a7789d55b41d1918b3088a8f1e7f3",
"name": "cert_a",
"timestamp": 1544756441859,
"expireTime": 1545978662373
}, {
"id": "388a7789d55b41d1918b3088a8f1e7f4",
"name": "cert_b",
"timestamp": 1544756441859,
"expireTime": 1545978662356
}]
}</pre>
</div>
</div>
<div class="section" id="waf_02_0019__section17855279"><h4 class="sectiontitle">Status Code</h4><div class="p" id="waf_02_0019__waf_02_0012_a652d4922b7df48fca0a65bc1a38ea5f2"><a href="#waf_02_0019__waf_02_0012_t82c3440f3efb42a38b9d4dc4011a33d0">Table 4</a> describes the normal status code returned by the API.
<div class="tablenoborder"><a name="waf_02_0019__waf_02_0012_t82c3440f3efb42a38b9d4dc4011a33d0"></a><a name="waf_02_0012_t82c3440f3efb42a38b9d4dc4011a33d0"></a><table cellpadding="4" cellspacing="0" summary="" id="waf_02_0019__waf_02_0012_t82c3440f3efb42a38b9d4dc4011a33d0" frame="border" border="1" rules="all"><caption><b>Table 4 </b>Status code</caption><thead align="left"><tr id="waf_02_0019__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_0019__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_0019__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_0019__waf_02_0012_ada185614bba24140995b8123b3e9faa8">Meaning</p>
</th>
</tr>
</thead>
<tbody><tr id="waf_02_0019__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_0019__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_0019__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_0019__waf_02_0012_en-us_topic_0144911667_p369874114414">The request has succeeded.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<p id="waf_02_0019__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>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="waf_02_0018.html">Certificate Management</a></div>
</div>
</div>