Device Goes Online

Last Updated on : 2023-06-20 12:39:04

The partner synchronizes the online status of the specified device to Tuya based on the network connection of the device.

API address

PUT: /v1.0/iot-03/3rdcloud/devices/{device_id}/online

Request parameter

Parameter nameTypeINRequiredDescription
device_idStringuritrueThe ID of the specified Tuya-enabled device.

Return parameter

Parameter nameTypeDescription
resultBooleanThe response result.
codeStringThe response code. It is empty when the request succeeded.
msgStringThe message that is returned if the request fails. It is empty if the request is successful.
successBooleanIndicates whether the request is successful. Valid values:
  • true: success.
  • false: failure.
tLongThe 13-digit timestamp of a response.

Request example

PUT: /v1.0/iot-03/3rdcloud/devices/6cf4171005d11e2ca7****/online

Return example

{
    "result": true,
    "t": 1649993753725,
    "success": true
}

Error code

For more information, see error code.