forked from docs/doc-exports
Reviewed-by: Belejkanic, Lukas <lukas.belejkanic@t-systems.com> Co-authored-by: Li, Qiao <qiaoli@huawei.com> Co-committed-by: Li, Qiao <qiaoli@huawei.com>
189 lines
18 KiB
HTML
189 lines
18 KiB
HTML
<a name="kms_02_0032"></a><a name="kms_02_0032"></a>
|
|
|
|
<h1 class="topictitle1">Querying Grants That Can Be Retired</h1>
|
|
<div id="body1497317398920"><div class="section" id="kms_02_0032__en-us_topic_0112992293_s1731a14fb0144c79bf0fa90c694f34f7"><h4 class="sectiontitle">Function</h4><p id="kms_02_0032__en-us_topic_0112992293_p3693098916421">This API enables you to query grants that can be retired.</p>
|
|
</div>
|
|
<div class="section" id="kms_02_0032__en-us_topic_0112992293_se70c3e5518a04f60b06032524dddfef4"><h4 class="sectiontitle">URI</h4><ul id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0020091565_ul60390938"><li id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0020091565_li6647531">URI format<p id="kms_02_0032__en-us_topic_0112992293_p445073801740"><a name="kms_02_0032__en-us_topic_0112992293_en-us_topic_0020091565_li6647531"></a><a name="en-us_topic_0112992293_en-us_topic_0020091565_li6647531"></a>POST /v1.0/{project_id}/kms/list-retirable-grants</p>
|
|
</li><li id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0020091565_li14211994">Parameter description
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="kms_02_0032__en-us_topic_0112992293_t982da1e0196d4ec1a28d1fbff2cc8191" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="kms_02_0032__en-us_topic_0112992293_r6e963322c1e740d181726d2f0e91df5a"><th align="left" class="cellrowborder" valign="top" width="22.74%" id="mcps1.3.2.2.2.1.2.5.1.1"><p id="kms_02_0032__en-us_topic_0112992293_a3b5bbe5a7f644fd3a74cecbfb3f7ed60"><strong id="kms_02_0032__en-us_topic_0112992293_b842352706193829">Parameter</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="22.18%" id="mcps1.3.2.2.2.1.2.5.1.2"><p id="kms_02_0032__en-us_topic_0112992293_ad98d2f62bd064b4e96ea922645197c24"><strong id="kms_02_0032__en-us_topic_0112992293_b842352706193832">Mandatory</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="20.49%" id="mcps1.3.2.2.2.1.2.5.1.3"><p id="kms_02_0032__en-us_topic_0112992293_a3becf0b3aec9468984c2efc8d5abbea5">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="34.589999999999996%" id="mcps1.3.2.2.2.1.2.5.1.4"><p id="kms_02_0032__en-us_topic_0112992293_a6bb6f1fe56a2454982832e8d56d354d8">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="kms_02_0032__en-us_topic_0112992293_r69bf37b65d3f446eab7b3f4d1b2fcec0"><td class="cellrowborder" valign="top" width="22.74%" headers="mcps1.3.2.2.2.1.2.5.1.1 "><p id="kms_02_0032__en-us_topic_0112992293_ae42d73592f58424ea93a11e52d2478dd">project_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="22.18%" headers="mcps1.3.2.2.2.1.2.5.1.2 "><p id="kms_02_0032__en-us_topic_0112992293_a56440c0f0ae34ba3b8033d1247673984">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.49%" headers="mcps1.3.2.2.2.1.2.5.1.3 "><p id="kms_02_0032__en-us_topic_0112992293_p4386100291125">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="34.589999999999996%" headers="mcps1.3.2.2.2.1.2.5.1.4 "><p id="kms_02_0032__en-us_topic_0112992293_a1314869d2dc147b38461e037d622f7b4">Project ID</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="kms_02_0032__en-us_topic_0112992293_seb7b7901701247fab30a59b76f1c7f93"><h4 class="sectiontitle">Requests</h4>
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="kms_02_0032__en-us_topic_0112992293_table46221022101230" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Request parameters</caption><thead align="left"><tr id="kms_02_0032__en-us_topic_0112992293_row9315574101230"><th align="left" class="cellrowborder" valign="top" width="17%" id="mcps1.3.3.2.2.5.1.1"><p id="kms_02_0032__en-us_topic_0112992293_p16364058101230"><strong id="kms_02_0032__en-us_topic_0112992293_b673430343">Parameter</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="16%" id="mcps1.3.3.2.2.5.1.2"><p id="kms_02_0032__en-us_topic_0112992293_p57514295101230"><strong id="kms_02_0032__en-us_topic_0112992293_b842352706193857">Mandatory</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="17%" id="mcps1.3.3.2.2.5.1.3"><p id="kms_02_0032__en-us_topic_0112992293_p50420322101230"><strong id="kms_02_0032__en-us_topic_0112992293_b842352706193855">Type</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="50%" id="mcps1.3.3.2.2.5.1.4"><p id="kms_02_0032__en-us_topic_0112992293_p28146304101230">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="kms_02_0032__en-us_topic_0112992293_row2638193101722"><td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.3.2.2.5.1.1 "><p id="kms_02_0032__en-us_topic_0112992293_p5119285016439">limit</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.3.2.2.5.1.2 "><p id="kms_02_0032__en-us_topic_0112992293_p6353760916439">No</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.3.2.2.5.1.3 "><p id="kms_02_0032__en-us_topic_0112992293_p0691401259">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.3.2.2.5.1.4 "><p id="kms_02_0032__en-us_topic_0112992293_p187030631183">This parameter specifies the number of entries returned. If the specified number is smaller than the actual number of existing entries, <span class="parmvalue" id="kms_02_0032__en-us_topic_0112992293_parmvalue555125744154359"><b>true</b></span> will be returned for the response parameter <span class="parmname" id="kms_02_0032__en-us_topic_0112992293_parmname769647905154346"><b>truncated</b></span>, indicating that the query results will be displayed in separate pages.</p>
|
|
<p id="kms_02_0032__en-us_topic_0112992293_p4627274216439">The value is within the range of the maximum number of grants, for example, <span class="parmvalue" id="kms_02_0032__en-us_topic_0112992293_parmvalue581493328154547"><b>100</b></span>.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="kms_02_0032__en-us_topic_0112992293_row35142504101726"><td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.3.2.2.5.1.1 "><p id="kms_02_0032__en-us_topic_0112992293_p2967402816439">marker</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.3.2.2.5.1.2 "><p id="kms_02_0032__en-us_topic_0112992293_p848971516439">No</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.3.2.2.5.1.3 "><p id="kms_02_0032__en-us_topic_0112992293_p1110110421756">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.3.2.2.5.1.4 "><p id="kms_02_0032__en-us_topic_0112992293_p1313368711816">This parameter marks the starting location in a pagination query.</p>
|
|
<p id="kms_02_0032__en-us_topic_0112992293_p1657829916439">If the <span class="parmname" id="kms_02_0032__en-us_topic_0112992293_parmname769647905155414"><b>truncated</b></span> value is <span class="parmvalue" id="kms_02_0032__en-us_topic_0112992293_parmvalue555125744155422"><b>true</b></span>, you can send consecutive requests to obtain more record entries. The <span class="parmname" id="kms_02_0032__en-us_topic_0112992293_parmname769647905155539"><b>marker</b></span> value must be set to the <span class="parmname" id="kms_02_0032__en-us_topic_0112992293_parmname769647905155552"><b>next_marker</b></span> value in the response, for example, <strong id="kms_02_0032__en-us_topic_0112992293_b7956061174331">10</strong>.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="kms_02_0032__en-us_topic_0112992293_row59920057164255"><td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.3.2.2.5.1.1 "><p id="kms_02_0032__en-us_topic_0112992293_p5386140416439">sequence</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.3.2.2.5.1.2 "><p id="kms_02_0032__en-us_topic_0112992293_p5650607916439">No</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.3.2.2.5.1.3 "><p id="kms_02_0032__en-us_topic_0112992293_p213117445516">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.3.2.2.5.1.4 "><p id="kms_02_0032__en-us_topic_0112992293_p1358971416439">36-byte serial number of a request message</p>
|
|
<p id="kms_02_0032__en-us_topic_0112992293_p5519856416439">Example: 919c82d4-8046-4722-9094-35c3c6524cff</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="kms_02_0032__en-us_topic_0112992293_sfadd53a5f4714e8f87811818d62d0296"><h4 class="sectiontitle">Responses</h4>
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="kms_02_0032__en-us_topic_0112992293_t98d238e10953421e84a073707024c329" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Response parameters</caption><thead align="left"><tr id="kms_02_0032__en-us_topic_0112992293_r144a2c52c5054c6d9243eb2ef3875a21"><th align="left" class="cellrowborder" valign="top" width="17%" id="mcps1.3.4.2.2.5.1.1"><p id="kms_02_0032__en-us_topic_0112992293_p13230838154934"><strong id="kms_02_0032__en-us_topic_0112992293_b1065095169">Parameter</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="16%" id="mcps1.3.4.2.2.5.1.2"><p id="kms_02_0032__en-us_topic_0112992293_p65064970154934"><strong id="kms_02_0032__en-us_topic_0112992293_b1114472755">Mandatory</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="17%" id="mcps1.3.4.2.2.5.1.3"><p id="kms_02_0032__en-us_topic_0112992293_p35771181154934">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="50%" id="mcps1.3.4.2.2.5.1.4"><p id="kms_02_0032__en-us_topic_0112992293_p11784586154934">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="kms_02_0032__en-us_topic_0112992293_r3c4af7b36e9240d197ab56255e37b83c"><td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.4.2.2.5.1.1 "><p id="kms_02_0032__en-us_topic_0112992293_p54751797164430">grants</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.4.2.2.5.1.2 "><p id="kms_02_0032__en-us_topic_0112992293_p63244409104212">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.4.2.2.5.1.3 "><p id="kms_02_0032__en-us_topic_0112992293_p18681346567">Array of objects</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.2.2.5.1.4 "><p id="kms_02_0032__en-us_topic_0112992293_p22523510104212">Grant list. For details, see <a href="kms_02_0031.html#kms_02_0031__en-us_topic_0112992310_table17099798154440">Table 4</a>.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="kms_02_0032__en-us_topic_0112992293_row1195616116587"><td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.4.2.2.5.1.1 "><p id="kms_02_0032__en-us_topic_0112992293_p5734209165853">next_marker</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.4.2.2.5.1.2 "><p id="kms_02_0032__en-us_topic_0112992293_p41184394165853">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.4.2.2.5.1.3 "><p id="kms_02_0032__en-us_topic_0112992293_p750913471517">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.2.2.5.1.4 "><p id="kms_02_0032__en-us_topic_0112992293_p40375092113058">This parameter indicates the <span class="parmname" id="kms_02_0032__en-us_topic_0112992293_parmname76964790515596"><b>marker</b></span> value required for obtaining the next page of query results.</p>
|
|
<p id="kms_02_0032__en-us_topic_0112992293_p47601640165853">If the <span class="parmname" id="kms_02_0032__en-us_topic_0112992293_parmname769647905155931"><b>truncated</b></span> value is <span class="parmvalue" id="kms_02_0032__en-us_topic_0112992293_parmvalue555125744155940"><b>false</b></span>, the <span class="parmname" id="kms_02_0032__en-us_topic_0112992293_parmname76964790516018"><b>next_marker</b></span> parameter is left blank.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="kms_02_0032__en-us_topic_0112992293_row63650114165815"><td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.4.2.2.5.1.1 "><p id="kms_02_0032__en-us_topic_0112992293_p6312998165853">truncated</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.4.2.2.5.1.2 "><p id="kms_02_0032__en-us_topic_0112992293_p13415518165853">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.4.2.2.5.1.3 "><p id="kms_02_0032__en-us_topic_0112992293_p26461450057">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.2.2.5.1.4 "><div class="p" id="kms_02_0032__en-us_topic_0112992293_p12915177165853">This parameter indicates whether there are more results displayed in another page.<ul id="kms_02_0032__en-us_topic_0112992293_ul49127730165853"><li id="kms_02_0032__en-us_topic_0112992293_li39496392165853">If the value is <span class="parmvalue" id="kms_02_0032__en-us_topic_0112992293_parmvalue5551257441629"><b>true</b></span>, there are more results.</li><li id="kms_02_0032__en-us_topic_0112992293_li19923211165853">If the value is <span class="parmvalue" id="kms_02_0032__en-us_topic_0112992293_parmvalue30958336113051"><b>false</b></span>, the current page is the last page.</li></ul>
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="kms_02_0032__en-us_topic_0112992293_row41123860163925"><td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.4.2.2.5.1.1 "><p id="kms_02_0032__en-us_topic_0112992293_p37562908163928">total</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="16%" headers="mcps1.3.4.2.2.5.1.2 "><p id="kms_02_0032__en-us_topic_0112992293_p26496943163928">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="17%" headers="mcps1.3.4.2.2.5.1.3 "><p id="kms_02_0032__en-us_topic_0112992293_p22696744163928">Integer</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.2.2.5.1.4 "><p id="kms_02_0032__en-us_topic_0112992293_p65877659163928">This parameter indicates the total number of grants.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="kms_02_0032__en-us_topic_0112992293_section122445141020"><h4 class="sectiontitle">Examples</h4><p id="kms_02_0032__en-us_topic_0112992293_p64104145114">The following example describes how to query the list of grants that can be retired.</p>
|
|
<ul id="kms_02_0032__en-us_topic_0112992293_ul202971954181012"><li id="kms_02_0032__en-us_topic_0112992293_li3385453102">Example request<pre class="screen" id="kms_02_0032__en-us_topic_0112992293_screen13381345181018">{
|
|
"limit": "",
|
|
"marker": ""
|
|
}</pre>
|
|
</li><li id="kms_02_0032__en-us_topic_0112992293_li84234591016">Example response<pre class="screen" id="kms_02_0032__en-us_topic_0112992293_screen204234513101">{
|
|
"grants": [
|
|
{"key_id": "bb6a3d22-dc93-47ac-b5bd-88df7ad35f1e",
|
|
"grant_id": "7c9a3286af4fcca5f0a385ad13e1d21a50e27b6dbcab50f37f30f93b8939827d",
|
|
"operations":
|
|
["describe-key","create-datakey", "encrypt-datakey"],
|
|
"grantee_principal":"13gg44z4g2sglzk0egw0u726zoyzvrs8",
|
|
"retiring_principal":"13gg44z4g2sglzk0egw0u726zoyzvrs8",
|
|
"issuing_principal":"e4hkeeea506ex3wgnzyhi656n8hx8xa3",
|
|
"name":"my_grant",
|
|
"creation_date":"1497341531000"
|
|
}],
|
|
"next_marker": "",
|
|
"truncated": "false",
|
|
"total":1
|
|
}</pre>
|
|
<p id="kms_02_0032__en-us_topic_0112992293_p942114561010">or</p>
|
|
<pre class="screen" id="kms_02_0032__en-us_topic_0112992293_screen84213455105">{
|
|
"error": {
|
|
"error_code": "KMS.XXXX",
|
|
"error_msg": "XXX"
|
|
}
|
|
}</pre>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="kms_02_0032__en-us_topic_0112992293_section3454223421"><h4 class="sectiontitle">Status Codes</h4><div class="p" id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_en-us_topic_0079615001_p17772351"><a href="#kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_en-us_topic_0079615001_table20596071">Table 4</a> lists the normal status code returned by the response.
|
|
<div class="tablenoborder"><a name="kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_en-us_topic_0079615001_table20596071"></a><a name="en-us_topic_0112992293_en-us_topic_0112992294_en-us_topic_0079615001_table20596071"></a><table cellpadding="4" cellspacing="0" summary="" id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_en-us_topic_0079615001_table20596071" frame="border" border="1" rules="all"><caption><b>Table 4 </b>Status codes</caption><thead align="left"><tr id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_en-us_topic_0079615001_row9746163"><th align="left" class="cellrowborder" valign="top" width="16.16%" id="mcps1.3.6.2.2.2.4.1.1"><p id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_p57545694203043">Status Code</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="28.28%" id="mcps1.3.6.2.2.2.4.1.2"><p id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_p4531342288">Status</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="55.559999999999995%" id="mcps1.3.6.2.2.2.4.1.3"><p id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_p30689603203043">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_en-us_topic_0079615001_row48621261"><td class="cellrowborder" valign="top" width="16.16%" headers="mcps1.3.6.2.2.2.4.1.1 "><p id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_en-us_topic_0079615001_p46008046">200</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="28.28%" headers="mcps1.3.6.2.2.2.4.1.2 "><p id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_p7538425819">OK</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="55.559999999999995%" headers="mcps1.3.6.2.2.2.4.1.3 "><p id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_p1885682315512">Request processed successfully.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<p id="kms_02_0032__en-us_topic_0112992293_en-us_topic_0112992294_p5626181018551">Exception status code. For details, see <a href="kms_02_0301.html#kms_02_0301">Status Codes</a>.</p>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="kms_02_0011.html">CMK Management</a></div>
|
|
</div>
|
|
</div>
|
|
|