Queries all OTA modules of a product.

Limits

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

Note 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 ListOTAModuleByProduct

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

ProductKey String Yes a1uctKe****

The ProductKey of the product.

IotInstanceId String No iot-cn-0pp1n8t****

The ID of the instance. You can view the instance ID on the Overview page in the IoT Platform console.

Notice
  • If your instance has an ID, you must configure this parameter. If you do not set this parameter, the call fails.
  • If your instance has no Overview page or ID, you do not need to set this parameter.

For more information, see Overview.

In addition to the preceding operation-specific request parameters, you must specify common request parameters when you call this 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 Array of OtaModuleDTO

The OTA modules returned if the call is successful.

AliasName String Barcode_scanner

The alias of the OTA module.

Desc String This module represents the firmware of the barcode scanner.

The description of the OTA module.

GmtCreate String 2020-10-13T09:46Z

The time when the OTA module was created. The time is displayed in UTC.

GmtModified String 2020-10-19T09:46Z

The last time when the OTA module was updated. The time is displayed in UTC.

ModuleName String barcodeScanner

The name of the OTA module.

ProductKey String aluctKe****

The ProductKey of the product.

ErrorMessage String A system exception occurred.

The error message returned if the call fails.

RequestId String 74C2BB8D-1D6F-41F5-AE68-6B2310883F63

The ID of the request.

Success Boolean true

Indicates whether the call was successful.

  • true: The call was successful.
  • false: The call failed.

Examples

Sample requests

https://iot.cn-shanghai.aliyuncs.com/?Action=ListOTAModuleByProduct
&ProductKey=a1uctKe****
&<Common request parameters>

Sample success responses

XML format

<ListOTAModuleByProductResponse>
      <RequestId>74C2BB8D-1D6F-41F5-AE68-6B2310883F63</RequestId>
      <Data>
            <Desc>This module represents the firmware of the barcode scanner.</Desc>
            <GmtCreate>2020-10-13T09:46Z</GmtCreate>
            <ModuleName>barcodeScanner</ModuleName>
            <AliasName>Barcode_scanner</AliasName>
            <GmtModified>2020-10-19T09:46Z</GmtModified>
            <ProductKey>a1uctKe****</ProductKey>
      </Data>
      <Success>true</Success>
</ListOTAModuleByProductResponse>

JSON format

{
    "Data": {
        "Desc": "This module represents the firmware of the barcode scanner.",
        "GmtCreate": "2020-10-13T09:46Z",
        "ModuleName": "barcodeScanner",
        "AliasName": "Barcode_scanner",
        "GmtModified": "2020-10-19T09:46Z",
        "ProductKey": "a1uctKe****"
    },
    "RequestId": "74C2BB8D-1D6F-41F5-AE68-6B2310883F63",
    "Success": true
}

Error codes

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