Files
doc-exports/docs/lts/api-ref/ListHostGroup.html
liusiying77 fdbbe7547a LTS API 20240130 version.
Reviewed-by: Bobkova, Natalia <natalia.bobkova@t-systems.com>
Reviewed-by: Hasko, Vladimir <vladimir.hasko@t-systems.com>
Co-authored-by: liusiying77 <liusiying@huawei.com>
Co-committed-by: liusiying77 <liusiying@huawei.com>
2025-03-12 12:37:01 +00:00

498 lines
34 KiB
HTML

<a name="ListHostGroup"></a><a name="ListHostGroup"></a>
<h1 class="topictitle1">Querying Host Groups</h1>
<div id="body1708331107508"><div class="section" id="ListHostGroup__section534719555315"><h4 class="sectiontitle">Function</h4><p id="ListHostGroup__p03481553316">Query the host group list.</p>
</div>
<div class="section" id="ListHostGroup__section23482550314"><h4 class="sectiontitle">URI</h4><p id="ListHostGroup__p183486553318">POST /v3/{project_id}/lts/host-group-list</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="ListHostGroup__table1034895511311" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Path Parameters</caption><thead align="left"><tr id="ListHostGroup__row6348165517310"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.2.3.2.5.1.1"><p id="ListHostGroup__p434912555312">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.2.3.2.5.1.2"><p id="ListHostGroup__p134912554317">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.2.3.2.5.1.3"><p id="ListHostGroup__p1034911553319">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.2.3.2.5.1.4"><p id="ListHostGroup__p734935583115">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="ListHostGroup__row534819558311"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.2.3.2.5.1.1 "><p id="ListHostGroup__p134915515319">project_id</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.2.3.2.5.1.2 "><p id="ListHostGroup__p2350165513312">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.2.3.2.5.1.3 "><p id="ListHostGroup__p1635015513119">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.2.3.2.5.1.4 "><p id="ListHostGroup__p43500555317">Project ID. For details about how to obtain a project ID, see <a href="lts_api_0006.html">Obtaining the Project ID, Account ID, Log Group ID, and Log Stream ID</a>.</p>
<p id="ListHostGroup__p163501655203110">Minimum: <strong id="ListHostGroup__b20351125503116">1</strong></p>
<p id="ListHostGroup__p0351175573115">Maximum: <strong id="ListHostGroup__b7351155593114">64</strong></p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="ListHostGroup__section1035120559316"><h4 class="sectiontitle">Request Parameters</h4>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="ListHostGroup__HeaderParameter" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Request header parameters</caption><thead align="left"><tr id="ListHostGroup__row435265516319"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.2.2.5.1.1"><p id="ListHostGroup__p1535512552311">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.2.2.5.1.2"><p id="ListHostGroup__p1535585518311">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.2.2.5.1.3"><p id="ListHostGroup__p1235613557313">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.3.2.2.5.1.4"><p id="ListHostGroup__p1235620558311">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="ListHostGroup__row1835415543120"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.2.5.1.1 "><p id="ListHostGroup__p1135635593119">X-Auth-Token</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.2.5.1.2 "><p id="ListHostGroup__p3357555133110">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.2.5.1.3 "><p id="ListHostGroup__p935711550313">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.2.2.5.1.4 "><p id="ListHostGroup__p18357135514318">User token obtained from IAM. For details about how to obtain a user token, see <a href="lts_api_0004.html">Obtaining a User Token</a>.</p>
<p id="ListHostGroup__p1435785512319">Minimum: <strong id="ListHostGroup__b1435915533110">1</strong></p>
<p id="ListHostGroup__p15359155518315">Maximum: <strong id="ListHostGroup__b635913559314">10000</strong></p>
</td>
</tr>
<tr id="ListHostGroup__row1935435523117"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.2.5.1.1 "><p id="ListHostGroup__p133591155143119">Content-Type</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.2.5.1.2 "><p id="ListHostGroup__p436025511311">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.2.5.1.3 "><p id="ListHostGroup__p6360155511318">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.2.2.5.1.4 "><p id="ListHostGroup__p113604559316">Set this parameter to application/json;charset=UTF-8.</p>
<p id="ListHostGroup__p12360955143117">Minimum: <strong id="ListHostGroup__b7360145512310">30</strong></p>
<p id="ListHostGroup__p18360955113120">Maximum: <strong id="ListHostGroup__b1336045503116">30</strong></p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="ListHostGroup__request_GetHostGroupListRequestBody" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Request body parameters</caption><thead align="left"><tr id="ListHostGroup__row15361175519314"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.1"><p id="ListHostGroup__p236215583115">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.2"><p id="ListHostGroup__p173621555183118">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.3"><p id="ListHostGroup__p336219558311">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.3.3.2.5.1.4"><p id="ListHostGroup__p1736212559310">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="ListHostGroup__row1136115516319"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.1 "><p id="ListHostGroup__p836245514317">host_group_id_list</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.2 "><p id="ListHostGroup__p63626559318">No</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.3 "><p id="ListHostGroup__p17363955163115">Array of strings</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.3.2.5.1.4 "><p id="ListHostGroup__p19363195513112">List of host group IDs.</p>
<p id="ListHostGroup__p12363125514314">Minimum: <strong id="ListHostGroup__b336311557316">36</strong></p>
<p id="ListHostGroup__p73637553316">Maximum: <strong id="ListHostGroup__b436315511314">36</strong></p>
</td>
</tr>
<tr id="ListHostGroup__row2361155519315"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.1 "><p id="ListHostGroup__p9363195583110">filter</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.2 "><p id="ListHostGroup__p1436317554314">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.3 "><p id="ListHostGroup__p1936311555315"><a href="#ListHostGroup__request_GetHostGroupListFilter">GetHostGroupListFilter</a> object</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.3.2.5.1.4 "><p id="ListHostGroup__p11364355183113">Host group filters.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="ListHostGroup__request_GetHostGroupListFilter"></a><a name="request_GetHostGroupListFilter"></a><table cellpadding="4" cellspacing="0" summary="" id="ListHostGroup__request_GetHostGroupListFilter" frame="border" border="1" rules="all"><caption><b>Table 4 </b>GetHostGroupListFilter</caption><thead align="left"><tr id="ListHostGroup__row18364125513112"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.4.2.5.1.1"><p id="ListHostGroup__p436665583118">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.4.2.5.1.2"><p id="ListHostGroup__p7366135563117">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.4.2.5.1.3"><p id="ListHostGroup__p53661955173112">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.3.4.2.5.1.4"><p id="ListHostGroup__p203661555103119">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="ListHostGroup__row1436465513118"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.1 "><p id="ListHostGroup__p93661255103116">host_group_type</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.2 "><p id="ListHostGroup__p536718559315">No</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.3 "><p id="ListHostGroup__p336712551319">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.4.2.5.1.4 "><p id="ListHostGroup__p2367555153111">Host group type.</p>
<ul id="ListHostGroup__ul1636715510313"><li id="ListHostGroup__li1836705523116">Windows</li><li id="ListHostGroup__li12367125510318">Linux</li></ul>
</td>
</tr>
<tr id="ListHostGroup__row2036515557311"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.1 "><p id="ListHostGroup__p12367115513114">host_group_name_list</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.2 "><p id="ListHostGroup__p6368455163112">No</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.3 "><p id="ListHostGroup__p19368155143113">Array of strings</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.4.2.5.1.4 "><p id="ListHostGroup__p17368055133115">List of host group names.</p>
<p id="ListHostGroup__p12368195520313">Minimum: <strong id="ListHostGroup__b153685557316">1</strong></p>
<p id="ListHostGroup__p133681355203110">Maximum: <strong id="ListHostGroup__b2036845593117">64</strong></p>
</td>
</tr>
<tr id="ListHostGroup__row14365355103112"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.1 "><p id="ListHostGroup__p43691955183116">host_name_list</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.2 "><p id="ListHostGroup__p17369135573110">No</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.3 "><p id="ListHostGroup__p15369155516316">Array of strings</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.4.2.5.1.4 "><p id="ListHostGroup__p6369185515312">Host name list.</p>
<p id="ListHostGroup__p193699552314">Minimum: <strong id="ListHostGroup__b14369195519319">1</strong></p>
<p id="ListHostGroup__p836920552311">Maximum: <strong id="ListHostGroup__b836925513117">128</strong></p>
</td>
</tr>
<tr id="ListHostGroup__row14365155515316"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.1 "><p id="ListHostGroup__p1636945520318">host_group_tag</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.2 "><p id="ListHostGroup__p15369125533114">No</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.3 "><p id="ListHostGroup__p33691655113111"><a href="#ListHostGroup__request_GetHostGroupListTag">GetHostGroupListTag</a> object</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.4.2.5.1.4 "><p id="ListHostGroup__p936913559317">Host group tags.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="ListHostGroup__request_GetHostGroupListTag"></a><a name="request_GetHostGroupListTag"></a><table cellpadding="4" cellspacing="0" summary="" id="ListHostGroup__request_GetHostGroupListTag" frame="border" border="1" rules="all"><caption><b>Table 5 </b>GetHostGroupListTag</caption><thead align="left"><tr id="ListHostGroup__row153701550319"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.5.2.5.1.1"><p id="ListHostGroup__p0371105593118">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.5.2.5.1.2"><p id="ListHostGroup__p1637111558314">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.5.2.5.1.3"><p id="ListHostGroup__p1837145563111">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.3.5.2.5.1.4"><p id="ListHostGroup__p1937218555311">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="ListHostGroup__row173700556314"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.5.2.5.1.1 "><p id="ListHostGroup__p173721755123119">tag_type</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.5.2.5.1.2 "><p id="ListHostGroup__p203729552319">No</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.5.2.5.1.3 "><p id="ListHostGroup__p14372555193114">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.5.2.5.1.4 "><p id="ListHostGroup__p9372555133116">Tag type. Tag filtering logic: <strong id="ListHostGroup__b163721555153114">AND</strong> or <strong id="ListHostGroup__b123724552318">OR</strong>.</p>
</td>
</tr>
<tr id="ListHostGroup__row03704554317"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.5.2.5.1.1 "><p id="ListHostGroup__p1937275514314">tag_list</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.5.2.5.1.2 "><p id="ListHostGroup__p03731455203113">No</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.5.2.5.1.3 "><p id="ListHostGroup__p2037335511311">Array of <a href="#ListHostGroup__request_HostGroupTag">HostGroupTag</a> objects</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.5.2.5.1.4 "><p id="ListHostGroup__p12373125515317">Host group tags.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="ListHostGroup__request_HostGroupTag"></a><a name="request_HostGroupTag"></a><table cellpadding="4" cellspacing="0" summary="" id="ListHostGroup__request_HostGroupTag" frame="border" border="1" rules="all"><caption><b>Table 6 </b>HostGroupTag</caption><thead align="left"><tr id="ListHostGroup__row1637335523112"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.6.2.5.1.1"><p id="ListHostGroup__p7373155593118">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.6.2.5.1.2"><p id="ListHostGroup__p1937317553313">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.6.2.5.1.3"><p id="ListHostGroup__p237445519315">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.3.6.2.5.1.4"><p id="ListHostGroup__p20374195523116">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="ListHostGroup__row143731155113114"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.6.2.5.1.1 "><p id="ListHostGroup__p133741155193119">key</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.6.2.5.1.2 "><p id="ListHostGroup__p14374105513110">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.6.2.5.1.3 "><p id="ListHostGroup__p1237415554314">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.6.2.5.1.4 "><p id="ListHostGroup__p1037465512316">Tag key. Use only UTF-8 letters, digits, spaces, and the following characters: .:=+-@. Do not start with an underscore (). Max 128 characters are allowed.</p>
</td>
</tr>
<tr id="ListHostGroup__row4373175553115"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.6.2.5.1.1 "><p id="ListHostGroup__p16374175512314">value</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.6.2.5.1.2 "><p id="ListHostGroup__p33746557319">No</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.6.2.5.1.3 "><p id="ListHostGroup__p437435514311">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.6.2.5.1.4 "><p id="ListHostGroup__p9374455173110">Tag value. Use only UTF-8 letters, digits, spaces, and the following characters: _.:/=+-@. Max 255 characters are allowed.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="ListHostGroup__section103741455173112"><h4 class="sectiontitle">Response Parameters</h4><p id="ListHostGroup__p153751655143119"><strong id="ListHostGroup__b1337510552312">Status code: 200</strong></p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="ListHostGroup__response_GetHostGroupListResponseBody" frame="border" border="1" rules="all"><caption><b>Table 7 </b>Response body parameters</caption><thead align="left"><tr id="ListHostGroup__row17375125563114"><th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.4.3.2.4.1.1"><p id="ListHostGroup__p537514556318">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.4.3.2.4.1.2"><p id="ListHostGroup__p1937514554316">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="50%" id="mcps1.3.4.3.2.4.1.3"><p id="ListHostGroup__p16375155514311">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="ListHostGroup__row637517553313"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.3.2.4.1.1 "><p id="ListHostGroup__p137511555312">result</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.3.2.4.1.2 "><p id="ListHostGroup__p133751255153119">Array of <a href="#ListHostGroup__response_GetHostGroupInfo">GetHostGroupInfo</a> objects</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.3.2.4.1.3 "><p id="ListHostGroup__p837617556314">Host group list.</p>
</td>
</tr>
<tr id="ListHostGroup__row5375955153110"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.3.2.4.1.1 "><p id="ListHostGroup__p537612553318">total</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.3.2.4.1.2 "><p id="ListHostGroup__p11376145513318">Long</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.3.2.4.1.3 "><p id="ListHostGroup__p637614551312">Total number of host groups.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="ListHostGroup__response_GetHostGroupInfo"></a><a name="response_GetHostGroupInfo"></a><table cellpadding="4" cellspacing="0" summary="" id="ListHostGroup__response_GetHostGroupInfo" frame="border" border="1" rules="all"><caption><b>Table 8 </b>GetHostGroupInfo</caption><thead align="left"><tr id="ListHostGroup__row6376135553110"><th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.4.4.2.4.1.1"><p id="ListHostGroup__p11377955173118">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.4.4.2.4.1.2"><p id="ListHostGroup__p537785513313">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="50%" id="mcps1.3.4.4.2.4.1.3"><p id="ListHostGroup__p137715513314">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="ListHostGroup__row9376355103119"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.1 "><p id="ListHostGroup__p33771055103110">host_group_id</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.2 "><p id="ListHostGroup__p1137712558317">String</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.4.2.4.1.3 "><p id="ListHostGroup__p53771655133116">Host group ID.</p>
</td>
</tr>
<tr id="ListHostGroup__row7376125517318"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.1 "><p id="ListHostGroup__p203771955123118">host_group_name</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.2 "><p id="ListHostGroup__p1537795573120">String</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.4.2.4.1.3 "><p id="ListHostGroup__p637725512318">Host group name.</p>
</td>
</tr>
<tr id="ListHostGroup__row1037645583114"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.1 "><p id="ListHostGroup__p93771855143112">host_group_type</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.2 "><p id="ListHostGroup__p8377125583119">String</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.4.2.4.1.3 "><p id="ListHostGroup__p20377255123110">Host group type.</p>
</td>
</tr>
<tr id="ListHostGroup__row193761155183118"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.1 "><p id="ListHostGroup__p1337810559317">host_id_list</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.2 "><p id="ListHostGroup__p1737835516311">Array of strings</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.4.2.4.1.3 "><p id="ListHostGroup__p10378125515317">Host ID list.</p>
</td>
</tr>
<tr id="ListHostGroup__row1376115511317"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.1 "><p id="ListHostGroup__p2037875519316">host_group_tag</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.2 "><p id="ListHostGroup__p1937885519311">Array of <a href="#ListHostGroup__response_HostGroupTagResBody">HostGroupTagResBody</a> objects</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.4.2.4.1.3 "><p id="ListHostGroup__p10378185563115">Tag information.</p>
</td>
</tr>
<tr id="ListHostGroup__row1737695510312"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.1 "><p id="ListHostGroup__p137875523117">create_time</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.2 "><p id="ListHostGroup__p173785552310">Long</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.4.2.4.1.3 "><p id="ListHostGroup__p237895593118">Creation time.</p>
</td>
</tr>
<tr id="ListHostGroup__row73761555153115"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.1 "><p id="ListHostGroup__p12378755193114">update_time</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.2 "><p id="ListHostGroup__p14378185543110">Long</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.4.2.4.1.3 "><p id="ListHostGroup__p13378145511315">Update time.</p>
</td>
</tr>
<tr id="ListHostGroup__row2376185513317"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.1 "><p id="ListHostGroup__p737975513115">labels</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.2 "><p id="ListHostGroup__p6379165533116">Array of strings</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.4.2.4.1.3 "><p id="ListHostGroup__p33791355163111">Host group ID.</p>
</td>
</tr>
<tr id="ListHostGroup__row137675563116"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.1 "><p id="ListHostGroup__p1937985553110">agent_access_type</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.4.2.4.1.2 "><p id="ListHostGroup__p203798559316">String</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.4.2.4.1.3 "><p id="ListHostGroup__p337945510313">Host access type.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="ListHostGroup__response_HostGroupTagResBody"></a><a name="response_HostGroupTagResBody"></a><table cellpadding="4" cellspacing="0" summary="" id="ListHostGroup__response_HostGroupTagResBody" frame="border" border="1" rules="all"><caption><b>Table 9 </b>HostGroupTagResBody</caption><thead align="left"><tr id="ListHostGroup__row73796557318"><th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.4.5.2.4.1.1"><p id="ListHostGroup__p3379145517312">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.4.5.2.4.1.2"><p id="ListHostGroup__p11380175517313">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="50%" id="mcps1.3.4.5.2.4.1.3"><p id="ListHostGroup__p15380055193114">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="ListHostGroup__row73795552316"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.5.2.4.1.1 "><p id="ListHostGroup__p14380145533120">key</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.5.2.4.1.2 "><p id="ListHostGroup__p5380105503110">String</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.5.2.4.1.3 "><p id="ListHostGroup__p153801855133115">Tag key.</p>
</td>
</tr>
<tr id="ListHostGroup__row33791755123111"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.5.2.4.1.1 "><p id="ListHostGroup__p1838085512312">value</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.5.2.4.1.2 "><p id="ListHostGroup__p638016558315">String</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.5.2.4.1.3 "><p id="ListHostGroup__p33801155193115">Tag value.</p>
</td>
</tr>
<tr id="ListHostGroup__row137911552319"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.5.2.4.1.1 "><p id="ListHostGroup__p4380455113115">tags_to_streams_enable</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.5.2.4.1.2 "><p id="ListHostGroup__p1438025543116">Boolean</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.5.2.4.1.3 "><p id="ListHostGroup__p23805557314">Whether to apply the tag to the log stream. Only a tag of a log group can be directly applied to its log stream.</p>
</td>
</tr>
</tbody>
</table>
</div>
<p id="ListHostGroup__p1138085553115"><strong id="ListHostGroup__b1938018552314">Status code: 400</strong></p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="ListHostGroup__response_GetHostListErrorRsp" frame="border" border="1" rules="all"><caption><b>Table 10 </b>Response body parameters</caption><thead align="left"><tr id="ListHostGroup__row1838045593120"><th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.4.7.2.4.1.1"><p id="ListHostGroup__p2381755173110">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.4.7.2.4.1.2"><p id="ListHostGroup__p5381155583116">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="50%" id="mcps1.3.4.7.2.4.1.3"><p id="ListHostGroup__p1438114556312">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="ListHostGroup__row638005573112"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.7.2.4.1.1 "><p id="ListHostGroup__p338116559311">error_code</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.7.2.4.1.2 "><p id="ListHostGroup__p838115552314">String</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.7.2.4.1.3 "><p id="ListHostGroup__p138118552317">Error code.</p>
</td>
</tr>
<tr id="ListHostGroup__row2380175512313"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.7.2.4.1.1 "><p id="ListHostGroup__p11381175515319">error_msg</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.7.2.4.1.2 "><p id="ListHostGroup__p12381145512319">String</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.7.2.4.1.3 "><p id="ListHostGroup__p2381125513116">Error message.</p>
</td>
</tr>
</tbody>
</table>
</div>
<p id="ListHostGroup__p163811755113112"><strong id="ListHostGroup__b138145510315">Status code: 500</strong></p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="ListHostGroup__table19381205523113" frame="border" border="1" rules="all"><caption><b>Table 11 </b>Response body parameters</caption><thead align="left"><tr id="ListHostGroup__row5381165553116"><th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.4.9.2.4.1.1"><p id="ListHostGroup__p5382195515315">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="25%" id="mcps1.3.4.9.2.4.1.2"><p id="ListHostGroup__p19382155514311">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="50%" id="mcps1.3.4.9.2.4.1.3"><p id="ListHostGroup__p1338215553116">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="ListHostGroup__row338165563118"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.9.2.4.1.1 "><p id="ListHostGroup__p738245543111">error_code</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.9.2.4.1.2 "><p id="ListHostGroup__p1383655133113">String</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.9.2.4.1.3 "><p id="ListHostGroup__p12383955203114">Error code.</p>
</td>
</tr>
<tr id="ListHostGroup__row838215559313"><td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.9.2.4.1.1 "><p id="ListHostGroup__p83831255133116">error_msg</p>
</td>
<td class="cellrowborder" valign="top" width="25%" headers="mcps1.3.4.9.2.4.1.2 "><p id="ListHostGroup__p4383195553114">String</p>
</td>
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.4.9.2.4.1.3 "><p id="ListHostGroup__p93831155143120">Error message.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="ListHostGroup__section538325510314"><h4 class="sectiontitle">Example Requests</h4><p id="ListHostGroup__p0384115513114">Host groups are sorted by filters specified in the request body. If no filters are configured in the body, all host groups are queried.</p>
<pre class="screen" id="ListHostGroup__screen43854557311">POST https://{endpoint}/v3/{project_id}/lts/host-group-list
{
"host_group_id_list" : [ "bca6d903-3528-42a8-91f4-586722cxxxxx" ],
"filter" : {
"host_group_type" : "linux",
"host_group_name_list" : [ "wjyTxxx" ],
"host_name_list" : [ "ecs-apmtexxxdeletion" ],
"host_group_tag" : {
"tag_type" : "AND",
"tag_list" : [ {
"key" : "xxx",
"value" : "xxx",
"tags_to_streams_enable" : true
} ]
}
}
}</pre>
</div>
<div class="section" id="ListHostGroup__section116241255193120"><h4 class="sectiontitle">Example Responses</h4><p id="ListHostGroup__p12624055173117"><strong id="ListHostGroup__b16241955193119">Status code: 200</strong></p>
<p id="ListHostGroup__p9624455173112">The host group query is successful.</p>
<pre class="screen" id="ListHostGroup__screen166241655153118">{
"result" : [ {
"host_group_id" : "598c77aa-c69b-42f0-8cb8-xxxx5b38",
"host_group_name" : "wjyTxxx",
"host_group_type" : "linux",
"host_id_list" : [ "dc1dab7e-b04xxxx", "xxxxx" ],
"host_group_tag" : [ {
"key" : "xxx",
"value" : "xxx"
} ],
"create_time" : 1635459410332,
"update_time" : 163560332
} ],
"total" : 1
}</pre>
<p id="ListHostGroup__p862414559319"><strong id="ListHostGroup__b96241955163119">Status code: 400</strong></p>
<p id="ListHostGroup__p2062413555310">Invalid request. Modify the request based on the description in <strong id="ListHostGroup__b12624175513117">error_msg</strong> before a retry.</p>
<pre class="screen" id="ListHostGroup__screen762435513113">{
"error_code" : "LTS.1807",
"error_msg" : "Invalid host group id"
}</pre>
<p id="ListHostGroup__p1462435516312"><strong id="ListHostGroup__b16624165543114">Status code: 500</strong></p>
<p id="ListHostGroup__p11624145515314">The server has received the request but encountered an internal error.</p>
<pre class="screen" id="ListHostGroup__screen1262445511312">{
"error_code" : "LTS.0010",
"error_msg" : "Internal Server Error"
}</pre>
</div>
<div class="section" id="ListHostGroup__section062514559318"><h4 class="sectiontitle">Status Codes</h4>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="ListHostGroup__status_code" frame="border" border="1" rules="all"><thead align="left"><tr id="ListHostGroup__row839116551314"><th align="left" class="cellrowborder" valign="top" width="15%" id="mcps1.3.7.2.1.3.1.1"><p id="ListHostGroup__p56253557317">Status Code</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="85%" id="mcps1.3.7.2.1.3.1.2"><p id="ListHostGroup__p262505543111">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="ListHostGroup__row18391125503116"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.7.2.1.3.1.1 "><p id="ListHostGroup__p106251554318">200</p>
</td>
<td class="cellrowborder" valign="top" width="85%" headers="mcps1.3.7.2.1.3.1.2 "><p id="ListHostGroup__p4625155133112">The host group query is successful.</p>
</td>
</tr>
<tr id="ListHostGroup__row739115558311"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.7.2.1.3.1.1 "><p id="ListHostGroup__p156253550312">400</p>
</td>
<td class="cellrowborder" valign="top" width="85%" headers="mcps1.3.7.2.1.3.1.2 "><p id="ListHostGroup__p1762545512312">Invalid request. Modify the request based on the description in <strong id="ListHostGroup__b16625855123120">error_msg</strong> before a retry.</p>
</td>
</tr>
<tr id="ListHostGroup__row1539185519314"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.7.2.1.3.1.1 "><p id="ListHostGroup__p17625555133118">500</p>
</td>
<td class="cellrowborder" valign="top" width="85%" headers="mcps1.3.7.2.1.3.1.2 "><p id="ListHostGroup__p2625755123112">The server has received the request but encountered an internal error.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="ListHostGroup__section262515520316"><h4 class="sectiontitle">Error Codes</h4><p id="ListHostGroup__p12625175523111">See <a href="ErrorCode.html">Error Codes</a>.</p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="lts_api_1015.html">Host Group Management</a></div>
</div>
</div>