Registers multiple devices in a product. The names of these devices are randomly generated.

Usage notes

You can use one of the following methods to register multiple devices:

  • Call the BatchRegisterDevice operation to generate random device names.

    Perform the following steps to register devices and view the results.

    1. Call the BatchRegisterDevice operation to register multiple devices. If a successful result is returned, it indicates that a batch registration request is submitted. In practice, devices are asynchronously registered. The process takes a few minutes.

    2. Call the QueryBatchRegisterDeviceStatus operation to view the results of device registration.

    3. Call the QueryPageByApplyId operation to view the details of registered devices. The details include the device names, device secrets, and device IDs.

  • Call the BatchRegisterDeviceWithApplyId operation to specify custom device names. For more information, see BatchRegisterDeviceWithApplyId.


  • You can create a maximum of 10,000 devices in a single call.
  • 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 BatchRegisterDevice

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

Count Integer Yes 100

The name of the device.

Note You can create up to 10,000 devices in a single call.
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 public instances. 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.

Data Struct

The data returned if the call succeeds.

ApplyId Long 1295006

The application ID (ApplyId) returned for the request if the call succeeds.

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

	"Data": {
		"ApplyId": 12345678
	"RequestId": "92C67DC1-41B5-45F8-9AFD-1FB42448D405",
	"Success": true

Error codes

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