Get the upgrade task batch list under the upgrade package.
| Name | Type | Required | Sample Values | Description |
|---|---|---|---|---|
| Action | String | Yes | ListOTAJobByFirmware | System defined parameters. Value: ListOTAJobByFirmware. |
| CurrentPage | Integer | Yes | 1 | Specifies the page number in the returned results. Pages are sorted from 1. |
| FirmwareID | String | Yes | 197 | The upgrade package ID, which is the unique identifier of the upgrade package. |
| PageSize | Integer | Yes | 10 | Specifies the number of upgrade batches displayed on each page in the returned results. The maximum value is 200. |
Note: When calling an API, in addition to the API-specific request parameters described in this topic, you must also pass in the common request parameters. For more information about common request parameters, see Common parameters.
| Name | Type | Sample Values | Description |
|---|---|---|---|
| Code | String | Iot.system.SystemException | The error code returned when the call fails. For more information, see Error codes. |
| CurrentPage | Integer | 1 | The current page number. |
| Data | Array of SimpleOTAJobInfo | The batch information returned when the call is successful. For details, please see SimpleOTAJobInfo parameter under. | |
| SimpleOTAJobInfo | |||
| FirmwareID | String | 176 | The upgrade package ID. |
| JobId | String | 183634077921266 * * * * | Upgrade batch ID, the unique identifier of the batch. |
| JobStatus | String | IN_PROGRESS | The status of the batch. ●PLANNED : Planned. The batch has been created, but the scheduled time has not expired. Only batches that are scheduled for static upgrades may return this value. ●IN_PROGRESS : in execution. ●COMPLETED : Completed. ●CANCELED : Cancelled. |
| JobType | String | UPGRADE_FIRMWARE | Batch type. ●VERIFY_FIRMWARE : Upgrade package validation batch. ●UPGRADE_FIRMWARE: Bulk upgrade batch. |
| ProductKey | String | A19mzPZ * * * * | The unique identifier of The product to which The upgrade package belongs. |
| TargetSelection | String | SPECIFIC | Upgrade scope. ●ALL : Full upgrade. ●SPECIFIC : Directed upgrades. ●GRAY : Grayscale upgrade. |
| UtcCreate | String | 2019-12-28 T02:43:10.000Z | The time when the batch is created, in UTC format. |
| UtcModified | String | 2019-12-28 T02:43:10.000Z | The time when the batch was last modified, in UTC format. |
| ErrorMessage | String | System Exception | Error information returned when the call fails. |
| PageCount | Integer | 1 | Total number of pages. |
| PageSize | Integer | 10 | Number of device upgrade Jobs displayed per page. |
| RequestID | String | Kan | The unique identifier that IoT Platform generates for the request. |
| Success | Boolean | True | Whether the call was successful. ●True : The call succeeded. ●False : The call failed. |
| Total | Integer | 1 | Total number of equipment upgrade jobs. |
Request Example
curl 'https://si-d6e8d******8958054.tuyacloud.com:8686/?Action=ListOTAJobByFirmware&SignatureNonce=9e6189124f5a4716ad2de849467b****&AccessKeyId=xMr9wgwXQLhv5AUa65o0****&SignatureMethod=HMAC-SHA1&Timestamp=2024-11-19T09%3A47%3A43Z&FirmwareId=187&PageSize=10&CurrentPage=1&Signature=WJN0Ee8%2BX6pogcD3loLHIqQNEN0%3D'
Normal Return Example
{
"code": "",
"currentPage": 1,
"data": {
"simpleOTAJobInfo": [
{
"firmwareId": "125",
"jobId": "183414358556252****",
"jobStatus": "COMPLETED",
"jobType": "UPGRADE_FIRMWARE",
"productKey": "k1h9drZ****",
"selectionType": "STATIC",
"targetSelection": "SPECIFIC",
"utcCreate": "2024-09-12T08:14:42.214Z",
"utcModified": "2024-09-12T08:14:42.214Z"
}
]
},
"pageCount": 1,
"pageSize": 10,
"requestId": "78159f9b-5b3c-446c-b51a-28d701f7de88",
"success": true,
"total": 1
}