forked from docs/doc-exports
Reviewed-by: Pristromskaia, Margarita <margarita.pristromskaia@t-systems.com> Reviewed-by: Hasko, Vladimir <vladimir.hasko@t-systems.com> Co-authored-by: Zaoxu, Li <lizaoxu@huawei.com> Co-committed-by: Zaoxu, Li <lizaoxu@huawei.com>
155 lines
11 KiB
HTML
155 lines
11 KiB
HTML
<a name="deh_02_0028"></a><a name="deh_02_0028"></a>
|
|
|
|
<h1 class="topictitle1">Querying the DeH Quota of a Tenant</h1>
|
|
<div id="body1512563929534"><div class="section" id="deh_02_0028__section5174319"><h4 class="sectiontitle">Function</h4><p id="deh_02_0028__p33868885">This API is used to query the DeH quota of a tenant.</p>
|
|
</div>
|
|
<div class="section" id="deh_02_0028__section46568871"><h4 class="sectiontitle">URI</h4><p id="deh_02_0028__p1729371418485">GET /v1.0/{project_id}/quota-sets/{tenant_id}</p>
|
|
<p id="deh_02_0028__p14129111619484"><a href="#deh_02_0028__table291625114015">Table 1</a> describes the parameters.</p>
|
|
|
|
<div class="tablenoborder"><a name="deh_02_0028__table291625114015"></a><a name="table291625114015"></a><table cellpadding="4" cellspacing="0" summary="" id="deh_02_0028__table291625114015" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters description</caption><thead align="left"><tr id="deh_02_0028__row291610574011"><th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.2.4.2.5.1.1"><p id="deh_02_0028__p1467218184410"><strong id="deh_02_0028__b14327624133118">Parameter</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.2.4.2.5.1.2"><p id="deh_02_0028__p0675111204414"><strong id="deh_02_0028__b19815152817316">Type</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.2.4.2.5.1.3"><p id="deh_02_0028__p69548610432"><strong id="deh_02_0028__b9784429103118">Mandatory</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.2.4.2.5.1.4"><p id="deh_02_0028__p19679111448"><strong id="deh_02_0028__b11409311318">Description</strong></p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="deh_02_0028__row69161956409"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.2.4.2.5.1.1 "><p id="deh_02_0028__p126868117449">project_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.2.4.2.5.1.2 "><p id="deh_02_0028__p1688101174411">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.2.4.2.5.1.3 "><p id="deh_02_0028__p59527664313">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.2.4.2.5.1.4 "><p id="deh_02_0028__p1969317113442">Specifies the project ID.</p>
|
|
<p id="deh_02_0028__p7376194915119">For details about how to obtain the project ID, see <a href="https://docs.otc.t-systems.com/en-us/api/apiug/apig-en-api-180328009.html" target="_blank" rel="noopener noreferrer">Obtaining Required Information</a>.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="deh_02_0028__row2895162113492"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.2.4.2.5.1.1 "><p id="deh_02_0028__p1895162114495">tenant_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.2.4.2.5.1.2 "><p id="deh_02_0028__p12311833124919">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.2.4.2.5.1.3 "><p id="deh_02_0028__p72331733174920">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.2.4.2.5.1.4 "><p id="deh_02_0028__p15234143317494">Specifies the tenant ID.</p>
|
|
<p id="deh_02_0028__p858154817367">You can obtain the value from the DeH console or using the API in <a href="deh_02_0020.html">Querying DeHs</a>.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="deh_02_0028__section13982202"><h4 class="sectiontitle">Request</h4><p id="deh_02_0028__p159698177509">You can add the <strong id="deh_02_0028__b68247549313">resource</strong> parameter to the URI. For example:</p>
|
|
<p id="deh_02_0028__p144271326205013"><strong id="deh_02_0028__b1541035413501">/v1.0/{project_id}/quota-sets/{tenant_id}?resource={resource}</strong></p>
|
|
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="deh_02_0028__table3841636155213" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Request parameters</caption><thead align="left"><tr id="deh_02_0028__row1385153665219"><th align="left" class="cellrowborder" valign="top" width="17.61%" id="mcps1.3.3.4.2.6.1.1"><p id="deh_02_0028__p156471053205218"><strong id="deh_02_0028__b2711431298">Parameter</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="17.52%" id="mcps1.3.3.4.2.6.1.2"><p id="deh_02_0028__p116471753175213"><strong id="deh_02_0028__b13257201473920">Location</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="17.07%" id="mcps1.3.3.4.2.6.1.3"><p id="deh_02_0028__p1647105312527"><strong id="deh_02_0028__b2271195473213">Type</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="16.08%" id="mcps1.3.3.4.2.6.1.4"><p id="deh_02_0028__p964710536524"><strong id="deh_02_0028__b890577105">Mandatory</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="31.72%" id="mcps1.3.3.4.2.6.1.5"><p id="deh_02_0028__p15647653195212"><strong id="deh_02_0028__b1282019564324">Description</strong></p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="deh_02_0028__row48513366524"><td class="cellrowborder" valign="top" width="17.61%" headers="mcps1.3.3.4.2.6.1.1 "><p id="deh_02_0028__p3647115319521">resource</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="17.52%" headers="mcps1.3.3.4.2.6.1.2 "><p id="deh_02_0028__p16472533525">query</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="17.07%" headers="mcps1.3.3.4.2.6.1.3 "><p id="deh_02_0028__p2064775315217">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="16.08%" headers="mcps1.3.3.4.2.6.1.4 "><p id="deh_02_0028__p1764705314529">No</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="31.72%" headers="mcps1.3.3.4.2.6.1.5 "><p id="deh_02_0028__p146481353105213">Specifies the resource type.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="deh_02_0028__section58730959"><h4 class="sectiontitle">Response</h4>
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="deh_02_0028__table6718201285315" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Response parameters</caption><thead align="left"><tr id="deh_02_0028__row16718181225320"><th align="left" class="cellrowborder" valign="top" width="25.972597259725973%" id="mcps1.3.4.2.2.4.1.1"><p id="deh_02_0028__p154247351537"><strong id="deh_02_0028__b131080712539">Parameter</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="23.45234523452345%" id="mcps1.3.4.2.2.4.1.2"><p id="deh_02_0028__p1642493595315"><strong id="deh_02_0028__b736858125317">Type</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="50.57505750575058%" id="mcps1.3.4.2.2.4.1.3"><p id="deh_02_0028__p1424133545314"><strong id="deh_02_0028__b19122312535">Description</strong></p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="deh_02_0028__row10719121245316"><td class="cellrowborder" valign="top" width="25.972597259725973%" headers="mcps1.3.4.2.2.4.1.1 "><p id="deh_02_0028__p124243357539">quota_set</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="23.45234523452345%" headers="mcps1.3.4.2.2.4.1.2 "><p id="deh_02_0028__p124241835145315">Array of objects</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50.57505750575058%" headers="mcps1.3.4.2.2.4.1.3 "><p id="deh_02_0028__p74241535185317">Specifies the quota set of a DeH.</p>
|
|
<p id="deh_02_0028__p204241224164219">For details, see <a href="#deh_02_0028__table379913618427">Table 4</a>.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="tablenoborder"><a name="deh_02_0028__table379913618427"></a><a name="table379913618427"></a><table cellpadding="4" cellspacing="0" summary="" id="deh_02_0028__table379913618427" frame="border" border="1" rules="all"><caption><b>Table 4 </b><strong id="deh_02_0028__b1834424915392">quota_set</strong> field description</caption><thead align="left"><tr id="deh_02_0028__row5800864424"><th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.4.3.2.4.1.1"><p id="deh_02_0028__p863918253434"><strong id="deh_02_0028__b28840129323539">Parameter</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.4.3.2.4.1.2"><p id="deh_02_0028__p1639112520432"><strong id="deh_02_0028__b1612375543">Type</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.4.3.2.4.1.3"><p id="deh_02_0028__p463932517434"><strong id="deh_02_0028__b1238175223919">Description</strong></p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="deh_02_0028__row78008634214"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.3.2.4.1.1 "><p id="deh_02_0028__p7258611204212">resource</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.3.2.4.1.2 "><p id="deh_02_0028__p192581911174218">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.3.2.4.1.3 "><p id="deh_02_0028__p1225881174213">Specifies the resource type.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="deh_02_0028__row180120614219"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.3.2.4.1.1 "><p id="deh_02_0028__p1425811111421">hard_limit</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.3.2.4.1.2 "><p id="deh_02_0028__p202581611194219">Integer</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.3.2.4.1.3 "><p id="deh_02_0028__p1225801110426">Specifies the quota limit. </p>
|
|
<p id="deh_02_0028__p1325813119425"><strong id="deh_02_0028__b1741851481812">-1</strong> indicates that the resource quota is not limited.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="deh_02_0028__row14801662427"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.3.2.4.1.1 "><p id="deh_02_0028__p3258181184216">used</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.3.2.4.1.2 "><p id="deh_02_0028__p525941124216">Integer</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.4.3.2.4.1.3 "><p id="deh_02_0028__p1825941114219">Specifies the used amount of the quota.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="deh_02_0028__section1768432015261"><h4 class="sectiontitle">Example Request</h4><p id="deh_02_0028__p12778923121714">Query the DeH quota of the tenant whose ID is <strong id="deh_02_0028__b144415140292">45df5566cb3443ab910cf0daebcapoi8</strong>.</p>
|
|
<pre class="screen" id="deh_02_0028__screen083512915551">GET https://{Endpoint}/v1.0/9c53a566cb3443ab910cf0daebca90c4/quota-sets/45df5566cb3443ab910cf0daebcapoi8</pre>
|
|
</div>
|
|
<div class="section" id="deh_02_0028__section156132912611"><h4 class="sectiontitle">Example Response</h4><pre class="screen" id="deh_02_0028__screen126616289817">{
|
|
"quota_set": [
|
|
{
|
|
"used": 0,
|
|
"resource": "c4",
|
|
"hard_limit": 5
|
|
},
|
|
{
|
|
"used": 0,
|
|
"resource": "m4",
|
|
"hard_limit": 5
|
|
}
|
|
]
|
|
}</pre>
|
|
</div>
|
|
<div class="section" id="deh_02_0028__section66523006"><h4 class="sectiontitle">Status Code</h4><p id="deh_02_0028__p17936932">See <a href="deh_02_0016.html">Status Codes</a>.</p>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="deh_02_0026.html">Quota Configuration</a></div>
|
|
</div>
|
|
</div>
|
|
|