Add Device to Group

Last Updated on : 2023-07-06 07:59:23download

Add devices to a device group. Up to 20 devices can be added each time.

API address

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

Request parameter

Parameter nameTypeINRequiredDescription
group_idStringuritrueThe ID of a specified group.

Description of body

Parameter nameTypeINRequiredDescription
device_idsListbodytrueThe ID sets of devices to be added.

Return parameter

Parameter nameTypeDescription
resultGroupPackageTaskVOThe returned result.

Description of result

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

Request example

POST: /v1.0/iot-03/device-groups/1430809xxxx8728904/actions/device-add

Error code

For more information, see error code.