This method allows to simultaneously replace or remove related objects for multiple host groups.该方法允许同时替换或删除多个主机组的相关对象。

    Parameters 参数

    (object) Parameters containing the IDs of the host groups to update and the objects that should be updated. 包含要更新的主机组的ID和应更新的对象的参数。

    (object) Returns an object containing the IDs of the updated host groups under the property.返回包含“groupids”属性下更新的主机组的ID的对象。

    Examples 示例

    Replacing hosts in a host group 更换主机组中的主机

    Request:

    Response:

    1. {
    2. "jsonrpc": "2.0",
    3. "result": {
    4. "groupids": [
    5. "6",
    6. ]
    7. "id": 1
    8. }

    Source 来源

    CHostGroup::massUpdate() in frontends/php/include/classes/api/services/CHostGroup.php.