Files
doc-exports/docs/bms/api-ref/en-us_topic_0000002340222828.html
wanghuijuan738 69783f9e3e bms api 20241225 version
Reviewed-by: Pristromskaia, Margarita <margarita.pristromskaia@t-systems.com>
Co-authored-by: wanghuijuan738 <wanghuijuan738@huawei.com>
Co-committed-by: wanghuijuan738 <wanghuijuan738@huawei.com>
2025-07-16 09:58:55 +00:00

87 lines
13 KiB
HTML

<a name="EN-US_TOPIC_0000002340222828"></a><a name="EN-US_TOPIC_0000002340222828"></a>
<h1 class="topictitle1">Deleting a Tag from a <span id="en-us_topic_0060424486_text93761115448">BMS</span><span id="en-us_topic_0060424486_text1297323418528"></span><span id="en-us_topic_0060424486_text18543158123214"></span></h1>
<div id="body8662426"><div class="section" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_section46928615105534"><h4 class="sectiontitle">Function</h4><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p43121505105534">This API is used to delete a tag of a <span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text185671349205318">BMS</span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text256784955315"></span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text691215573314"></span>.</p>
<p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p133455520338">You are required to use the HTTP header <strong id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0060410926_b842352706165643">X-OpenStack-Nova-API-Version: 2.26</strong> to specify the micro version on the client.</p>
</div>
<div class="section" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_section11729622194315"><h4 class="sectiontitle">Constraints</h4><ul id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_ul6367192553415"><li id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_li8367925133413">The tag contains a maximum of 80 characters.</li><li id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_li13321831163420">If a tag contains non-URL-safe characters, perform URL encoding.</li></ul>
<div class="note" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_note65604746151638"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><ul id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_ul20910143374618"><li id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_li1791023324610">Tag <strong id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_b8854822124319">__type_baremetal</strong> is used to identify a <span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text13854152212433">BMS</span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text10854192224315"></span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text168541822104319"></span>. You are not advised to delete this tag. Otherwise, the <span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text1485522214434">BMS</span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text17855822144320"></span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text208558227431"></span> will be displayed only on the ECS console.</li><li id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_li54881723385">After deleting the <strong id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_b1946315231436">__type_baremetal</strong> tag, you can add it again by following the instructions in <a href="en-us_topic_0000002374101049.html#EN-US_TOPIC_0000002374101049">Adding a Tag for a BMS</a>. After the tag is added, the <span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text19665257155320">BMS</span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text1266555713535"></span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text5631132924417"></span> will be displayed on the BMS console.</li></ul>
</div></div>
</div>
<div class="section" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_section3181044105534"><h4 class="sectiontitle">URI</h4><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p67083394105534">DELETE /v2.1/{project_id}/servers/{server_id}/tags/{tag}</p>
<p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p51059371521"><a href="#EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_table105191945325">Table 1</a> lists the parameters.</p>
<div class="tablenoborder"><a name="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_table105191945325"></a><a name="en-us_topic_0060424486_table105191945325"></a><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_table105191945325" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_row55201745523"><th align="left" class="cellrowborder" valign="top" width="23.03230323032303%" id="mcps1.3.3.4.2.4.1.1"><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p67050730103718">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="24.782478247824784%" id="mcps1.3.3.4.2.4.1.2"><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p55073076202321">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="52.185218521852185%" id="mcps1.3.3.4.2.4.1.3"><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p21237868103718">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_row165207451427"><td class="cellrowborder" valign="top" width="23.03230323032303%" headers="mcps1.3.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p23650911103718">project_id</p>
</td>
<td class="cellrowborder" valign="top" width="24.782478247824784%" headers="mcps1.3.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p36675672103718">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="52.185218521852185%" headers="mcps1.3.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p17939461103718">Specifies the project ID.</p>
<p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p9141450142010">For 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="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_row1752024519217"><td class="cellrowborder" valign="top" width="23.03230323032303%" headers="mcps1.3.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p18738546141829">server_id</p>
</td>
<td class="cellrowborder" valign="top" width="24.782478247824784%" headers="mcps1.3.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p41427238141829">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="52.185218521852185%" headers="mcps1.3.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p163111141829">Specifies the <span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text1185913451434">BMS</span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text486034515437"></span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text3860134515436"></span> ID.</p>
<p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p29791113277">You can obtain the BMS ID from the <span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0113746489_text895314101319">BMS</span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0113746489_text1695320481317"></span> console or by calling the API <a href="en-us_topic_0000002340063012.html">Querying BMSs</a>.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_row4520184517219"><td class="cellrowborder" valign="top" width="23.03230323032303%" headers="mcps1.3.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p54908755151432">tag</p>
</td>
<td class="cellrowborder" valign="top" width="24.782478247824784%" headers="mcps1.3.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p18424196151432">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="52.185218521852185%" headers="mcps1.3.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p3844311810">Specifies the tag information.</p>
<p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p1648373542814">Constraints:</p>
<ul id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_ul16436151718351"><li id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_li3436117113517">A tag can contain a maximum of 80 characters. If a tag contains non-URL-safe characters, perform URL encoding.</li><li id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_li16436517143511">If no key is specified, all tags of the <span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text14203744549">BMS</span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text62039475411"></span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text12147175724411"></span> are deleted.</li></ul>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_section61879170105534"><h4 class="sectiontitle">Request Parameters</h4><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p198782519109">None</p>
</div>
<div class="section" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_section68905592277"><h4 class="sectiontitle">Example Request</h4><div class="p" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p8990122233813">Deleting a tag from a <span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text169161430191210">BMS</span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text1916183011217"></span><span id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_text491693061210"></span> (ID: 53206ed0-56de-4d6b-b7ee-ffc62ca26f43)<div class="codecoloring" codetype="Java" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_screen692717114116"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span></pre></div></td><td class="code"><div><pre><span></span><span class="n">DELETE</span><span class="w"> </span><span class="n">https</span><span class="p">:</span><span class="c1">//{ECS Endpoint}/v2.1/bbf1946d374b44a0a2a95533562ba954/servers/53206ed0-56de-4d6b-b7ee-ffc62ca26f43/tags/{tag}</span>
</pre></div></td></tr></table></div>
</div>
</div>
</div>
<div class="section" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_section33789573105534"><h4 class="sectiontitle">Response</h4><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_p18832719143830">N/A</p>
</div>
<div class="section" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_section27037160"><h4 class="sectiontitle">Returned Values</h4><div class="p" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0053158659_p1271142611013">Normal values
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0053158659_table753804619176" frame="border" border="1" rules="all"><thead align="left"><tr id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0053158659_row10735134615172"><th align="left" class="cellrowborder" valign="top" width="42.42%" id="mcps1.3.7.2.1.1.3.1.1"><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0053158659_p19735204616177">Returned Values</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="57.58%" id="mcps1.3.7.2.1.1.3.1.2"><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0053158659_p207355465176">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0053158659_row1473514621713"><td class="cellrowborder" valign="top" width="42.42%" headers="mcps1.3.7.2.1.1.3.1.1 "><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0053158659_p13735144611178">204</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.7.2.1.1.3.1.2 "><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0053158659_p81516575011">The server has processed the request but did not return any content.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0053158659_p47633965">For details about other returned values, see <a href="en-us_topic_0053158690.html">Status Codes</a>.</p>
</div>
<div class="section" id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_section14752650154917"><h4 class="sectiontitle">Error Codes</h4><p id="EN-US_TOPIC_0000002340222828__en-us_topic_0060424486_en-us_topic_0106040941_p10243161417491">See <a href="en-us_topic_0107541808.html">Error Codes</a>.</p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="en-us_topic_0000002374101045.html">BMS 1D Tag Management (OpenStack Nova APIs)</a></div>
</div>
</div>