Remove Devices from Group

Last Updated on : 2023-06-15 05:04:05

Remove devices from a device group. Up to 20 devices can be removed each time.

API address

POST: /v1.0/iot-03/device-groups/{group_id}/actions/device-remove

Request parameter

Parameter nameTypeINRequiredDescription
group_idStringuritrueThe ID of a specified group.

Description of body

Parameter nameTypeINRequiredDescription
device_idsListbodytrueThe ID sets of devices to be removed.

Return parameter

Parameter nameTypeDescription
resultGroupPackageTaskVOThe returned result.

Description of result

Parameter nameTypeDescription
group_idStringThe ID of a specified group.
task_idStringThe ID of a specified task.
expire_timeLongThe expiration time in seconds.

Request example

POST: /v1.0/iot-03/device-groups/14308xxxx887268904/actions/device-remove
{
  "device_ids": [
    "vdevo16292xxxx310895"
  ]
}

Return example

{
    "result": {
        "expire_time": 10,
        "task_id": "143253xxxx5458899",
        "group_id": "14308xxxx887268904"
    },
    "t": 1630379063616,
    "success": true
}

Error code

For more information, see error code.