Queries the processing status and result of device registration for multiple devices.

Limits

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

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

Debugging

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 QueryBatchRegisterDeviceStatus

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

ApplyId Long Yes 1295006

The application ID. The application ID is included in the successful result that is returned by the BatchRegisterDeviceWithApplyId or BatchRegisterDevice operation.

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, the parameter is required for the instances that you have purchased.

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.

Note X.509 certificates are available only for devices in the China (Shanghai) region. If devices do not reside in the China (Shanghai) region, you cannot generate X.509 certificates for these devices and the iot.device.RegionNotSupportX509 error code is returned.
Data Struct

The status information returned if the call succeeds.

InvalidList List { "Name": [] }
  • If the value of the Status parameter is CHECK_FAILED or CREATE_FAILED, the names of the devices that fail to be created are returned.
  • If the value of the Status parameter is CHECK_SUCCESS or CREATE_SUCCESS, this parameter includes an empty array.
Status String CREATE_SUCCESS

The processing status and result. Valid values:

  • CHECK: The system is verifying device names.
  • CHECK_SUCCESS: All devices in the application form are verified.
  • CHECK_FAILED: All devices in the application form fail to be verified.
  • CREATE: The system is creating devices.
  • CREATE_SUCCESS: All devices in the application form are created.
    Note If the authentication type of the product to which the devices belong is X.509 certificate, it indicates that all devices and the related X.509 certificates are created.
  • CREATE_FAILED: All devices in the application form fail to be created.
    Note If a device or X.509 certificate fails to be created in the current batch when the authentication type is X.509, all devices fail to be created.
ValidList List { "Name": [] }
  • If the value of the Status parameter is CHECK_FAILED or CREATE_FAILED, the names of the created devices are returned.
  • If the value of the Status parameter is CHECK_SUCCESS or CREATE_SUCCESS, this parameter includes an empty array.
ErrorMessage String A system exception 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.

Examples

Sample requests

https://iot.cn-shanghai.aliyuncs.com/?Action=QueryBatchRegisterDeviceStatus
&ProductKey=a1BwAGV****
&ApplyId=1234567
&<Common request parameters>

Sample success responses

XML format

<QueryBatchCheckDeviceNamesStatusResponse>
  <Data>
        <Status>CREATE_SUCCESS</Status>
        <ValidList></ValidList>
        <InvalidList></InvalidList>
  </Data>
  <RequestId>F731C7F3-A86C-4039-9FCA-5F802F3C59A1</RequestId>
  <Success>true</Success>
</QueryBatchCheckDeviceNamesStatusResponse>

JSON format

{
    "Data": {
        "Status": "CREATE_SUCCESS",
        "ValidList": {
            "Name": []
        },
        "InvalidList": {
            "Name": []
        }
    },
    "RequestId": "F731C7F3-A86C-4039-9FCA-5F802F3C59A1",
    "Success": true
}

Error codes

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