Specifies properties for multiple devices.


Each Alibaba Cloud account can run a maximum of 10 queries per second (QPS).

Note Resource Access Management (RAM) users share the quota of the Alibaba Cloud account.


OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes SetDevicesProperty

The operation that you want to perform. Set the value to SetDevicesProperty.

DeviceName.N RepeatList Yes light

The names of devices for which you want to specifies properties. You can specify a maximum of 100 devices at a time.

Items String Yes {"Switch":1,"Color":"blue"}

The information of properties. The information must be in the JSON format.

The information of each property consists of a key-value pair in the key:value format. Separate multiple pairs with commas (,).

For example, specify the following properties for a smart light:

  • A switch property whose identifier is Switch and the data type is Boolean. Set the value to 1. The value 1 indicates that the light is on.
  • A color property whose identifier is Color and the data type is String. Set the value to blue.

In this case, you can set the Items parameter to {"Switch":1,"Color":"blue"}.

Note If the preceding properties belong to a custom module named testFB, you can set the Items parameter to {"testFb:Switch":1,"testFb:Color":"blue"}. The custom module is not the default module.
ProductKey String Yes a1BwAGV****

The key of the product to which the devices belong.

IotInstanceId String No iot_instc_pu****_c*-v64********

The instance ID. This parameter is not required for the public instance. However, this parameter is required for Enterprise Edition instances.

In addition to the preceding operation-specific request parameters, you must specify common request parameters when you call this API operation. For more information, see Common request parameters.

Response parameters

Parameter Type Example Description
Code String iot.system.SystemException

The error code returned if the call fails. For more information, see Error codes.

ErrorMessage String A system exception has occurred.

The error message returned if the call fails.

RequestId String E55E50B7-40EE-4B6B-8BBE-D3ED55CCF565

The ID of the request.

Success Boolean true

Indicates whether the call succeeds.

  • true: The call succeeded.
  • false: The call failed.


Sample requests

&<Common request parameters>

Sample success responses

XML format


JSON format

  "RequestId": "2E19BDAF-0FD0-4608-9F41-82D230CFEE38",
  "Success": true

Error codes

For a list of error codes, visit the API Error Center.